Re: Tile widgets: using "cget"
- From: jenglish@xxxxxxxxxxxxx (Joe English)
- Date: 29 Sep 2005 15:10:31 GMT
Adrian Davis wrote:
>
>For example: I'd like to be able to create a label which has the same
>font as an existing (themed) label, but with either or both of the
>underline/bold attributes set and possibly in a different size. What
>would be the recommended Tile method to achieve this?
The Tile widgets uniformly use TIP#145(-inspired) named fonts.
First check if one of the following predefined symbolic font
names are appropriate for your purposes. If so, just use that:
# TkDefaultFont -- default for GUI items not otherwise specified
# TkTextFont -- font for user text (entry, listbox, others).
# TkHeadingFont -- headings (column headings, etc)
# TkCaptionFont -- dialog captions (primary text in alert dialogs, etc.)
# TkTooltipFont -- font to use for tooltip windows
If not, use [font configure TkDefaultFont] (or TkTextFont, or
whichever one you want to use as a base font) to extract the
default -family, -size, and -weight; modify to suit; and create
a new font with those attributes.
(See also library/fonts.tcl for more details).
--Joe English
.
- References:
- Tile widgets: using "cget"
- From: Adrian Davis
- Re: Tile widgets: using "cget"
- From: Bryan Oakley
- Re: Tile widgets: using "cget"
- From: Joe English
- Re: Tile widgets: using "cget"
- From: Adrian Davis
- Tile widgets: using "cget"
- Prev by Date: Re: TIP #257: Object Orientation for Tcl
- Next by Date: Re: TIP #257: Object Orientation for Tcl
- Previous by thread: Re: Tile widgets: using "cget"
- Next by thread: Tk Unicode is slow
- Index(es):
Relevant Pages
|