summaryrefslogtreecommitdiff
path: root/itcl/iwidgets/demos/selectiondialog
diff options
context:
space:
mode:
Diffstat (limited to 'itcl/iwidgets/demos/selectiondialog')
-rw-r--r--itcl/iwidgets/demos/selectiondialog22
1 files changed, 22 insertions, 0 deletions
diff --git a/itcl/iwidgets/demos/selectiondialog b/itcl/iwidgets/demos/selectiondialog
new file mode 100644
index 00000000000..15569f74dcb
--- /dev/null
+++ b/itcl/iwidgets/demos/selectiondialog
@@ -0,0 +1,22 @@
+# ----------------------------------------------------------------------
+# DEMO: selectiondialog in [incr Widgets]
+# ----------------------------------------------------------------------
+package require Iwidgets 4.0
+
+option add *textBackground seashell
+
+iwidgets::selectiondialog .sd -modality application
+.sd configure -selectionlabel "Font:"
+
+.sd insert items end Ariel Courier Helvetica Knarly Lucida \
+ Rumpus Symbol Times "Zapf Dingbats"
+
+button .select -text "Font..." -command {
+ if {[.sd activate]} {
+ puts "selected: [.sd get]"
+ } else {
+ puts "cancelled"
+ }
+}
+pack .select -side left
+