summaryrefslogtreecommitdiff
path: root/iwidgets/demos/dialogshell
diff options
context:
space:
mode:
authorKeith Seitz <keiths@redhat.com>2002-09-24 23:50:31 +0000
committerKeith Seitz <keiths@redhat.com>2002-09-24 23:50:31 +0000
commit43375e54d64ecea0b356c82d72b29fd95dd54cc9 (patch)
tree7582d7bb623964e848d993dde740802e40a748b0 /iwidgets/demos/dialogshell
parent5a88d945c95d8c15e31bf74fc9850b8c01fdeaec (diff)
downloadgdb-43375e54d64ecea0b356c82d72b29fd95dd54cc9.tar.gz
import iwidgets 4.0.1tcltk840-20020924-branchpoint
Diffstat (limited to 'iwidgets/demos/dialogshell')
-rw-r--r--iwidgets/demos/dialogshell35
1 files changed, 35 insertions, 0 deletions
diff --git a/iwidgets/demos/dialogshell b/iwidgets/demos/dialogshell
new file mode 100644
index 00000000000..1e3cd408ce1
--- /dev/null
+++ b/iwidgets/demos/dialogshell
@@ -0,0 +1,35 @@
+# ----------------------------------------------------------------------
+# DEMO: dialogshell in [incr Widgets]
+# ----------------------------------------------------------------------
+package require Iwidgets 4.0
+
+iwidgets::radiobox .rb -labeltext "Use modality to\nlock up your\napplication:"
+pack .rb -padx 4 -pady 4
+
+.rb add none -text "-modality none"
+.rb add application -text "-modality application"
+.rb add global -text "-modality global"
+.rb select none
+
+button .activate -text "Push Me" -command {
+ .ds configure -modality [.rb get]
+ .ds activate
+}
+pack .activate
+
+#
+# Build a generic dialog
+#
+iwidgets::dialogshell .ds
+
+.ds add dismiss -text "Dismiss" -command {.ds deactivate}
+.ds default dismiss
+
+#
+# Add something to the top of the dialog...
+#
+set win [.ds childsite]
+label $win.ex -text "Minimal Dialog\n(put your widgets here)" \
+ -background black -foreground white \
+ -width 40 -height 5
+pack $win.ex -expand yes -fill both -padx 4 -pady 4