summaryrefslogtreecommitdiffstats
path: root/library/demos/search.tcl
diff options
context:
space:
mode:
Diffstat (limited to 'library/demos/search.tcl')
-rw-r--r--library/demos/search.tcl10
1 files changed, 5 insertions, 5 deletions
diff --git a/library/demos/search.tcl b/library/demos/search.tcl
index 3a5e9bc..9f44e16 100644
--- a/library/demos/search.tcl
+++ b/library/demos/search.tcl
@@ -8,6 +8,8 @@ if {![info exists widgetDemo]} {
error "This script should be run from the \"widget\" demo."
}
+package require Tk
+
# textLoadFile --
# This procedure below loads a file into a text widget, discarding
# the previous contents of the widget. Tags for the old widget are
@@ -80,11 +82,9 @@ wm title $w "Text Demonstration - Search and Highlight"
wm iconname $w "search"
positionWindow $w
-frame $w.buttons
-pack $w.buttons -side bottom -fill x -pady 2m
-button $w.buttons.dismiss -text Dismiss -command "destroy $w"
-button $w.buttons.code -text "See Code" -command "showCode $w"
-pack $w.buttons.dismiss $w.buttons.code -side left -expand 1
+## See Code / Dismiss buttons
+set btns [addSeeDismiss $w.buttons $w]
+pack $btns -side bottom -fill x
frame $w.file
label $w.file.label -text "File name:" -width 13 -anchor w