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

NAME

6       ttk::combobox - text field with popdown selection list
7

SYNOPSIS

9       ttk::combobox    pathName    ?options?     -class    -cursor   -takefo‐
10       cus     -style
11

OPTIONS

13       [-exportselection exportSelection] Boolean value.  If set,  the  widget
14       selection  is  linked to the X selection.  [-justify justify] Specifies
15       how the text is aligned within the widget.  One  of  left,  center,  or
16       right.  [-postcommand postCommand] A Tcl script to evaluate immediately
17       before displaying the listbox.  The -postcommand script may specify the
18       -values  to  display.   [-state state] One of normal, readonly, or dis‐
19       abled.  In the readonly state, the value may not  be  edited  directly,
20       and the user can only select one of the -values from the dropdown list.
21       In the normal state, the text field is directly editable.  In the  dis‐
22       abled  state, no interaction is possible.  [-textvariable textVariable]
23       Specifies the name of a variable whose value is linked  to  the  widget
24       value.   Whenever  the  variable  changes  value  the  widget  value is
25       updated, and vice versa.  [-values values] Specifies the list of values
26       to display in the drop-down listbox.  [-width width] Specifies an inte‐
27       ger value indicating the desired width of the entry window, in average-
28       size characters of the widget's font.
29

DESCRIPTION

31       A  combobox  combines  a text field with a pop-down list of values; the
32       user may select the value of the text field from among  the  values  in
33       the list.
34

WIDGET COMMAND

36       pathName cget option
37              Returns  the  current  value  of the specified option.  See wid‐
38              get(n).
39
40       pathName configure ?option? ?value option value ...?
41              Modify or query widget options.  See widget(n).
42
43       pathName current ?newIndex?
44              If newIndex is supplied, sets the combobox value to the  element
45              at position newIndex in the list of -values.  Otherwise, returns
46              the index of the current value in the list of -values or  -1  if
47              the current value does not appear in the list.
48
49       pathName get
50              Returns the current value of the combobox.
51
52       pathName identify x y
53              Returns  the  name of the element at position x, y, or the empty
54              string if the coordinates are outside the window.
55
56       pathName instate statespec ?script?
57              Test the widget state.  See widget(n).
58
59       pathName set value
60              Sets the value of the combobox to value.
61
62       pathName state ?stateSpec?
63              Modify or query the widget state.  See widget(n).
64
65       The combobox widget also supports the following entry  widget  commands
66       (see                entry(n)                for               details):
67       bbox                  delete               icursor
68       index                 insert               selection xview
69

VIRTUAL EVENTS

71       The combobox widget generates a <<ComboboxSelected>> virtual event when
72       the user selects an element from the list of  values.   This  event  is
73       generated after the listbox is unposted.
74

SEE ALSO

76       widget(n), entry(n)
77
78
79
80tile                                  0.4                          combobox(n)
Impressum