package require Iwidgets
wm title . "Checkbox Example"
##
## wrap in a dialog user interaction
##
iwidgets::dialog .d \
-title "Checkbox Example"
#.d hide Help
#.d hide Apply
.d buttonconfigure OK \
-text "Update"
set cs [.d childsite]
##=========================================================
## Create a checkbox iwidget
##=========================================================
##
iwidgets::checkbox $cs.cb \
-labeltext "Places Visited" \
-labelpos n
set places [list australia england france germany spain hawaii tahiti]
foreach c [lsort $places] {
$cs.cb add $c \
-text [string totitle $c]
}
pack $cs.cb \
-fill both \
-expand false
.d activate