summaryrefslogtreecommitdiffstats
path: root/library/demos/filebox.tcl
diff options
context:
space:
mode:
Diffstat (limited to 'library/demos/filebox.tcl')
-rw-r--r--library/demos/filebox.tcl17
1 files changed, 10 insertions, 7 deletions
diff --git a/library/demos/filebox.tcl b/library/demos/filebox.tcl
index 63c7d59..445052e 100644
--- a/library/demos/filebox.tcl
+++ b/library/demos/filebox.tcl
@@ -2,7 +2,7 @@
#
# This demonstration script prompts the user to select a file.
#
-# RCS: @(#) $Id: filebox.tcl,v 1.10 2009/04/10 16:42:01 das Exp $
+# RCS: @(#) $Id: filebox.tcl,v 1.11 2010/01/04 12:11:48 patthoyts Exp $
if {![info exists widgetDemo]} {
error "This script should be run from the \"widget\" demo."
@@ -17,7 +17,10 @@ wm title $w "File Selection Dialogs"
wm iconname $w "filebox"
positionWindow $w
-label $w.msg -font $font -wraplength 4i -justify left -text "Enter a file name in the entry box or click on the \"Browse\" buttons to select a file name using the file selection dialog."
+ttk::frame $w._bg
+place $w._bg -x 0 -y 0 -relwidth 1 -relheight 1
+
+ttk::label $w.msg -font $font -wraplength 4i -justify left -text "Enter a file name in the entry box or click on the \"Browse\" buttons to select a file name using the file selection dialog."
pack $w.msg -side top
## See Code / Dismiss buttons
@@ -25,10 +28,10 @@ set btns [addSeeDismiss $w.buttons $w]
pack $btns -side bottom -fill x
foreach i {open save} {
- set f [frame $w.$i]
- label $f.lab -text "Select a file to $i: " -anchor e
- entry $f.ent -width 20
- button $f.but -text "Browse ..." -command "fileDialog $w $f.ent $i"
+ set f [ttk::frame $w.$i]
+ ttk::label $f.lab -text "Select a file to $i: " -anchor e
+ ttk::entry $f.ent -width 20
+ ttk::button $f.but -text "Browse ..." -command "fileDialog $w $f.ent $i"
pack $f.lab -side left
pack $f.ent -side left -expand yes -fill x
pack $f.but -side left
@@ -36,7 +39,7 @@ foreach i {open save} {
}
if {[tk windowingsystem] eq "x11"} {
- checkbutton $w.strict -text "Use Motif Style Dialog" \
+ ttk::checkbutton $w.strict -text "Use Motif Style Dialog" \
-variable tk_strictMotif -onvalue 1 -offvalue 0
pack $w.strict -anchor c