#!/usr/bin/wish
package require wylib

# Close an existing toplevel window
#------------------------------------------
proc closeit {w tag} {
    variable cfig
    eval pref::auto $tag [$w.f pref]		;#save prefs
    destroy $w
}

set tag dbs_test
set w [uwin .$tag]				;#create unique window name

toplevel $w
#    wm transient $w .
wm title $w {Dbs Test:}

eval dbs::dbs $w.f -table empl
pack $w.f -fill both -exp 1

wm protocol $w WM_DELETE_WINDOW "closeit $w $tag"
if {[set parr [pref::auto $tag]] != {}} {eval $w.f pref $parr}	;#restore preferences
dia::place $w

#puts "PREF:[$w.f pref]"
#$w.f menu file mi sep
#$w.f menu file mi z Close "dbs::closeit $w $tag" -help {Close this search window} -hot C-w

#$w.f.wh configure -width 400 -height 100
