1style(n)                        Tile Widget Set                       style(n)
2
3
4

NAME

6       style - Control overall look and feel of widgets
7

SYNOPSIS

9       style option ?args?
10

NOTES

12       This manpage has not been written yet.  Please see the Tcl'2004 confer‐
13       ence              presentation,              available               at
14       http://tktable.sourceforge.net/tile/tile-tcl2004.pdf
15http://tktable.sourceforge.net/tile/tile-tcl2004.pdf
16

DEFINITIONS

18       Each widget is assigned a style, which specifies the  set  of  elements
19       making  up the widget and how they are arranged, along with dynamic and
20       default settings for element resources.  By default, the style name  is
21       the  same  as  the widget's class; this may be overridden by the -style
22       option.
23
24       A theme is a collection of elements and styles which controls the over‐
25       all look and feel of an application.
26

DESCRIPTION

28       The style command takes the following arguments:
29
30       style configure style ?-option ?value option value...? ?
31              Sets the default value of the specified option(s) in style.
32
33       style map style ?-option { statespec value } ... ?
34              Sets  dynamic  values of the specified option(s) in style.  Each
35              statespec / value pair is examined in order;  the  value  corre‐
36              sponding to the first matching statespec is used.
37
38       style lookup style -option ?state ?default??
39              Returns  the value specified for -option in style style in state
40              state, using the standard  lookup  rules  for  element  options.
41              state  is  a list of state names; if omitted, it defaults to all
42              bits off (the ``normal'' state).  If  the  default  argument  is
43              present, it is used as a fallback value in case no specification
44              for -option is found.
45
46       style layout style ?layoutSpec?
47              Define the widget layout for style style.  See  "LAYOUTS"  below
48              for  the format of layoutSpec.  If layoutSpec is omitted, return
49              the layout specification for style style.
50
51       style element create elementName type ?args...?
52              Creates a new element in the current theme of  type  type.   The
53              only  built-in  element  type  is image (see image(n)), although
54              themes may define other element types (see  Ttk_RegisterElement‐
55              Factory).
56
57       style element names
58              Returns the list of elements defined in the current theme.
59
60       style element options element
61              Returns the list of element's options.
62
63       style theme create themeName ?-parent basedon? ?-settings script... ?
64              Creates  a  new  theme.   It  is  an  error if themeName already
65              exists.  If -parent is specified, the  new  theme  will  inherit
66              styles, elements, and layouts from the parent theme basedon.  If
67              -settings is present, script is evaluated in the context of  the
68              new theme as per style theme settings.
69
70       style theme settings themeName script
71              Temporarily  sets  the  current  theme  to  themeName,  evaluate
72              script, then restore the previous theme.  Typically script  sim‐
73              ply  defines  styles and elements, though arbitrary Tcl code may
74              appear.
75
76       style theme names
77              Returns a list of the available themes.
78
79       style theme use themeName
80              Sets the current theme to themeName, and refreshes all widgets.
81
82

LAYOUTS

84       A layout specifies a list of elements, each followed  by  one  or  more
85       options  specifying  how  to arrange the element.  The layout mechanism
86       uses a simplified version of the pack geometry manager: given  an  ini‐
87       tial cavity, each element is allocated a parcel.  Valid options are:
88
89       -side side
90              Specifies  which side of the cavity to place the element; one of
91              left, right, top, or bottom.  If omitted, the  element  occupies
92              the entire cavity.
93
94       -sticky [nswe]
95              Specifies  where the element is placed inside its allocated par‐
96              cel.
97
98       -children { sublayout... }
99              Specifies a list of elements to place inside the element.
100
101       For example: style layout Horizontal.TScrollbar {
102           Scrollbar.trough -children {
103               Scrollbar.leftarrow -side left
104               Scrollbar.rightarrow -side right
105               Horizontal.Scrollbar.thumb -side left -sticky ew
106           } }
107

SEE ALSO

109       tile-intro, widget, pixmap
110

KEYWORDS

112       style, theme, appearance
113
114
115
116tile                                  0.5                             style(n)
Impressum