summaryrefslogtreecommitdiffstats
path: root/generic/tkMenu.c
Commit message (Expand)AuthorAgeFilesLines
* * unix/tcl.m4 (Darwin): add 64bit support, check for Tiger copyfile(),das2005-11-271-8/+8
* * generic/tkMenu.c (MenuCmd): create event handler earlier tohobbs2005-05-311-37/+15
* * generic/tkInt.h: Backport of shutdown safety mods from the HEADdavygrvy2004-10-271-3/+3
* * generic/tkMenu.c (MenuWorldChanged): ensure that we recomputehobbs2004-09-161-7/+7
* * generic/tkMenu.c (MenuVarProc): prevent this from triggeringhobbs2003-12-031-5/+13
* menu clone cleanup bug fixvincentdarley2003-07-151-60/+138
* * generic/tkMenu.c (TkMenuCleanup): make sure to reset statichobbs2003-02-261-2/+30
* Applied companion patch for Tcl Patch 585105,dgp2002-08-051-4/+4
* generic/tkMenu.c (ConfigureMenu): freed saved options in all error caseshobbs2002-04-121-9/+14
* * Updates to handle change in type of part2 argument ofdgp2002-03-201-3/+3
* Correct and test for logic error when cloning menus. Bug 508988uid382262002-01-311-2/+2
* * Updated callers of Tcl_SplitList and Tcl_Merge.dgp2002-01-251-2/+2
* * Updates to handle change in type of tablePtrdgp2002-01-171-8/+10
* implementation of TIP 63 (accepted) -compound option to menu items.macosx_8_4_branchpointtmh2001-10-121-1/+13
* * generic/tkImgGIF.c:andreas_kupries2001-09-141-2/+5
* Merged changes from feature branch dgp-privates-into-namespace,dgp2001-08-011-3/+3
* * generic/tkMenu.c (TkInvokeMenu): checked for menu deletionhobbs2001-04-031-7/+13
* Overall change: Implemented TIP 5, which exportsericm2000-11-221-6/+6
* * tests/bind.test: Tweaked expected error messages for [bindtags]ericm2000-08-031-9/+13
* * generic/tkMenu.c (DeleteMenuCloneEntries): Applied fix fromericm2000-06-271-2/+2
* * generic/tkImgGIF.c (FileReadGIF): added cast for trashBufferhobbs2000-02-101-6/+12
* Merged 8-1-0 into mainline.rjohnson1999-04-211-1/+1
* fixed Tk comment errorssurles1999-04-161-3/+3
* * Merged 8.1 branch into the main trunkstanton1999-04-161-907/+1302
* Replaced SCCS strings, fixed binary filesstanton1998-09-141-1/+1
* Initial revisionrjohnson1998-04-011-0/+3057
enting a region \fIwidth\fR pixels wide, \fIheight\fR pixels tall, at the specified \fIx, y\fR coordinates. .PP \fBTtk_PadBox\fR returns a new box located inside the specified \fIparcel\fR, shrunken according to the left, top, right, and bottom margins specified by \fIpadding\fR. .PP \fBTtk_ExpandBox\fR is the inverse of \fBTtk_PadBox\fR: it returns a new box surrounding the specified \fIparcel\fR, expanded according to the left, top, right, and bottom margins specified by \fIpadding\fR. .PP \fBTtk_PackBox\fR allocates a parcel \fIwidth\fR by \fIheight\fR pixels wide on the specified \fIside\fR of the \fIcavity\fR, and shrinks the \fIcavity\fR accordingly. .PP \fBTtk_StickBox\fR places a box with the requested \fIwidth\fR and \fIheight\fR inside the \fIparcel\fR according to the \fIsticky\fR bits. .PP \fBTtk_PlaceBox\fR combines \fBTtk_PackBox\fR and \fBTtk_StickBox\fR: it allocates a parcel on the specified \fIside\fR of the \fIcavity\fR, places a box of the requested size inside the parcel according to \fIsticky\fR, and shrinks the \fIcavity\fR. .PP \fBTtk_AnchorBox\fR places a box with the requested \fIwidth\fR and \fIheight\fR inside the \fIparcel\fR according to the specified \fIanchor\fR option. .PP \fBTtk_BoxContains\fR tests if the specified \fIx, y\fR coordinate lies within the rectangular region \fIbox\fR. .SH "PADDDING" The \fBTtk_Padding\fR structure is used to represent borders, internal padding, and external margins: .CS typedef struct { short left; short top; short right; short bottom; } Ttk_Padding; .CE .PP \fBTtk_MakePadding\fR is a convenience routine that contsructs a \fBTtk_Padding\fR structure with the specified left, top, right, and bottom components. .PP \fBTtk_UniformPadding\fR constructs a \fBTtk_Padding\fR structure with all components equal to the specified \fIborder\fR. .PP \fBTtk_AddPadding\fR adds two \fBTtk_Padding\fRs together and returns a combined padding containing the sum of the individual padding components. .PP \fBTtk_RelievePadding\fR adds an extra 2 pixels of padding to \fIpadding\fR according to the specified \fIrelief\fR. If \fIrelief\fR is \fBTK_RELIEF_SUNKEN\fR, adds two pixels at the top and left so the inner region is shifted down and to the left. If it is \fBTK_RELIEF_RAISED\fR, adds two pixels at the bottom and right so the inner region is shifted up and to the right. Otherwise, adds 1 pixel on all sides. This is typically used in element geometry procedures to simulate a .QW pressed-in look for pushbuttons. .SH "CONVERSION ROUTINES" \fBTtk_GetPaddingFromObj\fR converts the string in \fIobjPtr\fR to a \fBTtk_Padding\fR structure. The string representation is a list of up to four length specifications .QW "\fIleft top right bottom\fR" . If fewer than four elements are specified, \fIbottom\fR defaults to \fItop\fR, \fIright\fR defaults to \fIleft\fR, and \fItop\fR defaults to \fIleft\fR. See \fBTk_GetPixelsFromObj(3)\fR for the syntax of length specifications. .PP \fBTtk_GetBorderFromObj\fR is the same as \fBTtk_GetPaddingFromObj\fR except that the lengths are specified as integers (i.e., resolution-dependant values like \fI3m\fR are not allowed). .PP \fBTtk_GetStickyFromObj\fR converts the string in \fIobjPtr\fR to a \fIsticky\fR bitmask. The string contains zero or more of the characters \fBn\fR, \fBs\fR, \fBe\fR, or \fBw\fR. .SH "SEE ALSO" Tk_GetReliefFromObj(3), Tk_GetPixelsFromObj(3), Tk_GetAnchorFromObj(3) .SH "KEYWORDS" geometry, padding, margins, box, region, sticky, relief