diff options
-rw-r--r-- | ChangeLog | 60 | ||||
-rw-r--r-- | doc/grid.n | 35 |
2 files changed, 65 insertions, 30 deletions
@@ -1,18 +1,22 @@ +2009-07-11 Donal K. Fellows <dkf@users.sf.net> + + * doc/grid.n: [Bug 2818455]: Corrected example. + 2009-07-02 Pat Thoyts <patthoyts@users.sourceforge.net> * generic/tkInt.h: Avoid using C++ reserved word in header. 2009-06-30 Daniel Steffen <das@users.sourceforge.net> - * generic/tkInt.h: add assert macros for clang static + * generic/tkInt.h: Add assert macros for clang static analyzer and redefine Tcl_Panic to assert after panic in clang PURIFY builds. - * generic/tkImgPhInstance.c: small fixes to make clang static + * generic/tkImgPhInstance.c: Small fixes to make clang static * generic/tkTextDisp.c: analyzer happier. - * generic/tkConfig.c: add clang assert for false positives + * generic/tkConfig.c: Add clang assert for false positives * generic/tkUndo.c: from static analyzer. 2009-06-29 Daniel Steffen <das@users.sourceforge.net> @@ -63,68 +67,68 @@ * macosx/ttkMacOSXTheme.c: * macosx/tkMacOSXCarbonEvents.c (removed): - * macosx/tkMacOSXCursors.h (new): move cursor data from resources + * macosx/tkMacOSXCursors.h (new): Move cursor data from resources * macosx/tkMacOSXXCursors.h (new): to compiled-in const array; * macosx/tkMacOSXCursors.r (removed): remove obsolete Rez source * macosx/tkMacOSXXCursors.r (removed): files for resource data. * macosx/tkAboutDlg.r (removed): * macosx/tkMacOSXAETE.r (removed): - * macosx/Tk.tiff (new): rename and update icon to blue feather; + * macosx/Tk.tiff (new): Rename and update icon to blue feather; * macosx/Tk.icns (new): add tiff version for about dialog. * macosx/Wish.icns (removed): - * macosx/Tk-Info.plist.in: update copyright; adjust minimum system + * macosx/Tk-Info.plist.in: Update copyright; adjust minimum system * macosx/Wish-Info.plist.in: version requirement. * generic/tkEntry.h: - * license.terms: sync list of entities with those in the + * license.terms: Sync list of entities with those in the tcl license.terms, add Apple Inc. - * generic/tk.h: update comment with list of source + * generic/tk.h: Update comment with list of source files containing tk version numbers. - * generic/tkButton.c: on aqua, recompute button geometry on + * generic/tkButton.c: On aqua, recompute button geometry on secondary image change to enable cache of native img format in geom compute. - * generic/tkGrab.c: on aqua, make all grabs global, the + * generic/tkGrab.c: On aqua, make all grabs global, the Mac OS X windowserver forces all grabs to be application-local only anyway. - * generic/tkSelect.c: enable utf8 atom on aqua. + * generic/tkSelect.c: Enable utf8 atom on aqua. - * generic/tk.decls: replace carbon types in public and + * generic/tk.decls: Replace carbon types in public and * generic/tkInt.decls: internal platform stubs interfaces with void* resp. generic Tk types. - * xlib/xgc.c: add support for managing a platform- + * xlib/xgc.c: Add support for managing a platform- specific cache appended to a GC. - * tests/dialog.test: change name of undefined bit to avoid + * tests/dialog.test: Change name of undefined bit to avoid match with OSType native bitmap name. - * doc/cursors.n: update list of cursors mapped to native + * doc/cursors.n: Update list of cursors mapped to native cursors and add new native cursors. - * doc/menu.n: add documentation of new aqua-specific + * doc/menu.n: Add documentation of new aqua-specific .window menu, document new constraints on .apple menu. - * library/console.tcl: add aqua window and help menus. + * library/console.tcl: Add aqua window and help menus. - * unix/Makefile.in: add support for TkAqua-implementation- + * unix/Makefile.in: Add support for TkAqua-implementation- specific sources determined at configure-time. Update dist target for new/removed files. - * unix/configure.in: add libraries & compiler flags for + * unix/configure.in: Add libraries & compiler flags for Cocoa and Objective-C; update build support for new/removed files; add support for configure-time choice of TkAqua implementation. - * macosx/Tk-Common.xcconfig (new): rename Xcode projects and + * macosx/Tk-Common.xcconfig (new): Rename Xcode projects and * macosx/Tk-Debug.xcconfig (new): related files; update for Xcode * macosx/Tk-Release.xcconfig (new): 3.1 and 3.2; update for Cocoa, * macosx/Tk.xcode/* (new): Objective-C & GC; update with @@ -136,20 +140,20 @@ * macosx/Wish-Release.xcconfig (removed): * macosx/Wish.pbproj/* (removed): - * macosx/README: document new Cocoa-port features and + * macosx/README: Document new Cocoa-port features and constraints; update project docs; cleanup. - * carbon/tkMacOSXInt.h: add dummy defines for empty GC cache. + * carbon/tkMacOSXInt.h: Add dummy defines for empty GC cache. - * carbon/tkMacOSXColor.c: update for type changes in platform + * carbon/tkMacOSXColor.c: Update for type changes in platform * carbon/tkMacOSXDraw.c: stubs interfaces. * carbon/tkMacOSXHLEvents.c: * carbon/tkMacOSXMouseEvent.c: * carbon/tkMacOSXSubwindows.c: * carbon/tkMacOSXWm.c: - * carbon/tkMacOSXButton.c: fix warning. + * carbon/tkMacOSXButton.c: Fix warning. * generic/tkPlatDecls.h: regen. * generic/tkIntPlatDecls.h: @@ -164,11 +168,11 @@ 2009-06-26 Daniel Steffen <das@users.sourceforge.net> - * carbon/ (new directory): copy of current state of 'macosx' + * carbon/ (new directory): Copy of current state of 'macosx' source directory, to preserve legacy TkAqua implementation based on Carbon API (with support for Mac OS X releases older than 10.5). - * unix/Makefile.in: add support for --enable-aqua=carbon + * unix/Makefile.in: Add support for --enable-aqua=carbon * unix/configure.in: configure option (legacy fallback for pre-Mac OS X 10.5 releases). @@ -176,7 +180,7 @@ 2009-06-22 Jan Nijtmans <nijtmans@users.sf.net> - * generic/tkCanvUtil.c fix [Bug 220935] canvas dash update problem + * generic/tkCanvUtil.c: [Bug 220935]: canvas dash update problem 2009-06-12 Donal K. Fellows <dkf@users.sf.net> @@ -210,7 +214,7 @@ * win/tkWinSend.c: FormatMessage should always use the ignore-inserts * win/tkWinTest.c: flag when processing system errors. - * generic/tkFont.c: [Bug 2791352] handle parsing of type 5 font + * generic/tkFont.c: [Bug 2791352]: Handle parsing of type 5 font * tests/font.test: descriptions with hyphenated family name. 2009-05-06 Pat Thoyts <patthoyts@users.sourceforge.net> @@ -4,7 +4,7 @@ '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. '\" -'\" RCS: @(#) $Id: grid.n,v 1.22 2008/09/23 13:36:40 dkf Exp $ +'\" RCS: @(#) $Id: grid.n,v 1.23 2009/07/11 07:25:32 dkf Exp $ '\" .so man.macros .TH grid n 8.5 Tk "Tk Built-In Commands" @@ -24,6 +24,7 @@ The \fBgrid\fR command can have any of several forms, depending on the \fIoption\fR argument: .TP \fBgrid \fIslave \fR?\fIslave ...\fR? ?\fIoptions\fR? +. If the first argument to \fBgrid\fR is suitable as the first slave argument to \fBgrid configure\fR, either a window name (any value starting with \fB.\fR) or one of the characters \fBx\fR or \fB^\fR @@ -31,11 +32,13 @@ starting with \fB.\fR) or one of the characters \fBx\fR or \fB^\fR processed in the same way as \fBgrid configure\fR. .TP \fBgrid anchor \fImaster\fR ?\fIanchor\fR? +. The anchor value controls how to place the grid within the master when no row/column has any weight. See \fBTHE GRID ALGORITHM\fR below for further details. The default \fIanchor\fR is \fInw\fR. .TP \fBgrid bbox \fImaster\fR ?\fIcolumn row\fR? ?\fIcolumn2 row2\fR? +. With no arguments, the bounding box (in pixels) of the grid is returned. The return value consists of 4 integers. The first two are the pixel @@ -48,6 +51,7 @@ arguments are specified, then the bounding box spanning the rows and columns indicated is returned. .TP \fBgrid columnconfigure \fImaster index \fR?\fI\-option value...\fR? +. Query or set the column properties of the \fIindex\fR column of the geometry master, \fImaster\fR. The valid options are \fB\-minsize\fR, \fB\-weight\fR, \fB\-uniform\fR @@ -84,6 +88,7 @@ are returned in a list of pairs. .TP \fBgrid configure \fIslave \fR?\fIslave ...\fR? ?\fIoptions\fR? +. The arguments consist of the names of one or more slave windows followed by pairs of arguments that specify how to manage the slaves. @@ -95,6 +100,7 @@ The following options are supported: .RS .TP \fB\-column \fIn\fR +. Insert the slave so that it occupies the \fIn\fRth column in the grid. Column numbers start with 0. If this option is not supplied, then the slave is arranged just to the right of previous slave specified on this @@ -106,17 +112,20 @@ is incremented by one. Thus the \fBx\fR represents a blank column for this row in the grid. .TP \fB\-columnspan \fIn\fR +. Insert the slave so that it occupies \fIn\fR columns in the grid. The default is one column, unless the window name is followed by a \fB\-\fR, in which case the columnspan is incremented once for each immediately following \fB\-\fR. .TP \fB\-in \fIother\fR +. Insert the slave(s) in the master window given by \fIother\fR. The default is the first slave's parent window. .TP \fB\-ipadx \fIamount\fR +. The \fIamount\fR specifies how much horizontal internal padding to leave on each side of the slave(s). This is space is added inside the slave(s) border. @@ -124,12 +133,14 @@ The \fIamount\fR must be a valid screen distance, such as \fB2\fR or \fB.5c\fR. It defaults to 0. .TP \fB\-ipady \fIamount\fR +. The \fIamount\fR specifies how much vertical internal padding to leave on the top and bottom of the slave(s). This space is added inside the slave(s) border. The \fIamount\fR defaults to 0. .TP \fB\-padx \fIamount\fR +. The \fIamount\fR specifies how much horizontal external padding to leave on each side of the slave(s), in screen units. \fIAmount\fR may be a list @@ -138,6 +149,7 @@ The \fIamount\fR defaults to 0. This space is added outside the slave(s) border. .TP \fB\-pady \fIamount\fR +. The \fIamount\fR specifies how much vertical external padding to leave on the top and bottom of the slave(s), in screen units. \fIAmount\fR may be a list @@ -146,12 +158,14 @@ The \fIamount\fR defaults to 0. This space is added outside the slave(s) border. .TP \fB\-row \fIn\fR +. Insert the slave so that it occupies the \fIn\fRth row in the grid. Row numbers start with 0. If this option is not supplied, then the slave is arranged on the same row as the previous slave specified on this call to \fBgrid\fR, or the first unoccupied row if this is the first slave. .TP \fB\-rowspan \fIn\fR +. Insert the slave so that it occupies \fIn\fR rows in the grid. The default is one row. If the next \fBgrid\fR command contains \fB^\fR characters instead of \fIslaves\fR that line up with the columns @@ -159,6 +173,7 @@ of this \fIslave\fR, then the \fBrowspan\fR of this \fIslave\fR is extended by one. .TP \fB\-sticky \fIstyle\fR +. If a slave's cell is larger than its requested dimensions, this option may be used to position (or stretch) the slave within its cell. \fIStyle\fR is a string that contains zero or more of the characters @@ -181,6 +196,7 @@ than receiving default values. .RE .TP \fBgrid forget \fIslave \fR?\fIslave ...\fR? +. Removes each of the \fIslave\fRs from grid for its master and unmaps their windows. The slaves will no longer be managed by the grid geometry manager. @@ -189,6 +205,7 @@ slave is managed once more by the grid geometry manager, the initial default settings are used. .TP \fBgrid info \fIslave\fR +. Returns a list whose elements are the current configuration state of the slave given by \fIslave\fR in the same option-value form that might be specified to \fBgrid configure\fR. @@ -197,12 +214,14 @@ The first two elements of the list are where \fImaster\fR is the slave's master. .TP \fBgrid location \fImaster x y\fR +. Given \fIx\fR and \fIy\fR values in screen units relative to the master window, the column and row number at that \fIx\fR and \fIy\fR location is returned. For locations that are above or to the left of the grid, \fB\-1\fR is returned. .TP \fBgrid propagate \fImaster\fR ?\fIboolean\fR? +. If \fIboolean\fR has a true boolean value such as \fB1\fR or \fBon\fR then propagation is enabled for \fImaster\fR, which must be a window name (see \fBGEOMETRY PROPAGATION\fR below). @@ -215,6 +234,7 @@ for \fImaster\fR. Propagation is enabled by default. .TP \fBgrid rowconfigure \fImaster index \fR?\fI\-option value...\fR? +. Query or set the row properties of the \fIindex\fR row of the geometry master, \fImaster\fR. The valid options are \fB\-minsize\fR, \fB\-weight\fR, \fB\-uniform\fR @@ -251,6 +271,7 @@ are returned in a list of pairs. .TP \fBgrid remove \fIslave \fR?\fIslave ...\fR? +. Removes each of the \fIslave\fRs from grid for its master and unmaps their windows. The slaves will no longer be managed by the grid geometry manager. @@ -260,12 +281,14 @@ slave is managed once more by the grid geometry manager, the previous values are retained. .TP \fBgrid size \fImaster\fR +. Returns the size of the grid (in columns then rows) for \fImaster\fR. The size is determined either by the \fIslave\fR occupying the largest row or column, or the largest column or row with a \fBminsize\fR, \fBweight\fR, or \fBpad\fR that is non-zero. .TP \fBgrid slaves \fImaster\fR ?\fI\-option value\fR? +. If no options are supplied, a list of all of the slaves in \fImaster\fR are returned, most recently manages first. \fIOption\fR can be either \fB\-row\fR or \fB\-column\fR which @@ -289,16 +312,19 @@ command where \fIslave\fR names are normally expected. .RS .TP \fB\-\fR +. This increases the columnspan of the \fIslave\fR to the left. Several \fB\-\fR's in a row will successively increase the columnspan. A \fB\-\fR may not follow a \fB^\fR or a \fBx\fR, nor may it be the first \fIslave\fR argument to \fBgrid configure\fR. .TP \fBx\fR +. This leaves an empty column between the \fIslave\fR on the left and the \fIslave\fR on the right. .TP \fB^\fR +. This extends the \fBrowspan\fR of the \fIslave\fR above the \fB^\fR's in the grid. The number of \fB^\fR's in a row must match the number of columns spanned by the \fIslave\fR above it. @@ -393,15 +419,18 @@ manager, written by George Howlett. .SH EXAMPLES .PP A toplevel window containing a text widget and two scrollbars: +.PP .CS # Make the widgets toplevel .t text .t.txt \-wrap none \-xscroll {.t.h set} \-yscroll {.t.v set} -scrollbar .t.v \-orient vertical \-command {.t.txt xview} +scrollbar .t.v \-orient vertical \-command {.t.txt yview} scrollbar .t.h \-orient horizontal \-command {.t.txt xview} + # Lay them out \fBgrid\fR .t.txt .t.v \-sticky nsew \fBgrid\fR .t.h \-sticky nsew + # Tell the text widget to take all the extra room \fBgrid rowconfigure\fR .t .t.txt \-weight 1 \fBgrid columnconfigure\fR .t .t.txt \-weight 1 @@ -410,10 +439,12 @@ scrollbar .t.h \-orient horizontal \-command {.t.txt xview} Three widgets of equal width, despite their different .QW natural widths: +.PP .CS button .b \-text "Foo" entry .e \-variable foo label .l \-text "This is a fairly long piece of text" + \fBgrid\fR .b .e .l \-sticky ew \fBgrid columnconfigure\fR . "all" \-uniform allTheSame .CE |