1iwidgets::checkbox − Create and manipulate a checkbox widget
3gets::Labeledframe <‐ iwidgets::Checkbox
6See the "options" manual entry for details on the standard op‐
7tions.
10See the "labeledframe" class manual entry for details on the in‐
11herited options.
12Name: command
13Class: Command
14Command‐Line Switch: ‐command
15Specifies a Tcl command procedure to be evaluated following a
16change in the current check box selection.
17Name: orient
18Class: Orient
19Command‐Line Switch: ‐orient
20Default Value: vertical
21Specifies the orientation of the checkbuttons within the check‐
22box. Valid values are either "horizontal" or "vertical".
23
24The iwidgets::checkbox command creates a check button box widget
25capable of adding, inserting, deleting, selecting, and configur‐
26ing checkbuttons as well as obtaining the currently selected but‐
27ton.
28
29The iwidgets::checkbox command creates a new Tcl command whose
30name is pathName. This command may be used to invoke various op‐
31erations on the widget. It has the following general form: path‐
33act behavior of the command. Many of the widget commands for the
35of the checkbox to operate on. These indicators are called in‐
37Checkbox indexes may be specified in any of the following forms:
39to the top checkbutton of the checkbox. end Indicates the last
40checkbutton of the checkbox. pattern If the index doesn’t satis‐
41fy one of the above forms then this form is used. Pattern is
42pattern‐matched against the tag of each checkbutton in the check‐
43box, in order from top to bottom, until a matching entry is
44found. The rules of Tcl_StringMatch are used.
45
47button to the checkbuttond window on the bottom. The command
48takes additional options which are passed on to the checkbutton
49as construction arguments. These include the standard Tk check‐
50button options. The tag is returned. pathName buttonconfigure
52mand, except that it applies to the options for an individual
53checkbutton, whereas configureapplies to the options for the
54checkbox as a whole. Options may have any of the values accepted
55by the add widget command. If options are specified, options are
56modified as indicated in the command and the command returns an
57empty string. If no options are specified, returns a list de‐
58scribing the current options for entry index (see Tk_ConfigureIn‐
61en by option. Option may have any of the values accepted by the
64the widget. If no option is specified, returns a list describing
65all of the available options for pathName (see Tk_ConfigureInfo
66for information on the format of this list). If option is speci‐
67fied with no value, then the command returns a list describing
68the one named option (this list will be identical to the corre‐
69sponding sublist of the value returned if no option is speci‐
70fied). If one or more option−value pairs are specified, then the
71command modifies the given widget option(s) to have the given
72value(s); in this case the command returns an empty string. Op‐
75ton given an index. pathName deselect index Deselects a speci‐
76fied checkbutton given an index. pathName flash index Flashes a
77specified checkbutton given an index. pathName get ?index? Re‐
78turns the tags of the currently selected checkbuttons or the se‐
79lection status of specific checkbutton when given an index.
81index. pathName insert index tag ?option value option value ...?
82Same as the add command except that it inserts the new checkbut‐
83ton just before the one given by index, instead of appending to
84the end of the checkbox. The option, and value arguments have
85the same interpretation as for the add widget command. pathName
87
88 package require Iwidgets 4.0
89 iwidgets::checkbox .cb ‐labeltext Styles
90 .cb add bold ‐text Bold
91 .cb add italic ‐text Italic
92 .cb add underline ‐text Underline
93 .cb select underline
94
95 pack .cb ‐padx 10 ‐pady 10 ‐fill both ‐expand yes
96
97John A. Tucker checkbox, widget
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132