#!/usr/local/bin/wish -f # Program: main # Tcl version: 6.7 (Tcl/Tk/XF) # Tk version: 3.2 # XF version: $__lastrelease$ # # module inclusion global env global xfLoadPath if {[info exists env(XF_LOAD_PATH)]} { if {[string first $env(XF_LOAD_PATH) /usr/local/lib/] == -1} { set xfLoadPath $env(XF_LOAD_PATH):/usr/local/lib/ } { set xfLoadPath /usr/local/lib/ } } { set xfLoadPath /usr/local/lib/ } global argc global argv global tkVersion global xfLoadInfo global xfLoadPath set xfLoadInfo 0 set tmpArgv "" for {set counter 0} {$counter < $argc} {incr counter 1} { case [string tolower [lindex $argv $counter]] in { {-xfloadpath} { incr counter 1 set xfLoadPath "[lindex $argv $counter]:$xfLoadPath" } {-xfstartup} { incr counter 1 source [lindex $argv $counter] } {-xfbindfile} { incr counter 1 set env(XF_BIND_FILE) "[lindex $argv $counter]" } {-xfcolorfile} { incr counter 1 set env(XF_COLOR_FILE) "[lindex $argv $counter]" } {-xfcursorfile} { incr counter 1 set env(XF_CURSOR_FILE) "[lindex $argv $counter]" } {-xffontfile} { incr counter 1 set env(XF_FONT_FILE) "[lindex $argv $counter]" } {-xfmodelmono} { if {$tkVersion >= 3.0} { tk colormodel . monochrome } } {-xfmodelcolor} { if {$tkVersion >= 3.0} { tk colormodel . color } } {-xfloading} { set xfLoadInfo 1 } {-xfnoloading} { set xfLoadInfo 0 } {default} { lappend tmpArgv [lindex $argv $counter] } } } set argv $tmpArgv set argc [llength $tmpArgv] unset counter unset tmpArgv # procedure to show window . proc ShowWindow. {args} {# xf ignore me 7 # Window manager configurations global tkVersion wm positionfrom . user wm sizefrom . "" wm grid . 80 24 9 14 wm maxsize . 1152 900 wm minsize . 0 0 wm title . {FrasaSoft Postgres Frontend (v0.1)} # build widget .frame0 frame .frame0 \ -borderwidth {2}\ -relief {raised} # build widget .frame0.menubutton0 menubutton .frame0.menubutton0 \ -menu {.frame0.menubutton0.m}\ -text {Templates}\ -underline {0} # build widget .frame0.menubutton0.m menu .frame0.menubutton0.m .frame0.menubutton0.m add command\ -command {set temp [format "\nretrieve ()\nfrom \nwhere "] qtext insert end $temp}\ -label {Retrieve} .frame0.menubutton0.m add command\ -command {set temp [format "\nappend ()\n"] qtext insert end $temp}\ -label {Append} .frame0.menubutton0.m add command\ -command {set temp [format "\ncreate
()\n"] qtext insert end $temp}\ -label {Create table} .frame0.menubutton0.m add command\ -command {set temp [format "\ndefine function \n(language = \"C|postquel\", returntype = )\narg is ()\nas"] qtext insert end $temp}\ -label {Define function} .frame0.menubutton0.m add command\ -command {set temp [format "\nreplace
()\nfrom \nwhere "] qtext insert end $temp}\ -label {Update} # build widget .frame0.menubutton1 menubutton .frame0.menubutton1 \ -menu {.frame0.menubutton1.m}\ -text {Database}\ -underline {0} # bindings bind .frame0.menubutton1 {global currentdb set currentdb ""} # build widget .frame0.menubutton1.m menu .frame0.menubutton1.m .frame0.menubutton1.m add radiobutton\ -label {Query mode}\ -value {query}\ -variable {mode}\ -underline {0} .frame0.menubutton1.m add radiobutton\ -label {Source mode}\ -value {source}\ -variable {mode} .frame0.menubutton1.m add separator .frame0.menubutton1.m add cascade\ -command {SetDBMenu}\ -label {Databases >}\ -menu {.frame0.menubutton1.m.m} .frame0.menubutton1.m add separator .frame0.menubutton1.m add command\ -command {YesNoBox "Really Quit?" if {$yesNoBox(button) == 1} { destroy . }}\ -label {Quit}\ -underline {0} # build widget .frame0.menubutton1.m.m menu .frame0.menubutton1.m.m .frame0.menubutton1.m.m add command\ -command {global databases; set databases [GetDatabases]; SetDBMenu; InitDB}\ -label {Rescan} .frame0.menubutton1.m.m add separator .frame0.menubutton1.m.m add radiobutton\ -command {InitDB}\ -label {template1}\ -value {template1}\ -variable {currentdb} .frame0.menubutton1.m.m add radiobutton\ -command {InitDB}\ -label {postgres}\ -value {postgres}\ -variable {currentdb} .frame0.menubutton1.m.m add radiobutton\ -command {InitDB}\ -label {accessrtdb}\ -value {accessrtdb}\ -variable {currentdb} # build widget .frame0.menubutton2 menubutton .frame0.menubutton2 \ -menu {.frame0.menubutton2.m}\ -text {Help}\ -underline {0} # build widget .frame0.menubutton2.m menu .frame0.menubutton2.m .frame0.menubutton2.m add command\ -label {Not yet implemented} # pack widget .frame0 pack append .frame0 \ .frame0.menubutton1 {left frame center} \ .frame0.menubutton2 {right frame center} \ .frame0.menubutton0 {left frame center} # build widget .frame14 frame .frame14 \ -borderwidth {2}\ -relief {raised} # build widget .frame14.frame0 frame .frame14.frame0 \ -borderwidth {2}\ -relief {raised} # build widget .frame14.frame0.entry2 entry .frame14.frame0.entry2 \ -relief {sunken} # build widget .frame14.frame0.frame frame .frame14.frame0.frame # build widget .frame14.frame0.frame.scrollbar2 scrollbar .frame14.frame0.frame.scrollbar2 \ -command {.frame14.frame0.frame.listbox1 yview}\ -relief {raised} # build widget .frame14.frame0.frame.scrollbar3 scrollbar .frame14.frame0.frame.scrollbar3 \ -command {.frame14.frame0.frame.listbox1 xview}\ -orient {horizontal}\ -relief {raised} # build widget .frame14.frame0.frame.listbox1 listbox .frame14.frame0.frame.listbox1 \ -relief {sunken}\ -xscrollcommand {.frame14.frame0.frame.scrollbar3 set}\ -yscrollcommand {.frame14.frame0.frame.scrollbar2 set} # bindings bind .frame14.frame0.frame.listbox1 {MenuPopupHandle .frame14.frame0.frame.listbox1.menu0 %W %X %Y} bind .frame14.frame0.frame.listbox1 {.frame14.frame0.frame.listbox1.menu0 post %X %Y} bind .frame14.frame0.frame.listbox1 {.frame14.frame0.frame.listbox1.menu0 invoke active; .frame14.frame0.frame.listbox1.menu0 unpost} bind .frame14.frame0.frame.listbox1 {PrintSrc} bind .frame14.frame0.frame.listbox1 {funclist delete 0 end} # build widget .frame14.frame0.frame.listbox1.menu0 menu .frame14.frame0.frame.listbox1.menu0 .frame14.frame0.frame.listbox1.menu0 add command\ -command {PrintSrc}\ -label {Print source}\ -underline {0} # pack widget .frame14.frame0.frame pack append .frame14.frame0.frame \ .frame14.frame0.frame.scrollbar2 {left frame center filly} \ .frame14.frame0.frame.listbox1 {top frame center expand fill} \ .frame14.frame0.frame.scrollbar3 {bottom frame center fillx} # build widget .frame14.frame0.label1 label .frame14.frame0.label1 \ -relief {raised}\ -text {functions} # pack widget .frame14.frame0 pack append .frame14.frame0 \ .frame14.frame0.label1 {top frame center fillx} \ .frame14.frame0.frame {top frame center expand fill} \ .frame14.frame0.entry2 {top frame center fillx} # build widget .frame14.frame15 frame .frame14.frame15 \ -borderwidth {2}\ -relief {raised} # build widget .frame14.frame15.entry4 entry .frame14.frame15.entry4 \ -relief {sunken} # build widget .frame14.frame15.frame frame .frame14.frame15.frame # build widget .frame14.frame15.frame.scrollbar2 scrollbar .frame14.frame15.frame.scrollbar2 \ -command {.frame14.frame15.frame.listbox1 yview}\ -relief {raised} # build widget .frame14.frame15.frame.scrollbar3 scrollbar .frame14.frame15.frame.scrollbar3 \ -command {.frame14.frame15.frame.listbox1 xview}\ -orient {horizontal}\ -relief {raised} # build widget .frame14.frame15.frame.listbox1 listbox .frame14.frame15.frame.listbox1 \ -exportselection {0}\ -relief {sunken}\ -xscrollcommand {.frame14.frame15.frame.scrollbar3 set}\ -yscrollcommand {.frame14.frame15.frame.scrollbar2 set} # bindings bind .frame14.frame15.frame.listbox1 {%W select from [%W nearest %y]} bind .frame14.frame15.frame.listbox1 {MenuPopupHandle .frame14.frame15.frame.listbox1.menu0 %W %X %Y} bind .frame14.frame15.frame.listbox1 {.frame14.frame15.frame.listbox1.menu0 post %X %Y} bind .frame14.frame15.frame.listbox1 {.frame14.frame15.frame.listbox1.menu0 invoke active; .frame14.frame15.frame.listbox1.menu0 unpost} bind .frame14.frame15.frame.listbox1 {InitAttr InitFunc} bind .frame14.frame15.frame.listbox1 {classlist delete 0 end} bind .frame14.frame15.frame.listbox1 {%W select from [%W nearest %y]} bind .frame14.frame15.frame.listbox1 {%W select from [%W nearest %y]} # build widget .frame14.frame15.frame.listbox1.menu0 menu .frame14.frame15.frame.listbox1.menu0 .frame14.frame15.frame.listbox1.menu0 add command\ -command {InitAttr InitFunc}\ -label {Update attributes} .frame14.frame15.frame.listbox1.menu0 add command\ -command {set curclass [classlist curselection] if {$curclass != ""} { set classname [classlist get $curclass] delClass $classname }}\ -label {Delete Class}\ -underline {0} .frame14.frame15.frame.listbox1.menu0 add command\ -label {Rename Class} .frame14.frame15.frame.listbox1.menu0 add command\ -label {Add new Class ...} .frame14.frame15.frame.listbox1.menu0 add separator .frame14.frame15.frame.listbox1.menu0 add command\ -label {select parent} .frame14.frame15.frame.listbox1.menu0 add command\ -label {list children} .frame14.frame15.frame.listbox1.menu0 add command\ -command {EntryDialog}\ -label {Append}\ -state {active} # pack widget .frame14.frame15.frame pack append .frame14.frame15.frame \ .frame14.frame15.frame.scrollbar2 {left frame center filly} \ .frame14.frame15.frame.listbox1 {top frame center expand fill} \ .frame14.frame15.frame.scrollbar3 {bottom frame center fillx} # build widget .frame14.frame15.label18 label .frame14.frame15.label18 \ -relief {raised}\ -text {Classes} # pack widget .frame14.frame15 pack append .frame14.frame15 \ .frame14.frame15.label18 {top frame center expand fill} \ .frame14.frame15.frame {top frame center expand fill} \ .frame14.frame15.entry4 {top frame center fill} # build widget .frame14.frame16 frame .frame14.frame16 \ -borderwidth {2}\ -relief {raised} # build widget .frame14.frame16.entry3 entry .frame14.frame16.entry3 \ -relief {sunken} # build widget .frame14.frame16.frame frame .frame14.frame16.frame # build widget .frame14.frame16.frame.scrollbar2 scrollbar .frame14.frame16.frame.scrollbar2 \ -command {.frame14.frame16.frame.listbox1 yview}\ -relief {raised} # build widget .frame14.frame16.frame.scrollbar3 scrollbar .frame14.frame16.frame.scrollbar3 \ -command {.frame14.frame16.frame.listbox1 xview}\ -orient {horizontal}\ -relief {raised} # build widget .frame14.frame16.frame.listbox1 listbox .frame14.frame16.frame.listbox1 \ -exportselection {0}\ -relief {sunken}\ -xscrollcommand {.frame14.frame16.frame.scrollbar3 set}\ -yscrollcommand {.frame14.frame16.frame.scrollbar2 set} # bindings bind .frame14.frame16.frame.listbox1 {%W select from [%W nearest %y]} bind .frame14.frame16.frame.listbox1 {MenuPopupHandle .frame14.frame16.frame.listbox1.menu0 %W %X %Y} bind .frame14.frame16.frame.listbox1 {.frame14.frame16.frame.listbox1.menu0 post %X %Y} bind .frame14.frame16.frame.listbox1 {.frame14.frame16.frame.listbox1.menu0 invoke active; .frame14.frame16.frame.listbox1.menu0 unpost} bind .frame14.frame16.frame.listbox1 {InitValues} bind .frame14.frame16.frame.listbox1 {attrlist delete 0 end} bind .frame14.frame16.frame.listbox1 {%W select from [%W nearest %y]} bind .frame14.frame16.frame.listbox1 {%W select from [%W nearest %y]} # build widget .frame14.frame16.frame.listbox1.menu0 menu .frame14.frame16.frame.listbox1.menu0 .frame14.frame16.frame.listbox1.menu0 add command\ -command {InitValues}\ -label {Update Instance values} .frame14.frame16.frame.listbox1.menu0 add command\ -label {Delete attribute} .frame14.frame16.frame.listbox1.menu0 add command\ -label {Rename attribute} .frame14.frame16.frame.listbox1.menu0 add command\ -label {Add new attribute ...} # pack widget .frame14.frame16.frame pack append .frame14.frame16.frame \ .frame14.frame16.frame.scrollbar2 {left frame center filly} \ .frame14.frame16.frame.listbox1 {top frame center expand fill} \ .frame14.frame16.frame.scrollbar3 {bottom frame center fillx} # build widget .frame14.frame16.label19 label .frame14.frame16.label19 \ -relief {raised}\ -text {Attributes} # pack widget .frame14.frame16 pack append .frame14.frame16 \ .frame14.frame16.label19 {top frame center expand fill} \ .frame14.frame16.frame {top frame center expand fill} \ .frame14.frame16.entry3 {top frame center fill} # build widget .frame14.frame17 frame .frame14.frame17 \ -borderwidth {2}\ -relief {raised} # build widget .frame14.frame17.entry2 entry .frame14.frame17.entry2 \ -relief {sunken} # build widget .frame14.frame17.frame frame .frame14.frame17.frame # build widget .frame14.frame17.frame.scrollbar2 scrollbar .frame14.frame17.frame.scrollbar2 \ -command {.frame14.frame17.frame.listbox1 yview}\ -relief {raised} # build widget .frame14.frame17.frame.scrollbar3 scrollbar .frame14.frame17.frame.scrollbar3 \ -command {.frame14.frame17.frame.listbox1 xview}\ -orient {horizontal}\ -relief {raised} # build widget .frame14.frame17.frame.listbox1 listbox .frame14.frame17.frame.listbox1 \ -exportselection {0}\ -relief {sunken}\ -xscrollcommand {.frame14.frame17.frame.scrollbar3 set}\ -yscrollcommand {.frame14.frame17.frame.scrollbar2 set} # bindings bind .frame14.frame17.frame.listbox1 {%W select from [%W nearest %y]} bind .frame14.frame17.frame.listbox1 {valuelist delete 0 end} bind .frame14.frame17.frame.listbox1 {%W select from [%W nearest %y]} bind .frame14.frame17.frame.listbox1 {%W select from [%W nearest %y]} # pack widget .frame14.frame17.frame pack append .frame14.frame17.frame \ .frame14.frame17.frame.scrollbar2 {left frame center filly} \ .frame14.frame17.frame.listbox1 {top frame center expand fill} \ .frame14.frame17.frame.scrollbar3 {bottom frame center fillx} # build widget .frame14.frame17.label20 label .frame14.frame17.label20 \ -relief {raised}\ -text {instance values} # pack widget .frame14.frame17 pack append .frame14.frame17 \ .frame14.frame17.label20 {top frame center expand fill} \ .frame14.frame17.frame {top frame center expand fill} \ .frame14.frame17.entry2 {top frame center fill} # pack widget .frame14 pack append .frame14 \ .frame14.frame15 {left frame center expand fill} \ .frame14.frame16 {left frame center expand fill} \ .frame14.frame17 {left frame center expand fill} \ .frame14.frame0 {left frame center expand fill} # build widget .frame21 frame .frame21 \ -borderwidth {2} # build widget .frame21.frame frame .frame21.frame \ -relief {raised} # build widget .frame21.frame.scrollbar1 scrollbar .frame21.frame.scrollbar1 \ -command {.frame21.frame.text2 yview}\ -relief {raised} # build widget .frame21.frame.text2 text .frame21.frame.text2 \ -borderwidth {2}\ -font {*-Courier-Medium-R-Normal-*-140-*}\ -relief {sunken}\ -setgrid {1}\ -yscrollcommand {.frame21.frame.scrollbar1 set} # bindings bind .frame21.frame.text2 {MenuPopupHandle .frame21.frame.text2.menu0 %W %X %Y} bind .frame21.frame.text2 {qtext tag remove sel 1.0 end} bind .frame21.frame.text2 {.frame21.frame.text2.menu0 post %X %Y} bind .frame21.frame.text2 {.frame21.frame.text2.menu0 invoke active; .frame21.frame.text2.menu0 unpost} bind .frame21.frame.text2 {qtext delete sel.first sel.last} bind .frame21.frame.text2 {qtext mark set insert {insert + 1 lines}} bind .frame21.frame.text2 {qtext mark set insert {insert - 1 chars}} bind .frame21.frame.text2 {qtext mark set insert {insert + 1 chars}} bind .frame21.frame.text2 {qtext mark set insert {insert - 1 lines}} # build widget .frame21.frame.text2.menu0 menu .frame21.frame.text2.menu0 .frame21.frame.text2.menu0 add command\ -command {SendQuery}\ -label {Send}\ -underline {0} .frame21.frame.text2.menu0 add command\ -command {qtext delete 1.0 end}\ -label {Clear} .frame21.frame.text2.menu0 add command\ -command {global PreviousQuery qtext insert end $PreviousQuery}\ -label {Previous} .frame21.frame.text2.menu0 add command\ -command {qtext delete sel.first sel.last}\ -label {Delete selection} .frame21.frame.text2.menu0 add separator .frame21.frame.text2.menu0 add command\ -command {Rescan}\ -label {Rescan }\ -underline {0} .frame21.frame.text2.menu0 add checkbutton\ -label {Automatic Rescan}\ -offvalue {off}\ -onvalue {on}\ -variable {auto_rescan}\ -underline {0} .frame21.frame.text2.menu0 add separator .frame21.frame.text2.menu0 add command\ -command {SaveText}\ -label {Save to file}\ -underline {2} # pack widget .frame21.frame pack append .frame21.frame \ .frame21.frame.scrollbar1 {right frame center filly} \ .frame21.frame.text2 {top frame center expand fill} # pack widget .frame21 pack append .frame21 \ .frame21.frame {top frame center expand fill} # pack widget . pack append . \ .frame0 {top frame center fillx} \ .frame14 {top frame center fillx} \ .frame21 {top frame center expand fill} if {"[info procs XFEdit]" != ""} { XFEditSetShowWindows XFMiscBindWidgetTree .xfEdit } global tkVersion if {$tkVersion >= 3.0} { tk_menuBar .frame0 .frame0.menubutton0 .frame0.menubutton1 .frame0.menubutton2 } { tk_menus . .frame0.menubutton0 .frame0.menubutton1 .frame0.menubutton2 } .frame14.frame0.entry2 insert end {} .frame14.frame15.entry4 insert end {} .frame14.frame15.frame.listbox1 insert end {pg_type} .frame14.frame15.frame.listbox1 insert end {pg_database} .frame14.frame15.frame.listbox1 insert end {pg_demon} .frame14.frame15.frame.listbox1 insert end {pg_proc} .frame14.frame15.frame.listbox1 insert end {pg_server} .frame14.frame15.frame.listbox1 insert end {pg_user} .frame14.frame15.frame.listbox1 insert end {pg_attribute} .frame14.frame15.frame.listbox1 insert end {pg_class} .frame14.frame15.frame.listbox1 insert end {pg_magic} .frame14.frame15.frame.listbox1 insert end {pg_defaults} .frame14.frame15.frame.listbox1 insert end {pg_variable} .frame14.frame15.frame.listbox1 insert end {pg_log} .frame14.frame15.frame.listbox1 insert end {pg_time} .frame14.frame15.frame.listbox1 insert end {pg_group} .frame14.frame15.frame.listbox1 insert end {pg_inherits} .frame14.frame15.frame.listbox1 insert end {pg_index} .frame14.frame15.frame.listbox1 insert end {pg_version} .frame14.frame15.frame.listbox1 insert end {pg_statistic} .frame14.frame15.frame.listbox1 insert end {pg_operator} .frame14.frame15.frame.listbox1 insert end {pg_opclass} .frame14.frame15.frame.listbox1 insert end {pg_am} .frame14.frame15.frame.listbox1 insert end {pg_amop} .frame14.frame15.frame.listbox1 insert end {pg_amproc} .frame14.frame15.frame.listbox1 insert end {pg_language} .frame14.frame15.frame.listbox1 insert end {pg_parg} .frame14.frame15.frame.listbox1 insert end {pg_aggregate} .frame14.frame15.frame.listbox1 insert end {pg_ipl} .frame14.frame15.frame.listbox1 insert end {pg_inheritproc} .frame14.frame15.frame.listbox1 insert end {pg_platter} .frame14.frame15.frame.listbox1 insert end {pg_plmap} .frame14.frame15.frame.listbox1 insert end {pg_prs2rule} .frame14.frame15.frame.listbox1 insert end {pg_prs2plans} .frame14.frame15.frame.listbox1 insert end {pg_prs2stub} .frame14.frame15.frame.listbox1 insert end {pg_rewrite} .frame14.frame15.frame.listbox1 insert end {pg_listener} .frame14.frame15.frame.listbox1 insert end {pg_naming} .frame14.frame15.frame.listbox1 insert end {pg_large_object} .frame14.frame15.frame.listbox1 insert end {pg_attnameind} .frame14.frame15.frame.listbox1 insert end {pg_attnumind} .frame14.frame15.frame.listbox1 insert end {pg_attrelidind} .frame14.frame15.frame.listbox1 insert end {pg_procidind} .frame14.frame15.frame.listbox1 insert end {pg_procnameind} .frame14.frame15.frame.listbox1 insert end {pg_typeidind} .frame14.frame15.frame.listbox1 insert end {pg_typenameind} .frame14.frame15.frame.listbox1 insert end {pg_namingind} .frame14.frame15.frame.listbox1 insert end {pg_namparind} .frame14.frame15.frame.listbox1 insert end {pg_classnameind} .frame14.frame15.frame.listbox1 insert end {pg_classoidind} .frame14.frame15.frame.listbox1 insert end {DD_TABLES} .frame14.frame15.frame.listbox1 insert end {DD_ADM} .frame14.frame15.frame.listbox1 insert end {DD_AGE} .frame14.frame15.frame.listbox1 insert end {DD_BRK} .frame14.frame16.entry3 insert end {} .frame14.frame16.frame.listbox1 insert end {field} .frame14.frame16.frame.listbox1 insert end {typname} .frame14.frame16.frame.listbox1 insert end {descr} .frame14.frame16.frame.listbox1 insert end {rel} .frame14.frame16.frame.listbox1 insert end {ctid} .frame14.frame16.frame.listbox1 insert end {lock} .frame14.frame16.frame.listbox1 insert end {oid} .frame14.frame16.frame.listbox1 insert end {xmin} .frame14.frame16.frame.listbox1 insert end {cmin} .frame14.frame16.frame.listbox1 insert end {xmax} .frame14.frame16.frame.listbox1 insert end {cmax} .frame14.frame16.frame.listbox1 insert end {chain} .frame14.frame16.frame.listbox1 insert end {anchor} .frame14.frame16.frame.listbox1 insert end {tmin} .frame14.frame16.frame.listbox1 insert end {tmax} .frame14.frame16.frame.listbox1 insert end {vtype} .frame14.frame17.entry2 insert end {} .frame14.frame17.frame.listbox1 insert end {RECORD#} .frame14.frame17.frame.listbox1 insert end {PAT_ID1} .frame14.frame17.frame.listbox1 insert end {EDIT_DATE} .frame14.frame17.frame.listbox1 insert end {EDIT_ID} .frame14.frame17.frame.listbox1 insert end {IN_OUT} .frame14.frame17.frame.listbox1 insert end {ROOM_NUM} .frame14.frame17.frame.listbox1 insert end {BED_NUM} .frame14.frame17.frame.listbox1 insert end {TRAN_MODE} .frame14.frame17.frame.listbox1 insert end {ADM_DATE} .frame14.frame17.frame.listbox1 insert end {ADM_TIME} .frame14.frame17.frame.listbox1 insert end {ADM_DIAG} .frame14.frame17.frame.listbox1 insert end {CATAGORY} .frame14.frame17.frame.listbox1 insert end {DISCHARGE} .frame14.frame17.frame.listbox1 insert end {EXPIRED} .frame14.frame17.frame.listbox1 insert end {PREVIOUS_RT} .frame14.frame17.frame.listbox1 insert end {BIRTH_DATE} .frame14.frame17.frame.listbox1 insert end {BIRTH_PLACE} .frame14.frame17.frame.listbox1 insert end {RACE} .frame14.frame17.frame.listbox1 insert end {RELIGION} .frame14.frame17.frame.listbox1 insert end {GENDER} .frame14.frame17.frame.listbox1 insert end {MARITAL} .frame14.frame17.frame.listbox1 insert end {NUM_CHILDREN} .frame14.frame17.frame.listbox1 insert end {SS_NUMBER} .frame14.frame17.frame.listbox1 insert end {VIP} .frame14.frame17.frame.listbox1 insert end {PAT_ADR1} .frame14.frame17.frame.listbox1 insert end {PAT_ADR2} .frame14.frame17.frame.listbox1 insert end {PAT_CITY} .frame14.frame17.frame.listbox1 insert end {PAT_STATE} .frame14.frame17.frame.listbox1 insert end {PAT_FZIP} .frame14.frame17.frame.listbox1 insert end {PAT_POSTAL} .frame14.frame17.frame.listbox1 insert end {PAT_PLUS_4} .frame14.frame17.frame.listbox1 insert end {PAT_CENS_TRC} .frame14.frame17.frame.listbox1 insert end {PAT_CENS_ID} .frame14.frame17.frame.listbox1 insert end {PAT_COUNTY} .frame14.frame17.frame.listbox1 insert end {PAT_HOME_PH} .frame14.frame17.frame.listbox1 insert end {PAT_WORK_PH} .frame14.frame17.frame.listbox1 insert end {PAT_WK_PH_X} .frame21.frame.text2 insert end { OK } EndSrc. } proc EndSrc. {} { wm deiconify . } # User defined procedures # Procedure: AlertBox proc AlertBox { {alertBoxMessage "Alert message"} {alertBoxCommand ""} {alertBoxGeometry "350x150"} {alertBoxTitle "Alert box"} args} { # xf ignore me 9 ########## # Procedure: AlertBox # Description: show alert box # Arguments: {alertBoxMessage} - the text to display # {alertBoxCommand} - the command to call after ok # {alertBoxGeometry} - the geometry for the window # {alertBoxTitle} - the title for the window # {args} - labels of buttons # Returns: The number of the selected button, ot nothing # Sideeffects: none # Notes: there exist also functions called: # AlertBoxFile - to open and read a file automatically # AlertBoxFd - to read from an already opened filedescriptor ########## # # global alertBox(activeBackground) - active background color # global alertBox(activeForeground) - active foreground color # global alertBox(after) - destroy alert box after n seconds # global alertBox(anchor) - anchor for message box # global alertBox(background) - background color # global alertBox(font) - message font # global alertBox(foreground) - foreground color # global alertBox(justify) - justify for message box # global alertBox(toplevelName) - the toplevel name global alertBox # show alert box if {[llength $args] > 0} { eval AlertBoxInternal "\{$alertBoxMessage\}" "\{$alertBoxCommand\}" "\{$alertBoxGeometry\}" "\{$alertBoxTitle\}" $args } { AlertBoxInternal $alertBoxMessage $alertBoxCommand $alertBoxGeometry $alertBoxTitle } if {[llength $args] > 0} { # wait for the box to be destroyed update idletask grab $alertBox(toplevelName) tkwait window $alertBox(toplevelName) return $alertBox(button) } } # Procedure: AlertBoxFd proc AlertBoxFd { {alertBoxInFile ""} {alertBoxCommand ""} {alertBoxGeometry "350x150"} {alertBoxTitle "Alert box"} args} { # xf ignore me 9 ########## # Procedure: AlertBoxFd # Description: show alert box containing a filedescriptor # Arguments: {alertBoxInFile} - a filedescriptor to read. The descriptor # is closed after reading # {alertBoxCommand} - the command to call after ok # {alertBoxGeometry} - the geometry for the window # {alertBoxTitle} - the title for the window # {args} - labels of buttons # Returns: The number of the selected button, ot nothing # Sideeffects: none # Notes: there exist also functions called: # AlertBox - to display a passed string # AlertBoxFile - to open and read a file automatically ########## # # global alertBox(activeBackground) - active background color # global alertBox(activeForeground) - active foreground color # global alertBox(after) - destroy alert box after n seconds # global alertBox(anchor) - anchor for message box # global alertBox(background) - background color # global alertBox(font) - message font # global alertBox(foreground) - foreground color # global alertBox(justify) - justify for message box # global alertBox(toplevelName) - the toplevel name global alertBox # check file existance if {"$alertBoxInFile" == ""} { puts stderr "No filedescriptor specified" return } set alertBoxMessage [read $alertBoxInFile] close $alertBoxInFile # show alert box if {[llength $args] > 0} { eval AlertBoxInternal "\{$alertBoxMessage\}" "\{$alertBoxCommand\}" "\{$alertBoxGeometry\}" "\{$alertBoxTitle\}" $args } { AlertBoxInternal $alertBoxMessage $alertBoxCommand $alertBoxGeometry $alertBoxTitle } if {[llength $args] > 0} { # wait for the box to be destroyed update idletask grab $alertBox(toplevelName) tkwait window $alertBox(toplevelName) return $alertBox(button) } } # Procedure: AlertBoxFile proc AlertBoxFile { {alertBoxFile ""} {alertBoxCommand ""} {alertBoxGeometry "350x150"} {alertBoxTitle "Alert box"} args} { # xf ignore me 9 ########## # Procedure: AlertBoxFile # Description: show alert box containing a file # Arguments: {alertBoxFile} - filename to read # {alertBoxCommand} - the command to call after ok # {alertBoxGeometry} - the geometry for the window # {alertBoxTitle} - the title for the window # {args} - labels of buttons # Returns: The number of the selected button, ot nothing # Sideeffects: none # Notes: there exist also functions called: # AlertBox - to display a passed string # AlertBoxFd - to read from an already opened filedescriptor ########## # # global alertBox(activeBackground) - active background color # global alertBox(activeForeground) - active foreground color # global alertBox(after) - destroy alert box after n seconds # global alertBox(anchor) - anchor for message box # global alertBox(background) - background color # global alertBox(font) - message font # global alertBox(foreground) - foreground color # global alertBox(justify) - justify for message box # global alertBox(toplevelName) - the toplevel name global alertBox # check file existance if {"$alertBoxFile" == ""} { puts stderr "No filename specified" return } if {[catch "open $alertBoxFile r" alertBoxInFile]} { puts stderr "$alertBoxInFile" return } set alertBoxMessage [read $alertBoxInFile] close $alertBoxInFile # show alert box if {[llength $args] > 0} { eval AlertBoxInternal "\{$alertBoxMessage\}" "\{$alertBoxCommand\}" "\{$alertBoxGeometry\}" "\{$alertBoxTitle\}" $args } { AlertBoxInternal $alertBoxMessage $alertBoxCommand $alertBoxGeometry $alertBoxTitle } if {[llength $args] > 0} { # wait for the box to be destroyed update idletask grab $alertBox(toplevelName) tkwait window $alertBox(toplevelName) return $alertBox(button) } } # Procedure: AlertBoxInternal proc AlertBoxInternal { alertBoxMessage alertBoxCommand alertBoxGeometry alertBoxTitle args} { # xf ignore me 9 global alertBox set tmpButtonOpt "" set tmpFrameOpt "" set tmpMessageOpt "" if {"$alertBox(activeBackground)" != ""} { append tmpButtonOpt "-activebackground \"$alertBox(activeBackground)\" " } if {"$alertBox(activeForeground)" != ""} { append tmpButtonOpt "-activeforeground \"$alertBox(activeForeground)\" " } if {"$alertBox(background)" != ""} { append tmpButtonOpt "-background \"$alertBox(background)\" " append tmpFrameOpt "-background \"$alertBox(background)\" " append tmpMessageOpt "-background \"$alertBox(background)\" " } if {"$alertBox(font)" != ""} { append tmpButtonOpt "-font \"$alertBox(font)\" " append tmpMessageOpt "-font \"$alertBox(font)\" " } if {"$alertBox(foreground)" != ""} { append tmpButtonOpt "-foreground \"$alertBox(foreground)\" " append tmpMessageOpt "-foreground \"$alertBox(foreground)\" " } # start build of toplevel if {"[info commands XFDestroy]" != ""} { catch {XFDestroy $alertBox(toplevelName)} } { catch {destroy $alertBox(toplevelName)} } toplevel $alertBox(toplevelName) -borderwidth 0 catch "$alertBox(toplevelName) config $tmpFrameOpt" if {[catch "wm geometry $alertBox(toplevelName) $alertBoxGeometry"]} { wm geometry $alertBox(toplevelName) 350x150 } wm title $alertBox(toplevelName) $alertBoxTitle wm maxsize $alertBox(toplevelName) 1000 1000 wm minsize $alertBox(toplevelName) 100 100 # end build of toplevel message $alertBox(toplevelName).message1 -anchor "$alertBox(anchor)" -justify "$alertBox(justify)" -relief raised -text "$alertBoxMessage" catch "$alertBox(toplevelName).message1 config $tmpMessageOpt" set xfTmpWidth [string range $alertBoxGeometry 0 [expr [string first x $alertBoxGeometry]-1]] if {"$xfTmpWidth" != ""} { # set message size catch "$alertBox(toplevelName).message1 configure -width [expr $xfTmpWidth-10]" } { $alertBox(toplevelName).message1 configure -aspect 1500 } frame $alertBox(toplevelName).frame1 -borderwidth 0 -relief raised catch "$alertBox(toplevelName).frame1 config $tmpFrameOpt" set alertBoxCounter 0 set buttonNum [llength $args] if {$buttonNum > 0} { while {$alertBoxCounter < $buttonNum} { button $alertBox(toplevelName).frame1.button$alertBoxCounter -text "[lindex $args $alertBoxCounter]" -command " global alertBox set alertBox(button) $alertBoxCounter if {\"\[info commands XFDestroy\]\" != \"\"} { catch {XFDestroy $alertBox(toplevelName)} } { catch {destroy $alertBox(toplevelName)} }" catch "$alertBox(toplevelName).frame1.button$alertBoxCounter config $tmpButtonOpt" pack append $alertBox(toplevelName).frame1 $alertBox(toplevelName).frame1.button$alertBoxCounter {left fillx expand} incr alertBoxCounter } } { button $alertBox(toplevelName).frame1.button0 -text "OK" -command " global alertBox set alertBox(button) 0 if {\"\[info commands XFDestroy\]\" != \"\"} { catch {XFDestroy $alertBox(toplevelName)} } { catch {destroy $alertBox(toplevelName)} } $alertBoxCommand" catch "$alertBox(toplevelName).frame1.button0 config $tmpButtonOpt" pack append $alertBox(toplevelName).frame1 $alertBox(toplevelName).frame1.button0 {left fillx expand} } # packing pack append $alertBox(toplevelName) $alertBox(toplevelName).frame1 {bottom fill} $alertBox(toplevelName).message1 {top fill expand} if {$alertBox(after) != 0} { after [expr $alertBox(after)*1000] "catch \"$alertBox(toplevelName).frame1.button0 invoke\"" } } # Procedure: EntryDialog proc EntryDialog {} { global currentdb global auto_rescan set clnr [classlist curselection] if {$clnr != "" } { set class [classlist get $clnr] # find the attributes of selected class: set dontshow {ctid lock oid xmin cmin xmax cmax chain anchor tmin tmax vtype} set query [format "retrieve (a.attname) from a in pg_attribute, c in pg_class where a.attrelid = c.oid and c.relname = \"%s\"" $class] set res [retrieve_records $currentdb $query] # loop through them and create labeled entries set nrattr [llength $res] toplevel .append wm title .append [format "Append %s" $class] loop a 0 $nrattr 1 { set attr [lindex $res $a] keylget attr attname aname if {[lsearch $dontshow $aname] == -1} { frame .append.$a label .append.$a.label -text $aname -relief raised entry .append.$a.entry -relief sunken -width 60 # add binding for key to move to next field: bind .append.$a.entry { set c [winfo children .append] set nc [llength $c] set nc [expr {$nc - 1}] set el [lindex [split %W .] 2] set el [expr {($el + 1) %% $nc}] focus .append.$el.entry } bind .append.$a.entry { .append.buttons.insert invoke .append.buttons.clear invoke focus .append.0.entry } bind .append.$a.entry { .append.buttons.clear invoke focus .append.0.entry } pack append .append.$a .append.$a.label {left} .append.$a.entry {right fillx expand} pack append .append .append.$a {top fillx expand} } } # create some buttons at the bottom: frame .append.buttons pack append .append .append.buttons {bottom fillx} button .append.buttons.ok -text "OK" -command {destroy .append} button .append.buttons.insert -text "append (ctrl-a)" -command { set childs [winfo children .append] set l [expr {[llength $childs] - 1}] set cl [classlist curselection] set class [classlist get $cl] set result "append $class (" set split "" loop c 0 $l 1 { set lab [.append.$c.label configure -text] set aname [lindex $lab [expr {[llength $lab]-1}]] set avalue [.append.$c.entry get] if {$avalue != ""} { set result [format "%s%s%s = \"%s\"" $result $split $aname $avalue] if {$split == ""} {set split " , " } } } set result [format "%s)" $result] PQsetdb $currentdb set res [PQexec $result] if {{string range $res 0 0} == "E"} { qtext insert end [format "\nERROR in query:\n%s\n" $res] } else { qtext insert end [format "\nOK\n"] if {$auto_rescan == "on"} { Rescan } } } button .append.buttons.clear -text "Clear (ctrl-c)" -command { set nrofentries [expr {[llength [winfo children .append]] - 1}] loop e 0 $nrofentries 1 { .append.$e.entry delete 0 end } } checkbutton .append.buttons.auto -text "Auto rescan" -variable auto_rescan -offvalue {off} -onvalue {on} pack append .append.buttons .append.buttons.ok {right fillx expand} .append.buttons.insert {right fillx expand} .append.buttons.clear {right fillx expand } .append.buttons.auto {right fillx expand} grab set .append focus .append.0.entry tkwait window .append grab release .append } } # Procedure: FSBox proc FSBox { {fsBoxMessage "Select file:"} {fsBoxFileName ""} {fsBoxActionOk ""} {fsBoxActionCancel ""}} { # xf ignore me 5 ########## # Procedure: FSBox # Description: show file selector box # Arguments: fsBoxMessage - the text to display # fsBoxFileName - a file name that should be selected # fsBoxActionOk - the action that should be performed on ok # fsBoxActionCancel - the action that should be performed on cancel # Returns: the filename that was selected, or nothing # Sideeffects: none ########## # # global fsBox(activeBackground) - active background color # global fsBox(activeForeground) - active foreground color # global fsBox(background) - background color # global fsBox(font) - text font # global fsBox(foreground) - foreground color # global fsBox(extensions) - scan directory for extensions # global fsBox(scrollActiveForeground) - scrollbar active background color # global fsBox(scrollBackground) - scrollbar background color # global fsBox(scrollForeground) - scrollbar foreground color # global fsBox(scrollSide) - side where scrollbar is located global fsBox set tmpButtonOpt "" set tmpFrameOpt "" set tmpMessageOpt "" set tmpScaleOpt "" set tmpScrollOpt "" if {"$fsBox(activeBackground)" != ""} { append tmpButtonOpt "-activebackground \"$fsBox(activeBackground)\" " } if {"$fsBox(activeForeground)" != ""} { append tmpButtonOpt "-activeforeground \"$fsBox(activeForeground)\" " } if {"$fsBox(background)" != ""} { append tmpButtonOpt "-background \"$fsBox(background)\" " append tmpFrameOpt "-background \"$fsBox(background)\" " append tmpMessageOpt "-background \"$fsBox(background)\" " } if {"$fsBox(font)" != ""} { append tmpButtonOpt "-font \"$fsBox(font)\" " append tmpMessageOpt "-font \"$fsBox(font)\" " } if {"$fsBox(foreground)" != ""} { append tmpButtonOpt "-foreground \"$fsBox(foreground)\" " append tmpMessageOpt "-foreground \"$fsBox(foreground)\" " } if {"$fsBox(scrollActiveForeground)" != ""} { append tmpScrollOpt "-activeforeground \"$fsBox(scrollActiveForeground)\" " } if {"$fsBox(scrollBackground)" != ""} { append tmpScrollOpt "-background \"$fsBox(scrollBackground)\" " } if {"$fsBox(scrollForeground)" != ""} { append tmpScrollOpt "-foreground \"$fsBox(scrollForeground)\" " } if {[file exists [file tail $fsBoxFileName]] && [IsAFile [file tail $fsBoxFileName]]} { set fsBox(name) [file tail $fsBoxFileName] } { set fsBox(name) "" } if {[file exists $fsBoxFileName] && [IsADir $fsBoxFileName]} { set fsBox(path) $fsBoxFileName } { if {"[file rootname $fsBoxFileName]" != "."} { set fsBox(path) [file rootname $fsBoxFileName] } } if {$fsBox(showPixmap)} { set fsBox(path) [string trimleft $fsBox(path) @] } if {"$fsBox(path)" != "" && [file exists $fsBox(path)] && [IsADir $fsBox(path)]} { set fsBox(internalPath) $fsBox(path) } { if {"$fsBox(internalPath)" == "" || ![file exists $fsBox(internalPath)]} { set fsBox(internalPath) [pwd] } } # build widget structure # start build of toplevel if {"[info commands XFDestroy]" != ""} { catch {XFDestroy .fsBox} } { catch {destroy .fsBox} } toplevel .fsBox -borderwidth 0 catch ".fsBox config $tmpFrameOpt" wm geometry .fsBox 350x300 wm title .fsBox {File select box} wm maxsize .fsBox 1000 1000 wm minsize .fsBox 100 100 # end build of toplevel label .fsBox.message1 -anchor c -relief raised -text "$fsBoxMessage" catch ".fsBox.message1 config $tmpMessageOpt" frame .fsBox.frame1 -borderwidth 0 -relief raised catch ".fsBox.frame1 config $tmpFrameOpt" button .fsBox.frame1.ok -text "OK" -command " global fsBox set fsBox(name) \[.fsBox.file.file get\] if {$fsBox(showPixmap)} { set fsBox(path) @\[.fsBox.path.path get\] } { set fsBox(path) \[.fsBox.path.path get\] } set fsBox(internalPath) \[.fsBox.path.path get\] $fsBoxActionOk if {\"\[info commands XFDestroy\]\" != \"\"} { catch {XFDestroy .fsBox} } { catch {destroy .fsBox} }" catch ".fsBox.frame1.ok config $tmpButtonOpt" button .fsBox.frame1.rescan -text "Rescan" -command { global fsBox FSBoxFSShow [.fsBox.path.path get] [.fsBox.pattern.pattern get] $fsBox(all)} catch ".fsBox.frame1.rescan config $tmpButtonOpt" button .fsBox.frame1.cancel -text "Cancel" -command " global fsBox set fsBox(name) {} set fsBox(path) {} $fsBoxActionCancel if {\"\[info commands XFDestroy\]\" != \"\"} { catch {XFDestroy .fsBox} } { catch {destroy .fsBox} }" catch ".fsBox.frame1.cancel config $tmpButtonOpt" if {$fsBox(showPixmap)} { frame .fsBox.frame2 -borderwidth 0 -relief raised catch ".fsBox.frame2 config $tmpFrameOpt" scrollbar .fsBox.frame2.scrollbar3 -command {.fsBox.frame2.canvas2 xview} -orient {horizontal} -relief {raised} catch ".fsBox.frame2.scrollbar3 config $tmpScrollOpt" scrollbar .fsBox.frame2.scrollbar1 -command {.fsBox.frame2.canvas2 yview} -relief {raised} catch ".fsBox.frame2.scrollbar1 config $tmpScrollOpt" canvas .fsBox.frame2.canvas2 -confine {true} -relief {raised} -scrollregion {0c 0c 20c 20c} -width {100} -xscrollcommand {.fsBox.frame2.scrollbar3 set} -yscrollcommand {.fsBox.frame2.scrollbar1 set} catch ".fsBox.frame2.canvas2 config $tmpFrameOpt" .fsBox.frame2.canvas2 addtag currentBitmap withtag [.fsBox.frame2.canvas2 create bitmap 5 5 -anchor nw] } frame .fsBox.path -borderwidth 0 -relief raised catch ".fsBox.path config $tmpFrameOpt" frame .fsBox.path.paths -borderwidth 2 -relief raised catch ".fsBox.path.paths config $tmpFrameOpt" menubutton .fsBox.path.paths.paths -borderwidth 0 -menu ".fsBox.path.paths.paths.menu" -relief flat -text "Pathname:" catch ".fsBox.path.paths.paths config $tmpButtonOpt" menu .fsBox.path.paths.paths.menu catch ".fsBox.path.paths.paths.menu config $tmpButtonOpt" .fsBox.path.paths.paths.menu add command -label "[string trimright $fsBox(internalPath) {/@}]" -command " global fsBox FSBoxFSShow \[.fsBox.path.path get\] \[.fsBox.pattern.pattern get\] \$fsBox(all) .fsBox.path.path delete 0 end .fsBox.path.path insert 0 [string trimright $fsBox(internalPath) {/@}]" entry .fsBox.path.path -relief raised catch ".fsBox.path.path config $tmpMessageOpt" if {![IsADir $fsBox(internalPath)]} { set $fsBox(internalPath) [pwd] } .fsBox.path.path insert 0 $fsBox(internalPath) frame .fsBox.pattern -borderwidth 0 -relief raised catch ".fsBox.pattern config $tmpFrameOpt" frame .fsBox.pattern.patterns -borderwidth 2 -relief raised catch ".fsBox.pattern.patterns config $tmpFrameOpt" menubutton .fsBox.pattern.patterns.patterns -borderwidth 0 -menu ".fsBox.pattern.patterns.patterns.menu" -relief flat -text "Selection pattern:" catch ".fsBox.pattern.patterns.patterns config $tmpButtonOpt" menu .fsBox.pattern.patterns.patterns.menu catch ".fsBox.pattern.patterns.patterns.menu config $tmpButtonOpt" .fsBox.pattern.patterns.patterns.menu add checkbutton -label "Scan extensions" -variable fsBoxExtensions -command { global fsBox FSBoxFSShow [.fsBox.path.path get] [.fsBox.pattern.pattern get] $fsBox(all)} entry .fsBox.pattern.pattern -relief raised catch ".fsBox.pattern.pattern config $tmpMessageOpt" .fsBox.pattern.pattern insert 0 $fsBox(pattern) frame .fsBox.files -borderwidth 0 -relief raised catch ".fsBox.files config $tmpFrameOpt" scrollbar .fsBox.files.vscroll -relief raised -command ".fsBox.files.files yview" catch ".fsBox.files.vscroll config $tmpScrollOpt" scrollbar .fsBox.files.hscroll -orient horiz -relief raised -command ".fsBox.files.files xview" catch ".fsBox.files.hscroll config $tmpScrollOpt" listbox .fsBox.files.files -exportselection false -relief raised -xscrollcommand ".fsBox.files.hscroll set" -yscrollcommand ".fsBox.files.vscroll set" catch ".fsBox.files.files config $tmpMessageOpt" frame .fsBox.file -borderwidth 0 -relief raised catch ".fsBox.file config $tmpFrameOpt" label .fsBox.file.labelfile -relief raised -text "Filename:" catch ".fsBox.file.labelfile config $tmpMessageOpt" entry .fsBox.file.file -relief raised catch ".fsBox.file.file config $tmpMessageOpt" .fsBox.file.file delete 0 end .fsBox.file.file insert 0 $fsBox(name) checkbutton .fsBox.pattern.all -offvalue 0 -onvalue 1 -text "Show all files" -variable fsBox(all) -command { global fsBox FSBoxFSShow [.fsBox.path.path get] [.fsBox.pattern.pattern get] $fsBox(all)} catch ".fsBox.pattern.all config $tmpButtonOpt" FSBoxFSShow $fsBox(internalPath) $fsBox(pattern) $fsBox(all) # bindings bind .fsBox.files.files " FSBoxFSFileSelectDouble %W $fsBox(showPixmap) \{$fsBoxActionOk\} %y" bind .fsBox.files.files " FSBoxFSFileSelect %W $fsBox(showPixmap) %y" bind .fsBox.files.files " FSBoxFSFileSelect %W $fsBox(showPixmap) %y" bind .fsBox.files.files " FSBoxFSFileSelect %W $fsBox(showPixmap) %y" bind .fsBox.files.files " FSBoxFSFileSelect %W $fsBox(showPixmap) %y" bind .fsBox.path.path { FSBoxFSNameComplete path} bind .fsBox.path.path { global tkVersion global fsBox FSBoxFSShow [.fsBox.path.path get] [.fsBox.pattern.pattern get] $fsBox(all) FSBoxFSInsertPath if {$tkVersion >= 3.0} { .fsBox.file.file icursor end } { .fsBox.file.file cursor end } focus .fsBox.file.file} catch "bind .fsBox.path.path {}" bind .fsBox.path.path { global tkVersion if {$tkVersion >= 3.0} { .fsBox.file.file icursor end } { .fsBox.file.file cursor end } focus .fsBox.file.file} bind .fsBox.file.file { FSBoxFSNameComplete file} bind .fsBox.file.file " global fsBox set fsBox(name) \[.fsBox.file.file get\] if {$fsBox(showPixmap)} { set fsBox(path) @\[.fsBox.path.path get\] } { set fsBox(path) \[.fsBox.path.path get\] } set fsBox(internalPath) \[.fsBox.path.path get\] $fsBoxActionOk if {\"\[info commands XFDestroy\]\" != \"\"} { catch {XFDestroy .fsBox} } { catch {destroy .fsBox} }" bind .fsBox.file.file { global tkVersion if {$tkVersion >= 3.0} { .fsBox.path.path icursor end } { .fsBox.path.path cursor end } focus .fsBox.path.path} bind .fsBox.file.file { global tkVersion if {$tkVersion >= 3.0} { .fsBox.pattern.pattern icursor end } { .fsBox.pattern.pattern cursor end } focus .fsBox.pattern.pattern} bind .fsBox.pattern.pattern { global fsBox FSBoxFSShow [.fsBox.path.path get] [.fsBox.pattern.pattern get] $fsBox(all)} bind .fsBox.pattern.pattern { global tkVersion if {$tkVersion >= 3.0} { .fsBox.file.file icursor end } { .fsBox.file.file cursor end } focus .fsBox.file.file} catch "bind .fsBox.pattern.pattern {}" # packing pack append .fsBox.files .fsBox.files.vscroll "$fsBox(scrollSide) filly" .fsBox.files.hscroll {bottom fillx} .fsBox.files.files {left fill expand} pack append .fsBox.file .fsBox.file.labelfile {left} .fsBox.file.file {left fill expand} pack append .fsBox.frame1 .fsBox.frame1.ok {left fill expand} .fsBox.frame1.rescan {left fill expand} .fsBox.frame1.cancel {left fill expand} pack append .fsBox.path.paths .fsBox.path.paths.paths {left} pack append .fsBox.pattern.patterns .fsBox.pattern.patterns.patterns {left} pack append .fsBox.path .fsBox.path.paths {left} .fsBox.path.path {left fill expand} pack append .fsBox.pattern .fsBox.pattern.patterns {left} .fsBox.pattern.all {right fill} .fsBox.pattern.pattern {left fill expand} if {$fsBox(showPixmap)} { pack append .fsBox.frame2 .fsBox.frame2.scrollbar1 {left filly} .fsBox.frame2.canvas2 {top expand fill} .fsBox.frame2.scrollbar3 {top fillx} pack append .fsBox .fsBox.message1 {top fill} .fsBox.frame1 {bottom fill} .fsBox.pattern {bottom fill} .fsBox.file {bottom fill} .fsBox.path {bottom fill} .fsBox.frame2 {right fill} .fsBox.files {left fill expand} } { pack append .fsBox .fsBox.message1 {top fill} .fsBox.frame1 {bottom fill} .fsBox.pattern {bottom fill} .fsBox.file {bottom fill} .fsBox.path {bottom fill} .fsBox.files {left fill expand} } if {"$fsBoxActionOk" == "" && "$fsBoxActionCancel" == ""} { # wait for the box to be destroyed update idletask grab .fsBox tkwait window .fsBox if {"[string trim $fsBox(path)]" != "" || "[string trim $fsBox(name)]" != ""} { if {"[string trimleft [string trim $fsBox(name)] /]" == ""} { return [string trimright [string trim $fsBox(path)] /] } { return [string trimright [string trim $fsBox(path)] /]/[string trimleft [string trim $fsBox(name)] /] } } } } # Procedure: FSBoxBindSelectOne proc FSBoxBindSelectOne { fsBoxW fsBoxY} { # xf ignore me 6 set fsBoxNearest [$fsBoxW nearest $fsBoxY] if {$fsBoxNearest >= 0} { $fsBoxW select from $fsBoxNearest $fsBoxW select to $fsBoxNearest } } # Procedure: FSBoxFSFileSelect proc FSBoxFSFileSelect { fsBoxW fsBoxShowPixmap fsBoxY} { # xf ignore me 6 global fsBox FSBoxBindSelectOne $fsBoxW $fsBoxY set fsBoxNearest [$fsBoxW nearest $fsBoxY] if {$fsBoxNearest >= 0} { set fsBoxTmpEntry [$fsBoxW get $fsBoxNearest] if {"[string index $fsBoxTmpEntry [expr [string length $fsBoxTmpEntry]-1]]" == "/" || "[string index $fsBoxTmpEntry [expr [string length $fsBoxTmpEntry]-1]]" == "@"} { set fsBoxFileName [string range $fsBoxTmpEntry 0 [expr [string length $fsBoxTmpEntry]-2]] if {![IsADir [string trimright $fsBox(internalPath)/$fsBoxFileName @]] && ![IsASymlink [string trimright $fsBox(internalPath)/$fsBoxFileName @]]} { set fsBoxFileName $fsBoxTmpEntry } } { if {"[string index $fsBoxTmpEntry [expr [string length $fsBoxTmpEntry]-1]]" == "*"} { set fsBoxFileName [string range $fsBoxTmpEntry 0 [expr [string length $fsBoxTmpEntry]-2]] if {![file executable $fsBox(internalPath)/$fsBoxFileName]} { set fsBoxFileName $fsBoxTmpEntry } } { set fsBoxFileName $fsBoxTmpEntry } } if {![IsADir [string trimright $fsBox(internalPath)/$fsBoxFileName @]]} { set fsBox(name) $fsBoxFileName .fsBox.file.file delete 0 end .fsBox.file.file insert 0 $fsBox(name) if {$fsBoxShowPixmap} { catch ".fsBox.frame2.canvas2 itemconfigure currentBitmap -bitmap \"@$fsBox(internalPath)/$fsBox(name)\"" } } } } # Procedure: FSBoxFSFileSelectDouble proc FSBoxFSFileSelectDouble { fsBoxW fsBoxShowPixmap fsBoxAction fsBoxY} { # xf ignore me 6 global fsBox FSBoxBindSelectOne $fsBoxW $fsBoxY set fsBoxNearest [$fsBoxW nearest $fsBoxY] if {$fsBoxNearest >= 0} { set fsBoxTmpEntry [$fsBoxW get $fsBoxNearest] if {"$fsBoxTmpEntry" == "../"} { set fsBoxTmpEntry [string trimright [string trim $fsBox(internalPath)] "@/"] if {"$fsBoxTmpEntry" == ""} { return } FSBoxFSShow [file dirname $fsBoxTmpEntry] [.fsBox.pattern.pattern get] $fsBox(all) .fsBox.path.path delete 0 end .fsBox.path.path insert 0 $fsBox(internalPath) } { if {"[string index $fsBoxTmpEntry [expr [string length $fsBoxTmpEntry]-1]]" == "/" || "[string index $fsBoxTmpEntry [expr [string length $fsBoxTmpEntry]-1]]" == "@"} { set fsBoxFileName [string range $fsBoxTmpEntry 0 [expr [string length $fsBoxTmpEntry]-2]] if {![IsADir [string trimright $fsBox(internalPath)/$fsBoxFileName @]] && ![IsASymlink [string trimright $fsBox(internalPath)/$fsBoxFileName @]]} { set fsBoxFileName $fsBoxTmpEntry } } { if {"[string index $fsBoxTmpEntry [expr [string length $fsBoxTmpEntry]-1]]" == "*"} { set fsBoxFileName [string range $fsBoxTmpEntry 0 [expr [string length $fsBoxTmpEntry]-2]] if {![file executable $fsBox(internalPath)/$fsBoxFileName]} { set fsBoxFileName $fsBoxTmpEntry } } { set fsBoxFileName $fsBoxTmpEntry } } if {[IsADir [string trimright $fsBox(internalPath)/$fsBoxFileName @]]} { set fsBox(internalPath) "[string trimright $fsBox(internalPath) {/@}]/$fsBoxFileName" FSBoxFSShow $fsBox(internalPath) [.fsBox.pattern.pattern get] $fsBox(all) .fsBox.path.path delete 0 end .fsBox.path.path insert 0 $fsBox(internalPath) } { set fsBox(name) $fsBoxFileName if {$fsBoxShowPixmap} { set fsBox(path) @$fsBox(internalPath) } { set fsBox(path) $fsBox(internalPath) } if {"$fsBoxAction" != ""} { eval "global fsBox; $fsBoxAction" } if {"[info commands XFDestroy]" != ""} { catch {XFDestroy .fsBox} } { catch {destroy .fsBox} } } } } } # Procedure: FSBoxFSInsertPath proc FSBoxFSInsertPath {} { # xf ignore me 6 global fsBox set fsBoxLast [.fsBox.path.paths.paths.menu index last] set fsBoxNewEntry [string trimright [.fsBox.path.path get] "/@"] for {set fsBoxCounter 0} {$fsBoxCounter <= $fsBoxLast} {incr fsBoxCounter 1} { if {"$fsBoxNewEntry" == "[lindex [.fsBox.path.paths.paths.menu entryconfigure $fsBoxCounter -label] 4]"} { return } } if {$fsBoxLast < 9} { .fsBox.path.paths.paths.menu add command -label "$fsBoxNewEntry" -command " global fsBox FSBoxFSShow $fsBoxNewEntry \[.fsBox.pattern.pattern get\] \$fsBox(all) .fsBox.path.path delete 0 end .fsBox.path.path insert 0 $fsBoxNewEntry" } { for {set fsBoxCounter 0} {$fsBoxCounter < $fsBoxLast} {incr fsBoxCounter 1} { .fsBox.path.paths.paths.menu entryconfigure $fsBoxCounter -label [lindex [.fsBox.path.paths.paths.menu entryconfigure [expr $fsBoxCounter+1] -label] 4] .fsBox.path.paths.paths.menu entryconfigure $fsBoxCounter -command " global fsBox FSBoxFSShow [lindex [.fsBox.path.paths.paths.menu entryconfigure [expr $fsBoxCounter+1] -label] 4] \[.fsBox.pattern.pattern get\] \$fsBox(all) .fsBox.path.path delete 0 end .fsBox.path.path insert 0 [lindex [.fsBox.path.paths.paths.menu entryconfigure [expr $fsBoxCounter+1] -label] 4]" } .fsBox.path.paths.paths.menu entryconfigure $fsBoxLast -label "$fsBoxNewEntry" .fsBox.path.paths.paths.menu entryconfigure $fsBoxCounter -command " global fsBox FSBoxFSShow \[.fsBox.path.path get\] \[.fsBox.pattern.pattern get\] \$fsBox(all) .fsBox.path.path delete 0 end .fsBox.path.path insert 0 $fsBoxNewEntry" } } # Procedure: FSBoxFSNameComplete proc FSBoxFSNameComplete { fsBoxType} { # xf ignore me 6 global tkVersion global fsBox set fsBoxNewFile "" if {"$fsBoxType" == "path"} { set fsBoxDirName [file dirname [.fsBox.path.path get]] set fsBoxFileName [file tail [.fsBox.path.path get]] } { set fsBoxDirName [file dirname [.fsBox.path.path get]/] set fsBoxFileName [file tail [.fsBox.file.file get]] } set fsBoxNewFile "" if {[IsADir [string trimright $fsBoxDirName @]]} { catch "glob -nocomplain $fsBoxDirName/${fsBoxFileName}*" fsBoxResult foreach fsBoxCounter $fsBoxResult { if {"$fsBoxNewFile" == ""} { set fsBoxNewFile [file tail $fsBoxCounter] } { if {"[string index [file tail $fsBoxCounter] 0]" != "[string index $fsBoxNewFile 0]"} { set fsBoxNewFile "" break } set fsBoxCounter1 0 set fsBoxTmpFile1 $fsBoxNewFile set fsBoxTmpFile2 [file tail $fsBoxCounter] set fsBoxLength1 [string length $fsBoxTmpFile1] set fsBoxLength2 [string length $fsBoxTmpFile2] set fsBoxNewFile "" if {$fsBoxLength1 > $fsBoxLength2} { set fsBoxLength1 $fsBoxLength2 } while {$fsBoxCounter1 < $fsBoxLength1} { if {"[string index $fsBoxTmpFile1 $fsBoxCounter1]" == "[string index $fsBoxTmpFile2 $fsBoxCounter1]"} { append fsBoxNewFile [string index $fsBoxTmpFile1 $fsBoxCounter1] } { break } incr fsBoxCounter1 1 } } } } if {"$fsBoxNewFile" != ""} { if {[IsADir [string trimright $fsBoxDirName/$fsBoxNewFile @]] || ![IsAFile [string trimright $fsBoxDirName/$fsBoxNewFile @]]} { if {[IsADir [string trimright $fsBoxDirName/$fsBoxNewFile @]]} { if {"$fsBoxDirName" == "/"} { .fsBox.path.path delete 0 end .fsBox.path.path insert 0 "/[string trimright [string trim $fsBoxNewFile /] @]/" } { .fsBox.path.path delete 0 end .fsBox.path.path insert 0 "[string trimright $fsBoxDirName /]/[string trimright [string trim $fsBoxNewFile /] @]/" } FSBoxFSShow [.fsBox.path.path get] [.fsBox.pattern.pattern get] $fsBox(all) FSBoxFSInsertPath } { .fsBox.path.path delete 0 end .fsBox.path.path insert 0 "[string trimright $fsBoxDirName /]/[string trimright [string trim $fsBoxNewFile /] @]" } } { .fsBox.path.path delete 0 end .fsBox.path.path insert 0 "[string trimright $fsBoxDirName {@/}]/" .fsBox.file.file delete 0 end .fsBox.file.file insert 0 $fsBoxNewFile if {$tkVersion >= 3.0} { .fsBox.file.file icursor end } { .fsBox.file.file cursor end } focus .fsBox.file.file } } } # Procedure: FSBoxFSShow proc FSBoxFSShow { fsBoxPath fsBoxPattern fsBoxAll} { # xf ignore me 6 global fsBox set tmpButtonOpt "" if {"$fsBox(activeBackground)" != ""} { append tmpButtonOpt "-activebackground \"$fsBox(activeBackground)\" " } if {"$fsBox(activeForeground)" != ""} { append tmpButtonOpt "-activeforeground \"$fsBox(activeForeground)\" " } if {"$fsBox(background)" != ""} { append tmpButtonOpt "-background \"$fsBox(background)\" " } if {"$fsBox(font)" != ""} { append tmpButtonOpt "-font \"$fsBox(font)\" " } if {"$fsBox(foreground)" != ""} { append tmpButtonOpt "-foreground \"$fsBox(foreground)\" " } set fsBox(pattern) $fsBoxPattern if {[file exists $fsBoxPath] && [file readable $fsBoxPath] && [IsADir $fsBoxPath]} { set fsBox(internalPath) $fsBoxPath } { if {[file exists $fsBoxPath] && [file readable $fsBoxPath] && [IsAFile $fsBoxPath]} { set fsBox(internalPath) [file dirname $fsBoxPath] .fsBox.file.file delete 0 end .fsBox.file.file insert 0 [file tail $fsBoxPath] set fsBoxPath $fsBox(internalPath) } { while {"$fsBoxPath" != "" && "$fsBoxPath" != "/" && ![file isdirectory $fsBoxPath]} { set fsBox(internalPath) [file dirname $fsBoxPath] set fsBoxPath $fsBox(internalPath) } } } if {"$fsBoxPath" == ""} { set fsBoxPath "/" set fsBox(internalPath) "/" } .fsBox.path.path delete 0 end .fsBox.path.path insert 0 $fsBox(internalPath) if {[.fsBox.files.files size] > 0} { .fsBox.files.files delete 0 end } if {$fsBoxAll} { if {[catch "exec ls -F -a $fsBoxPath" fsBoxResult]} { puts stderr "$fsBoxResult" } } { if {[catch "exec ls -F $fsBoxPath" fsBoxResult]} { puts stderr "$fsBoxResult" } } set fsBoxElementList [lsort $fsBoxResult] foreach fsBoxCounter [winfo children .fsBox.pattern.patterns.patterns] { if {[string length [info commands XFDestroy]] > 0} { catch {XFDestroy $fsBoxCounter} } { catch {destroy $fsBoxCounter} } } menu .fsBox.pattern.patterns.patterns.menu catch ".fsBox.pattern.patterns.patterns.menu config $tmpButtonOpt" if {$fsBox(extensions)} { .fsBox.pattern.patterns.patterns.menu add command -label "*" -command { global fsBox set fsBox(pattern) "*" .fsBox.pattern.pattern delete 0 end .fsBox.pattern.pattern insert 0 $fsBox(pattern) FSBoxFSShow [.fsBox.path.path get] $fsBox(pattern) $fsBox(all)} } if {"$fsBoxPath" != "/"} { .fsBox.files.files insert end "../" } foreach fsBoxCounter $fsBoxElementList { if {[string match $fsBoxPattern $fsBoxCounter] || [IsADir [string trimright $fsBoxPath/$fsBoxCounter "/@"]]} { if {"$fsBoxCounter" != "../" && "$fsBoxCounter" != "./"} { .fsBox.files.files insert end $fsBoxCounter } } if {$fsBox(extensions)} { catch "file rootname $fsBoxCounter" fsBoxRootName catch "file extension $fsBoxCounter" fsBoxExtension set fsBoxExtension [string trimright $fsBoxExtension "/*@"] if {"$fsBoxExtension" != "" && "$fsBoxRootName" != ""} { set fsBoxInsert 1 set fsBoxLast [.fsBox.pattern.patterns.patterns.menu index last] for {set fsBoxCounter1 0} {$fsBoxCounter1 <= $fsBoxLast} {incr fsBoxCounter1 1} { if {"*$fsBoxExtension" == "[lindex [.fsBox.pattern.patterns.patterns.menu entryconfigure $fsBoxCounter1 -label] 4]"} { set fsBoxInsert 0 } } if {$fsBoxInsert} { .fsBox.pattern.patterns.patterns.menu add command -label "*$fsBoxExtension" -command " global fsBox set fsBox(pattern) \"*$fsBoxExtension\" .fsBox.pattern.pattern delete 0 end .fsBox.pattern.pattern insert 0 \$fsBox(pattern) FSBoxFSShow \[.fsBox.path.path get\] \$fsBox(pattern) \$fsBox(all)" } } } } if {$fsBox(extensions)} { .fsBox.pattern.patterns.patterns.menu add separator } if {$fsBox(extensions) || "[.fsBox.pattern.patterns.patterns.menu index last]" == "none"} { .fsBox.pattern.patterns.patterns.menu add checkbutton -label "Scan extensions" -variable "fsBox(extensions)" -command { global fsBox FSBoxFSShow [.fsBox.path.path get] [.fsBox.pattern.pattern get] $fsBox(all)} } } # Procedure: GetDatabases proc GetDatabases {} { set db template1 set query "retrieve (db.datname) from db in pg_database" set databases [retrieve_records $db $query] return $databases } # Procedure: InitAttr proc InitAttr {} { global currentdb global list3 set classnr [classlist curselection] # check if there is a selection made in the classlist if {$classnr != ""} { set classname [classlist get $classnr] set query [format "retrieve (a.attname) from a in pg_attribute, c in pg_class where a.attrelid = c.oid and c.relname = \"%s\"" $classname] # get attributes from postgres data dictionary set attributes [retrieve_records $currentdb $query] # delete all entries in middle and right listbox attrlist delete 0 end valuelist delete 0 end # store them in the middle listbox set nrofattr [llength $attributes] loop att 0 $nrofattr 1 { set tuple [lindex $attributes $att] keylget tuple attname attname attrlist insert end $attname } } } # Procedure: InitDB proc InitDB {} { global currentdb set query "retrieve (c.relname) from c in pg_class" set classes [retrieve_records $currentdb $query] set nrofcls [llength $classes] #delete all entries in classlistbox, attributelistbox and valuelistbox classlist delete 0 end attrlist delete 0 end valuelist delete 0 end funclist delete 0 end loop cl 0 $nrofcls 1 { set class [lindex $classes $cl] keylget class relname classname #add entry to listbox classlist insert end $classname } } # Procedure: InitFunc proc InitFunc {} { global currentdb set curclass [classlist curselection] if { ($curclass != "") } { set classname [classlist get $curclass] set query [format "retrieve (p.proname) from p in pg_proc where pg_type.typname = \"%s\" and pg_type.oid = p.proargtypes\[1\]" $classname] set result [retrieve_records $currentdb $query] set nroftuples [llength $result] # empty value listbox funclist delete 0 end # store result in listbox loop t 0 $nroftuples 1 { set tuple [lindex $result $t] keylget tuple proname value funclist insert end $value } } } # Procedure: InitValues proc InitValues {} { global currentdb set curclass [classlist curselection] set curattr [attrlist curselection] if { ($curclass != "") && ($curattr != "") } { set classname [classlist get $curclass] set attribute [attrlist get $curattr] set query [format "retrieve (c.%s) from c in %s" $attribute $classname] set result [retrieve_records $currentdb $query] set nroftuples [llength $result] # empty value listbox valuelist delete 0 end # store result in listbox loop t 0 $nroftuples 1 { set tuple [lindex $result $t] keylget tuple $attribute value valuelist insert end $value } } } # Procedure: IsADir proc IsADir { pathName} { # xf ignore me 5 ########## # Procedure: IsADir # Description: check if name is a directory (including symbolic links) # Arguments: pathName - the path to check # Returns: 1 if its a directory, otherwise 0 # Sideeffects: none ########## if {[file isdirectory $pathName]} { return 1 } { catch "file type $pathName" fileType if {"$fileType" == "link"} { if {[catch "file readlink $pathName" linkName]} { return 0 } catch "file type $linkName" fileType while {"$fileType" == "link"} { if {[catch "file readlink $linkName" linkName]} { return 0 } catch "file type $linkName" fileType } return [file isdirectory $linkName] } } return 0 } # Procedure: IsAFile proc IsAFile { fileName} { # xf ignore me 5 ########## # Procedure: IsAFile # Description: check if filename is a file (including symbolic links) # Arguments: fileName - the filename to check # Returns: 1 if its a file, otherwise 0 # Sideeffects: none ########## if {[file isfile $fileName]} { return 1 } { catch "file type $fileName" fileType if {"$fileType" == "link"} { if {[catch "file readlink $fileName" linkName]} { return 0 } catch "file type $linkName" fileType while {"$fileType" == "link"} { if {[catch "file readlink $linkName" linkName]} { return 0 } catch "file type $linkName" fileType } return [file isfile $linkName] } } return 0 } # Procedure: IsASymlink proc IsASymlink { fileName} { # xf ignore me 5 ########## # Procedure: IsASymlink # Description: check if filename is a symbolic link # Arguments: fileName - the path/filename to check # Returns: none # Sideeffects: none ########## catch "file type $fileName" fileType if {"$fileType" == "link"} { return 1 } return 0 } # Procedure: PQinterprete proc PQinterprete { res} { if {[string range $res 0 0] == "E"} { AlertBox [format "Postgres returned error: %s" $res] return } if {[string range $res 0 0] != "P"} { return } set portalname [string range $res 1 end] set hportal [PQparray $portalname] set ngroups [PQngroups $hportal] loop grpno 0 $ngroups 1 { set ntups [PQntuplesGroup $hportal $grpno] set nfields [PQnfieldsGroup $hportal $grpno] loop tupno 0 $ntups 1 { loop fldno 0 $nfields 1 { set fldname [PQfnameGroup $hportal $grpno $fldno] set fldvalue [PQgetvalue $hportal $tupno $fldno] qtext insert end [format "\n%s: %s" $fldname $fldvalue] } qtext insert end [format "\n-------------------------------------"] } qtext insert end [format "\n"] qtext mark set insert end qtext tag remove sel 1.0 end } } # Procedure: PQinterprete.old proc PQinterprete.old { res} { if {[string range $res 0 0] == "E"} { AlertBox [format "Postgres returned error: %s" $res] return } if {[string range $res 0 0] != "P"} { return } set portalname [string range $res 1 end] set hportal [PQparray $portalname] set ngroups [PQngroups $hportal] loop grpno 0 $ngroups 1 { set ntups [PQntuplesGroup $hportal $grpno] set nfields [PQnfieldsGroup $hportal $grpno] loop tupno 0 $ntups 1 { loop fldno 0 $nfields 1 { set fldname [PQfnameGroup $hportal $grpno $fldno] set fldvalue [PQgetvalue $hportal $tupno $fldno] keylset record $fldname $fldvalue } lappend records $record } } return $records } # Procedure: PrintSrc proc PrintSrc {} { global currentdb set curproc [funclist curselection] if { ($curproc != "") } { set procname [funclist get $curproc] set query [format "retrieve (p.prosrc) from p in pg_proc where p.proname = \"%s\"" $procname] set result [retrieve_records $currentdb $query] set tuple [lindex $result 0] keylget tuple prosrc value qtext insert end [format "\nsourcecode for %s:\n%s\n" $procname $value] } } # Procedure: Rescan proc Rescan {} { # remember the views and selections in the listboxes set sel_class [classlist curselection] set sel_attr [attrlist curselection] set sel_val [valuelist curselection] set top_class [classlist nearest 1] set top_attr [attrlist nearest 1] set top_val [valuelist nearest 1] set sel_func [funclist curselection] set top_func [funclist nearest 1] # rescan the database and reposition the listboxes InitDB if {$sel_class != ""} { classlist select to $sel_class classlist yview $top_class InitAttr if {$sel_attr != ""} { attrlist select to $sel_attr attrlist yview $top_attr InitValues if {$sel_val != ""} { valuelist select to $sel_val valuelist yview $top_val } } InitFunc if {$sel_func != ""} { funclist select to $sel_func funclist yview $top_func } } } # Procedure: SaveText proc SaveText {} { set file [FSBox "Select Outputfile:" "result.txt"] if {$file != ""} { set text [qtext get 1.0 end] set fileid [open $file w] puts $fileid $text close $fileid } } # Procedure: SendQuery proc SendQuery {} { global currentdb global PreviousQuery global auto_rescan if {[qtext tag nextrange sel 1.0 end] == ""} { return } set query [qtext get sel.first sel.last] if {$query != ""} { set PreviousQuery $query PQsetdb $currentdb set result [PQexec $query] PQinterprete $result if {$auto_rescan == "on"} { Rescan } } } # Procedure: SetDBMenu proc SetDBMenu {} { global databases set nrofdbs [llength $databases] # delete entries databasemenu delete 0 last # entry for creation of new database databasemenu add command -label "Rescan" -command {global databases; set databases [GetDatabases]; SetDBMenu; InitDB} databasemenu add separator loop db 0 $nrofdbs 1 { # get list element containing {datname $dbname} set db [lindex $databases $db] keylget db datname dbname databasemenu add radiobutton -label $dbname -value $dbname -variable currentdb -command {InitDB} } } # Procedure: YesNoBox proc YesNoBox { {yesNoBoxMessage "Yes/no message"} {yesNoBoxGeometry "350x150"}} { # xf ignore me 9 ########## # Procedure: YesNoBox # Description: show yesno box # Arguments: {yesNoBoxMessage} - the text to display # {yesNoBoxGeometry} - the geometry for the window # Returns: none # Sideeffects: none ########## # # global yesNoBox(activeBackground) - active background color # global yesNoBox(activeForeground) - active foreground color # global yesNoBox(anchor) - anchor for message box # global yesNoBox(background) - background color # global yesNoBox(font) - message font # global yesNoBox(foreground) - foreground color # global yesNoBox(justify) - justify for message box # global yesNoBox(afterNo) - destroy yes-no box after n seconds. # The no button is activated # global yesNoBox(afterYes) - destroy yes-no box after n seconds. # The yes button is activated global yesNoBox set tmpButtonOpt "" set tmpFrameOpt "" set tmpMessageOpt "" if {"$yesNoBox(activeBackground)" != ""} { append tmpButtonOpt "-activebackground \"$yesNoBox(activeBackground)\" " } if {"$yesNoBox(activeForeground)" != ""} { append tmpButtonOpt "-activeforeground \"$yesNoBox(activeForeground)\" " } if {"$yesNoBox(background)" != ""} { append tmpButtonOpt "-background \"$yesNoBox(background)\" " append tmpFrameOpt "-background \"$yesNoBox(background)\" " append tmpMessageOpt "-background \"$yesNoBox(background)\" " } if {"$yesNoBox(font)" != ""} { append tmpButtonOpt "-font \"$yesNoBox(font)\" " append tmpMessageOpt "-font \"$yesNoBox(font)\" " } if {"$yesNoBox(foreground)" != ""} { append tmpButtonOpt "-foreground \"$yesNoBox(foreground)\" " append tmpMessageOpt "-foreground \"$yesNoBox(foreground)\" " } # start build of toplevel if {"[info commands XFDestroy]" != ""} { catch {XFDestroy .yesNoBox} } { catch {destroy .yesNoBox} } toplevel .yesNoBox -borderwidth 0 catch ".yesNoBox config $tmpFrameOpt" if {[catch "wm geometry .yesNoBox $yesNoBoxGeometry"]} { wm geometry .yesNoBox 350x150 } wm title .yesNoBox {Alert box} wm maxsize .yesNoBox 1000 1000 wm minsize .yesNoBox 100 100 # end build of toplevel message .yesNoBox.message1 -anchor "$yesNoBox(anchor)" -justify "$yesNoBox(justify)" -relief raised -text "$yesNoBoxMessage" catch ".yesNoBox.message1 config $tmpMessageOpt" set xfTmpWidth [string range $yesNoBoxGeometry 0 [expr [string first x $yesNoBoxGeometry]-1]] if {"$xfTmpWidth" != ""} { # set message size catch ".yesNoBox.message1 configure -width [expr $xfTmpWidth-10]" } { .yesNoBox.message1 configure -aspect 1500 } frame .yesNoBox.frame1 -borderwidth 0 -relief raised catch ".yesNoBox.frame1 config $tmpFrameOpt" button .yesNoBox.frame1.button0 -text "Yes" -command " global yesNoBox set yesNoBox(button) 1 if {\"\[info commands XFDestroy\]\" != \"\"} { catch {XFDestroy .yesNoBox} } { catch {destroy .yesNoBox} }" catch ".yesNoBox.frame1.button0 config $tmpButtonOpt" button .yesNoBox.frame1.button1 -text "No" -command " global yesNoBox set yesNoBox(button) 0 if {\"\[info commands XFDestroy\]\" != \"\"} { catch {XFDestroy .yesNoBox} } { catch {destroy .yesNoBox} }" catch ".yesNoBox.frame1.button1 config $tmpButtonOpt" pack append .yesNoBox.frame1 .yesNoBox.frame1.button0 {left fillx expand} .yesNoBox.frame1.button1 {left fillx expand} # packing pack append .yesNoBox .yesNoBox.frame1 {bottom fill} .yesNoBox.message1 {top fill expand} if {$yesNoBox(afterYes) != 0} { after [expr $yesNoBox(afterYes)*1000] "catch \".yesNoBox.frame1.button0 invoke\"" } if {$yesNoBox(afterNo) != 0} { after [expr $yesNoBox(afterNo)*1000] "catch \".yesNoBox.frame1.button1 invoke\"" } # wait for the box to be destroyed update idletask grab .yesNoBox tkwait window .yesNoBox return $yesNoBox(button) } # Procedure: attrentry proc attrentry { args} { #xf ignore me 4 return [eval ".frame14.frame16.entry3 $args"] } # Procedure: attrlist proc attrlist { args} { #xf ignore me 4 return [eval ".frame14.frame16.frame.listbox1 $args"] } # Procedure: autoload proc autoload { filenam args} { global TCLENV foreach i $args { set TCLENV(PROC:$i) [list F $filenam] } } # Procedure: classentry proc classentry { args} { #xf ignore me 4 return [eval ".frame14.frame15.entry4 $args"] } # Procedure: classlist proc classlist { args} { #xf ignore me 4 return [eval ".frame14.frame15.frame.listbox1 $args"] } # Procedure: databasemenu proc databasemenu { args} { #xf ignore me 4 return [eval ".frame0.menubutton1.m.m $args"] } # Procedure: delClass proc delClass { name} { global currentdb global yesNoBox YesNoBox [format "Destroy class: %s\nAre you sure?" $name] if {$yesNoBox(button) == 1} { PQsetdb $currentdb PQexec "destroy $name" InitDB } } # Procedure: funclist proc funclist { args} { #xf ignore me 4 return [eval ".frame14.frame0.frame.listbox1 $args"] } # Procedure: label3 proc label3 { args} { #xf ignore me 4 return [eval ".frame14.frame17.label20 $args"] } # Procedure: load proc load { name} { global TCLPATH errorCode if {[string first / $name] >= 0} { return [uplevel #0 source $name] } set where [searchpath $TCLPATH $name] if [lempty $where] { error "couldn't find $name in Tcl search path" "" "TCLSH FILE_NOT_FOUND" } uplevel #0 source $where } # Procedure: qtext proc qtext { args} { #xf ignore me 4 return [eval ".frame21.frame.text2 $args"] } # Procedure: retrieve_records proc retrieve_records { db query} { PQsetdb $db catch {set res [PQexec $query]} set records "" if {[string range $res 0 0] == "E"} { AlertBox [format "%s\nretrieve_record failed" $res] return } if {[string range $res 0 0] != "P"} { AlertBox [format "retrieve_records: %s no portal?\n" $res] return } set portalname [string range $res 1 end] set hportal [PQparray $portalname] set ngroups [PQngroups $hportal] loop grpno 0 $ngroups 1 { set ntups [PQntuplesGroup $hportal $grpno] set nfields [PQnfieldsGroup $hportal $grpno] loop tupno 0 $ntups 1 { loop fldno 0 $nfields 1 { set fldname [PQfnameGroup $hportal $grpno $fldno] set fldvalue [PQgetvalue $hportal $tupno $fldno] keylset record $fldname $fldvalue } lappend records $record } } PQfinish return $records } # Procedure: searchpath proc searchpath { pathlist file} { foreach dir $pathlist { if {$dir == ""} {set dir .} if {[catch {file exists $dir/$file} result] == 0 && $result} { return $dir/$file } } return {} } # Procedure: valueentry proc valueentry { args} { #xf ignore me 4 return [eval ".frame14.frame17.entry2 $args"] } # Procedure: valuelist proc valuelist { args} { #xf ignore me 4 return [eval ".frame14.frame17.frame.listbox1 $args"] } # Internal procedures # Procedure: Alias proc Alias { args} { # xf ignore me 7 ########## # Procedure: Alias # Description: establish an alias for a procedure # Arguments: args - no argument means that a list of all aliases # is returned. Otherwise the first parameter is # the alias name, and the second parameter is # the procedure that is aliased. # Returns: nothing, the command that is bound to the alias or a # list of all aliases - command pairs. # Sideeffects: internalAliasList is updated, and the alias # proc is inserted ########## global internalAliasList if {[llength $args] == 0} { return $internalAliasList } { if {[llength $args] == 1} { set xfTmpIndex [lsearch $internalAliasList "[lindex $args 0] *"] if {$xfTmpIndex != -1} { return [lindex [lindex $internalAliasList $xfTmpIndex] 1] } } { if {[llength $args] == 2} { eval "proc [lindex $args 0] {args} {#xf ignore me 4 return \[eval \"[lindex $args 1] \$args\"\]}" set xfTmpIndex [lsearch $internalAliasList "[lindex $args 0] *"] if {$xfTmpIndex != -1} { set internalAliasList [lreplace $internalAliasList $xfTmpIndex $xfTmpIndex "[lindex $args 0] [lindex $args 1]"] } { lappend internalAliasList "[lindex $args 0] [lindex $args 1]" } } { error "Alias: wrong number or args: $args" } } } } # Procedure: GetSelection if {"[info procs GetSelection]" == ""} { proc GetSelection {} { # xf ignore me 7 ########## # Procedure: GetSelection # Description: get current selection # Arguments: none # Returns: none # Sideeffects: none ########## # the save way set xfSelection "" catch "selection get" xfSelection if {"$xfSelection" == "selection doesn't exist or form \"STRING\" not defined"} { return "" } { return $xfSelection } } } # Procedure: MenuPopupAdd if {"[info procs MenuPopupAdd]" == ""} { proc MenuPopupAdd { xfW xfButton xfMenu {xfModifier ""} {xfCanvasTag ""}} { # xf ignore me 7 # the popup menu handling is from (I already gave up with popup handling :-): # # Copyright 1991,1992 by James Noble. # Everyone is granted permission to copy, modify and redistribute. # This notice must be preserved on all copies or derivates. # ########## # Procedure: MenuPopupAdd # Description: attach a popup menu to widget # Arguments: xfW - the widget # xfButton - the button we use # xfMenu - the menu to attach # {xfModifier} - a optional modifier # {xfCanvasTag} - a canvas tagOrId # Returns: none # Sideeffects: none ########## if {"$xfModifier" != ""} { set xfPressModifier "$xfModifier-" set xfMoveModifier "$xfModifier-" set xfReleaseModifier "Any-" } { set xfPressModifier "" set xfMoveModifier "" set xfReleaseModifier "" } if {"$xfCanvasTag" == ""} { if {[catch "bind $xfW \"<${xfPressModifier}ButtonPress-$xfButton>\" \"$xfMenu post %X %Y\"" xfResult]} { if {"[info commands XFProcError]" != ""} { XFProcError "$xfResult" } { puts stdout "$xfResult" } return } if {[catch "bind $xfW \"<${xfMoveModifier}B$xfButton-Motion>\" \"MenuPopupHandle $xfMenu %W %X %Y\"" xfResult]} { if {"[info commands XFProcError]" != ""} { XFProcError "$xfResult" } { puts stdout "$xfResult" } return } # we need these to counteract the effects of passive grabs :-( if {[catch "bind $xfW \"<${xfReleaseModifier}ButtonRelease-$xfButton>\" \"$xfMenu invoke active; $xfMenu unpost\"" xfResult]} { if {"[info commands XFProcError]" != ""} { XFProcError "$xfResult" } { puts stdout "$xfResult" } return } } { if {[catch "$xfW bind $xfCanvasTag \"<${xfPressModifier}ButtonPress-$xfButton>\" \"$xfMenu post %X %Y\"" xfResult]} { if {"[info commands XFProcError]" != ""} { XFProcError "$xfResult" } { puts stdout "$xfResult" } return } if {[catch "$xfW bind $xfCanvasTag \"<${xfMoveModifier}B$xfButton-Motion>\" \"MenuPopupHandle $xfMenu %W %X %Y\"" xfResult]} { if {"[info commands XFProcError]" != ""} { XFProcError "$xfResult" } { puts stdout "$xfResult" } return } # we need these to counteract the effects of passive grabs :-( if {[catch "$xfW bind $xfCanvasTag \"<${xfReleaseModifier}ButtonRelease-$xfButton>\" \"$xfMenu invoke active; $xfMenu unpost\"" xfResult]} { if {"[info commands XFProcError]" != ""} { XFProcError "$xfResult" } { puts stdout "$xfResult" } return } } } } # Procedure: MenuPopupHandle if {"[info procs MenuPopupHandle]" == ""} { proc MenuPopupHandle { xfMenu xfW xfX xfY} { # xf ignore me 7 ########## # Procedure: MenuPopupHandle # Description: handle the popup menus # Arguments: xfMenu - the menu to attach # xfW - the widget # xfX - the root x coordinate # xfY - the root x coordinate # Returns: none # Sideeffects: none ########## if {"[info commands $xfMenu]" != "" && [winfo ismapped $xfMenu]} { set xfPopMinX [winfo rootx $xfMenu] set xfPopMaxX [expr $xfPopMinX+[winfo width $xfMenu]] if {($xfX >= $xfPopMinX) && ($xfX <= $xfPopMaxX)} { $xfMenu activate @[expr $xfY-[winfo rooty $xfMenu]] } { $xfMenu activate none } } } } # Procedure: NoFunction if {"[info procs NoFunction]" == ""} { proc NoFunction { args} { # xf ignore me 7 ########## # Procedure: NoFunction # Description: do nothing (especially with scales and scrollbars) # Arguments: args - a number of ignored parameters # Returns: none # Sideeffects: none ########## } } # Procedure: SN if {"[info procs SN]" == ""} { proc SN { {xfName ""}} { # xf ignore me 7 ########## # Procedure: SN # Description: map a symbolic name to the widget path # Arguments: xfName # Returns: the symbolic name # Sideeffects: none ########## SymbolicName $xfName } } # Procedure: SymbolicName if {"[info procs SymbolicName]" == ""} { proc SymbolicName { {xfName ""}} { # xf ignore me 7 ########## # Procedure: SymbolicName # Description: map a symbolic name to the widget path # Arguments: xfName # Returns: the symbolic name # Sideeffects: none ########## global symbolicName if {"$xfName" != ""} { set xfArrayName "" append xfArrayName symbolicName ( $xfName ) if {![catch "set \"$xfArrayName\"" xfValue]} { return $xfValue } { if {"[info commands XFProcError]" != ""} { XFProcError "Unknown symbolic name:\n$xfName" } { puts stderr "XF error: unknown symbolic name:\n$xfName" } } } return "" } } # Procedure: Unalias proc Unalias { aliasName} { # xf ignore me 7 ########## # Procedure: Unalias # Description: remove an alias for a procedure # Arguments: aliasName - the alias name to remove # Returns: none # Sideeffects: internalAliasList is updated, and the alias # proc is removed ########## global internalAliasList set xfIndex [lsearch $internalAliasList "$aliasName *"] if {$xfIndex != -1} { rename $aliasName "" set internalAliasList [lreplace $internalAliasList $xfIndex $xfIndex] } } # application parsing procedure proc XFLocalParseAppDefs {xfAppDefFile} { global xfAppDefaults # basically from: Michael Moore if {[file exists $xfAppDefFile] && [file readable $xfAppDefFile] && "[file type $xfAppDefFile]" == "link"} { catch "file type $xfAppDefFile" xfType while {"$xfType" == "link"} { if {[catch "file readlink $xfAppDefFile" xfAppDefFile]} { return } catch "file type $xfAppDefFile" xfType } } if {!("$xfAppDefFile" != "" && [file exists $xfAppDefFile] && [file readable $xfAppDefFile] && "[file type $xfAppDefFile]" == "file")} { return } if {![catch "open $xfAppDefFile r" xfResult]} { set xfAppFileContents [read $xfResult] close $xfResult foreach line [split $xfAppFileContents "\n"] { # backup indicates how far to backup. It applies to the # situation where a resource name ends in . and when it # ends in *. In the second case you want to keep the * # in the widget name for pattern matching, but you want # to get rid of the . if it is the end of the name. set backup -2 set line [string trim $line] if {[string index $line 0] == "#" || "$line" == ""} { # skip comments and empty lines continue } set list [split $line ":"] set resource [string trim [lindex $list 0]] set i [string last "." $resource] set j [string last "*" $resource] if {$j > $i} { set i $j set backup -1 } incr i set name [string range $resource $i end] incr i $backup set widname [string range $resource 0 $i] set value [string trim [lindex $list 1]] if {"$widname" != "" && "$widname" != "*"} { # insert the widget and resourcename to the application # defaults list. set xfAppDefaults($widname:[string tolower $name]) $value } } } } # application loading procedure proc XFLocalLoadAppDefs {xfClasses {xfPriority "startupFile"} {xfAppDefFile ""}} { global env if {"$xfAppDefFile" == ""} { set xfFileList "" if {[info exists env(XUSERFILESEARCHPATH)]} { append xfFileList [split $env(XUSERFILESEARCHPATH) :] } if {[info exists env(XAPPLRESDIR)]} { append xfFileList [split $env(XAPPLRESDIR) :] } if {[info exists env(XFILESEARCHPATH)]} { append xfFileList [split $env(XFILESEARCHPATH) :] } append xfFileList " /usr/lib/X11/app-defaults" append xfFileList " /usr/X11/lib/X11/app-defaults" foreach xfCounter1 $xfClasses { foreach xfCounter2 $xfFileList { set xfPathName $xfCounter2 if {[regsub -all "%N" "$xfPathName" "$xfCounter1" xfResult]} { set xfPathName $xfResult } if {[regsub -all "%T" "$xfPathName" "app-defaults" xfResult]} { set xfPathName $xfResult } if {[regsub -all "%S" "$xfPathName" "" xfResult]} { set xfPathName $xfResult } if {[regsub -all "%C" "$xfPathName" "" xfResult]} { set xfPathName $xfResult } if {[file exists $xfPathName] && [file readable $xfPathName] && ("[file type $xfPathName]" == "file" || "[file type $xfPathName]" == "link")} { catch "option readfile $xfPathName $xfPriority" if {"[info commands XFParseAppDefs]" != ""} { XFParseAppDefs $xfPathName } { if {"[info commands XFLocalParseAppDefs]" != ""} { XFLocalParseAppDefs $xfPathName } } } { if {[file exists $xfCounter2/$xfCounter1] && [file readable $xfCounter2/$xfCounter1] && ("[file type $xfCounter2/$xfCounter1]" == "file" || "[file type $xfCounter2/$xfCounter1]" == "link")} { catch "option readfile $xfCounter2/$xfCounter1 $xfPriority" if {"[info commands XFParseAppDefs]" != ""} { XFParseAppDefs $xfCounter2/$xfCounter1 } { if {"[info commands XFLocalParseAppDefs]" != ""} { XFLocalParseAppDefs $xfCounter2/$xfCounter1 } } } } } } } { # load a specific application defaults file if {[file exists $xfAppDefFile] && [file readable $xfAppDefFile] && ("[file type $xfAppDefFile]" == "file" || "[file type $xfAppDefFile]" == "link")} { catch "option readfile $xfAppDefFile $xfPriority" if {"[info commands XFParseAppDefs]" != ""} { XFParseAppDefs $xfAppDefFile } { if {"[info commands XFLocalParseAppDefs]" != ""} { XFLocalParseAppDefs $xfAppDefFile } } } } } # application setting procedure proc XFLocalSetAppDefs {{xfWidgetPath "."}} { global xfAppDefaults if {![info exists xfAppDefaults]} { return } foreach xfCounter [array names xfAppDefaults] { if {[string match "${xfWidgetPath}*" $xfCounter]} { set widname [string range $xfCounter 0 [expr [string first : $xfCounter]-1]] set name [string range $xfCounter [expr [string first : $xfCounter]+1] end] # Now lets see how many tcl commands match the name # pattern specified. set widlist [info command $widname] if {"$widlist" != ""} { foreach widget $widlist { # make sure this command is a widget. if {![catch "winfo id $widget"]} { catch "$widget configure -[string tolower $name] $xfAppDefaults($xfCounter)" } } } } } } # startup source proc StartupSrc {args} { global databases global currentdb global PreviousQuery set currentdb none set databases [GetDatabases] set PreviousQuery "retrieve () from where" } # prepare auto loading global auto_path global tk_library global xfLoadPath set auto_path "[split $xfLoadPath :] $tk_library [info library]" # startup source StartupSrc # initialize global variables proc InitGlobals {} { global {4} set {4} {0} global {PreviousQuery} set {PreviousQuery} {retrieve (a.attname) from a in pg_attribute, t in pg_class where a.attrelid = t.oid and t.relname = "DD_TABLES" } global {TCLDEFAULT} set {TCLDEFAULT} {/usr/local/lib/tcldefault6.7c} global {TCLENV} set {TCLENV(@-32238:45906)} {/usr/xf2.2/src/tclIndex} set {TCLENV(@-32239:45906)} {/usr/xf2.2/src/tclIndex} set {TCLENV(@-32241:45906)} {/usr/xf2.2/src/tclIndex} set {TCLENV(@-32245:230714)} {/usr/local/lib/tk/tclIndex} set {TCLENV(@-32245:87484)} {/usr/local/tcl/tcl.tlib} set {TCLENV(@-32245:87487)} {/usr/local/tcl/tk.tlib} set {TCLENV(@-32245:87537)} {/usr/local/tcl/tclIndex} set {TCLENV(PKG:TclX-ArrayProcedures)} {@-32245:87484 48 407} set {TCLENV(PKG:TclX-Compatibility)} {@-32245:87484 12174 59} set {TCLENV(PKG:TclX-assign_fields)} {@-32245:87484 500 148} set {TCLENV(PKG:TclX-convertlib)} {@-32245:87484 12273 933} set {TCLENV(PKG:TclX-developer_utils)} {@-32245:87484 699 804} set {TCLENV(PKG:TclX-directory_stack)} {@-32245:87484 8399 574} set {TCLENV(PKG:TclX-forfile)} {@-32245:87484 1537 167} set {TCLENV(PKG:TclX-forrecur)} {@-32245:87484 1749 356} set {TCLENV(PKG:TclX-globrecur)} {@-32245:87484 2147 330} set {TCLENV(PKG:TclX-help)} {@-32245:87484 2527 4828} set {TCLENV(PKG:TclX-packages)} {@-32245:87484 7400 950} set {TCLENV(PKG:TclX-profrep)} {@-32245:87484 13239 3169} set {TCLENV(PKG:TclX-set_functions)} {@-32245:87484 9039 2020} set {TCLENV(PKG:TclX-show_procedures)} {@-32245:87484 11111 603} set {TCLENV(PKG:TclX-stringfile_functions)} {@-32245:87484 11773 363} set {TCLENV(PKG:Tk-demo)} {@-32245:87484 16435 427} set {TCLENV(PKG:button.tcl)} {@-32245:87487 66 2232} set {TCLENV(PKG:entry.tcl)} {@-32245:87487 16912 1785} set {TCLENV(PKG:listbox.tcl)} {@-32245:87487 2345 1170} set {TCLENV(PKG:menu.tcl)} {@-32245:87487 7123 9715} set {TCLENV(PKG:text.tcl)} {@-32245:87487 3813 3124} set {TCLENV(PKG:tkerror.tcl)} {@-32245:87487 3547 174} set {TCLENV(PROC:AcceptRpcConnection)} {F /usr/local/tcl/rpc.tcl} set {TCLENV(PROC:CloseRPC)} {F /usr/local/tcl/rpc.tcl} set {TCLENV(PROC:CloseRPCFile)} {F /usr/local/tcl/rpc.tcl} set {TCLENV(PROC:CreateRemoteObject)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:DistributeObject)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:MakeRPCClient)} {F /usr/local/tcl/rpc.tcl} set {TCLENV(PROC:MakeRPCServer)} {F /usr/local/tcl/rpc.tcl} set {TCLENV(PROC:RPROC)} {F /usr/local/tcl/rpc.tcl} set {TCLENV(PROC:SetSlotOwner)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:SetTrigger)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:UndistributeObject)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:XFAlertBox)} {F /usr/xf2.2/src/xfalertBox.tcl} set {TCLENV(PROC:XFAlertBoxFd)} {F /usr/xf2.2/src/xfalertBox.tcl} set {TCLENV(PROC:XFAlertBoxFile)} {F /usr/xf2.2/src/xfalertBox.tcl} set {TCLENV(PROC:XFBinding)} {F /usr/xf2.2/src/xfbinding.tcl} set {TCLENV(PROC:XFColorBox)} {F /usr/xf2.2/src/xfcolorBox.tcl} set {TCLENV(PROC:XFCursorBox)} {F /usr/xf2.2/src/xfcursorBox.tcl} set {TCLENV(PROC:XFFSBox)} {F /usr/xf2.2/src/xffsBox.tcl} set {TCLENV(PROC:XFFontBox)} {F /usr/xf2.2/src/xffontBox.tcl} set {TCLENV(PROC:XFGroups)} {F /usr/xf2.2/src/xfgroups.tcl} set {TCLENV(PROC:XFIconBarConf)} {F /usr/xf2.2/src/xficonBar.tcl} set {TCLENV(PROC:XFIconBarInit)} {F /usr/xf2.2/src/xficonBar.tcl} set {TCLENV(PROC:XFIconBarRemove)} {F /usr/xf2.2/src/xficonBar.tcl} set {TCLENV(PROC:XFIconBarShow)} {F /usr/xf2.2/src/xficonBar.tcl} set {TCLENV(PROC:XFInfoAliases)} {F /usr/xf2.2/src/xfinfoAliases.tcl} set {TCLENV(PROC:XFInfoCommands)} {F /usr/xf2.2/src/xfinfoCmds.tcl} set {TCLENV(PROC:XFInfoErrors)} {F /usr/xf2.2/src/xfinfoErrs.tcl} set {TCLENV(PROC:XFInfoGlobals)} {F /usr/xf2.2/src/xfinfoGlobs.tcl} set {TCLENV(PROC:XFInfoPixmaps)} {F /usr/xf2.2/src/xfinfoPixmaps.tcl} set {TCLENV(PROC:XFInfoProcedures)} {F /usr/xf2.2/src/xfinfoProcs.tcl} set {TCLENV(PROC:XFInfoTreeSaveEdge)} {F /usr/xf2.2/src/xfinfoTree.tcl} set {TCLENV(PROC:XFInfoWidgetTree)} {F /usr/xf2.2/src/xfinfoTree.tcl} set {TCLENV(PROC:XFInputBoxMulti)} {F /usr/xf2.2/src/xfinputBox.tcl} set {TCLENV(PROC:XFInputBoxOne)} {F /usr/xf2.2/src/xfinputBox.tcl} set {TCLENV(PROC:XFKeysymBox)} {F /usr/xf2.2/src/xfkeysymBox.tcl} set {TCLENV(PROC:XFLayout)} {F /usr/xf2.2/src/xflayout.tcl} set {TCLENV(PROC:XFLayoutPosMove)} {F /usr/xf2.2/src/xflayout.tcl} set {TCLENV(PROC:XFLayoutPosPress)} {F /usr/xf2.2/src/xflayout.tcl} set {TCLENV(PROC:XFLayoutPosRelease)} {F /usr/xf2.2/src/xflayout.tcl} set {TCLENV(PROC:XFMenuBarConf)} {F /usr/xf2.2/src/xfmenuBar.tcl} set {TCLENV(PROC:XFMenuBarInit)} {F /usr/xf2.2/src/xfmenuBar.tcl} set {TCLENV(PROC:XFModules)} {F /usr/xf2.2/src/xfmodules.tcl} set {TCLENV(PROC:XFOptionsBind)} {F /usr/xf2.2/src/xfoptBind.tcl} set {TCLENV(PROC:XFOptionsGeneral)} {F /usr/xf2.2/src/xfoptGnrl.tcl} set {TCLENV(PROC:XFOptionsInterpreter)} {F /usr/xf2.2/src/xfoptInterp.tcl} set {TCLENV(PROC:XFOptionsPath)} {F /usr/xf2.2/src/xfoptPath.tcl} set {TCLENV(PROC:XFOptionsSource)} {F /usr/xf2.2/src/xfoptSource.tcl} set {TCLENV(PROC:XFOptionsVersion)} {F /usr/xf2.2/src/xfoptVersion.tcl} set {TCLENV(PROC:XFOptionsWindow)} {F /usr/xf2.2/src/xfoptWindow.tcl} set {TCLENV(PROC:XFPacking)} {F /usr/xf2.2/src/xfpacking.tcl} set {TCLENV(PROC:XFParameters)} {F /usr/xf2.2/src/xfparams.tcl} set {TCLENV(PROC:XFPasteFile)} {F /usr/xf2.2/src/xfcut.tcl} set {TCLENV(PROC:XFPasteShowTree)} {F /usr/xf2.2/src/xfcut.tcl} set {TCLENV(PROC:XFPasteUpdate)} {F /usr/xf2.2/src/xfcut.tcl} set {TCLENV(PROC:XFPlacing)} {F /usr/xf2.2/src/xfplacing.tcl} set {TCLENV(PROC:XFProcColorBox)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcConfAddCurrentItem)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfBinding)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfBindingAll)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfBindingClass)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfConfigure)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfGeometryDefault)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfInsertTemplate)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfInsertWidgetConfig)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfInsertWidgetDefault)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfLayout)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfPacking)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfParametersDefault)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfParametersGeneral)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfParametersGroups)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfParametersSmall)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfParametersSpecial)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcConfPlacing)} {F /usr/xf2.2/src/xfprocConfig.tcl} set {TCLENV(PROC:XFProcCursorBox)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcEditClearCut)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditCopy)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditCut)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditDelete)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditLoadCut)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditLoadTemplate)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditMakeAProc)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditPaste)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditSaveCut)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditSaveCutAsTemplate)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcEditShowCut)} {F /usr/xf2.2/src/xfprocEdit.tcl} set {TCLENV(PROC:XFProcError)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcFSBox)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcFSBoxFile)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcFSBoxPath)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcFSBoxPixmap)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcFileEnterTCL)} {F /usr/xf2.2/src/xfprocFile.tcl} set {TCLENV(PROC:XFProcFileInsert)} {F /usr/xf2.2/src/xfprocFile.tcl} set {TCLENV(PROC:XFProcFileLoad)} {F /usr/xf2.2/src/xfprocFile.tcl} set {TCLENV(PROC:XFProcFileNew)} {F /usr/xf2.2/src/xfprocFile.tcl} set {TCLENV(PROC:XFProcFileQuit)} {F /usr/xf2.2/src/xfprocFile.tcl} set {TCLENV(PROC:XFProcFileSave)} {F /usr/xf2.2/src/xfprocFile.tcl} set {TCLENV(PROC:XFProcFileSaveAs)} {F /usr/xf2.2/src/xfprocFile.tcl} set {TCLENV(PROC:XFProcFontBox)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcHelpAbout)} {F /usr/xf2.2/src/xfprocHelp.tcl} set {TCLENV(PROC:XFProcHelpHelp)} {F /usr/xf2.2/src/xfprocHelp.tcl} set {TCLENV(PROC:XFProcHelpTutorial)} {F /usr/xf2.2/src/xfprocHelp.tcl} set {TCLENV(PROC:XFProcIconBarRemove)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcIconBarShow)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcInputBoxMulti)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcInputBoxOne)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcKeysymBox)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcMessage)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcMessageFd)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcMessageFile)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcMiscAliases)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcMiscAppDefaults)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcMiscHardcopy)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcMiscModules)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcMiscPixmaps)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcMiscProgSaveEdge)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcMiscProgTreeEdge)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcMiscTestProgram)} {F /usr/xf2.2/src/xfprocMisc.tcl} set {TCLENV(PROC:XFProcOptionsBindings)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsGeneral)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsIconBar)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsInterpreter)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsMenuBar)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsPathFile)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsSaveClassBindings)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsSaveModuleList)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsSaveOptions)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsSavePositions)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsSource)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsVersion)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcOptionsWindow)} {F /usr/xf2.2/src/xfprocOpt.tcl} set {TCLENV(PROC:XFProcProgCommands)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgEditScript)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgEndSrc)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgErrors)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgGlobals)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgProcs)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgScript)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgStartupSrc)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcProgWidgetTree)} {F /usr/xf2.2/src/xfprocProg.tcl} set {TCLENV(PROC:XFProcText)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcTextFd)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcTextFile)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFProcYesNo)} {F /usr/xf2.2/src/xfprocOther.tcl} set {TCLENV(PROC:XFReadBox)} {F /usr/xf2.2/src/xfreadBox.tcl} set {TCLENV(PROC:XFSave)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveAsProc)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveBind)} {F /usr/xf2.2/src/xfsaveMisc.tcl} set {TCLENV(PROC:XFSaveClassBindings)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveModuleList)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveModules)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveProcsTmplt)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveScript)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveSourceAppendix)} {F /usr/xf2.2/src/xfsaveSource.tcl} set {TCLENV(PROC:XFSaveSubTree)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFSaveTclIndex)} {F /usr/xf2.2/src/xfsave.tcl} set {TCLENV(PROC:XFTextBox)} {F /usr/xf2.2/src/xftextBox.tcl} set {TCLENV(PROC:XFTextBoxFd)} {F /usr/xf2.2/src/xftextBox.tcl} set {TCLENV(PROC:XFTextBoxFile)} {F /usr/xf2.2/src/xftextBox.tcl} set {TCLENV(PROC:XFVersionLoad)} {F /usr/xf2.2/src/xfversion.tcl} set {TCLENV(PROC:XFVersionSave)} {F /usr/xf2.2/src/xfversion.tcl} set {TCLENV(PROC:XFYesNoBox)} {F /usr/xf2.2/src/xfyesNoBox.tcl} set {TCLENV(PROC:apropos)} {P TclX-help} set {TCLENV(PROC:assign_fields)} {P TclX-assign_fields} set {TCLENV(PROC:auto_execok)} {F /usr/local/tcl/init.tcl} set {TCLENV(PROC:auto_load)} {F /usr/local/tcl/init.tcl} set {TCLENV(PROC:auto_load_all)} {F /usr/local/tcl/rpc.tcl} set {TCLENV(PROC:auto_mkindex)} {F /usr/local/tcl/init.tcl} set {TCLENV(PROC:auto_reset)} {F /usr/local/tcl/init.tcl} set {TCLENV(PROC:autoprocs)} {P TclX-packages} set {TCLENV(PROC:buildpackageindex)} {F buildidx.tcl} set {TCLENV(PROC:convert_lib)} {P TclX-convertlib} set {TCLENV(PROC:dirs)} {P TclX-directory_stack} set {TCLENV(PROC:downsetf)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:edprocs)} {P TclX-developer_utils} set {TCLENV(PROC:execvp)} {P TclX-Compatibility} set {TCLENV(PROC:for_array_keys)} {P TclX-ArrayProcedures} set {TCLENV(PROC:for_file)} {P TclX-forfile} set {TCLENV(PROC:for_recursive_glob)} {P TclX-forrecur} set {TCLENV(PROC:getf)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:help)} {P TclX-help} set {TCLENV(PROC:helpcd)} {P TclX-help} set {TCLENV(PROC:helppwd)} {P TclX-help} set {TCLENV(PROC:intersect)} {P TclX-set_functions} set {TCLENV(PROC:intersect3)} {P TclX-set_functions} set {TCLENV(PROC:ldelete)} {F /usr/local/tcl/ldelete.tcl} set {TCLENV(PROC:lremovedup)} {F /usr/local/tcl/lremovedup.tcl} set {TCLENV(PROC:lrmdups)} {P TclX-set_functions} set {TCLENV(PROC:match)} {F /usr/local/tcl/match.tcl} set {TCLENV(PROC:matchExact)} {F /usr/local/tcl/match.tcl} set {TCLENV(PROC:matchNoCaseExact)} {F /usr/local/tcl/match.tcl} set {TCLENV(PROC:matchNoCasePattern)} {F /usr/local/tcl/match.tcl} set {TCLENV(PROC:matchPattern)} {F /usr/local/tcl/match.tcl} set {TCLENV(PROC:objectConfigure)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectCreateProc)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectExists)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectFree)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectSlot)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectSlotAppend)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectSlotFree)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectSlotSet)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:objectSlots)} {F /usr/local/tcl/oo.tcl} set {TCLENV(PROC:packages)} {P TclX-packages} set {TCLENV(PROC:parray)} {F /usr/local/tcl/parray.tcl} set {TCLENV(PROC:popd)} {P TclX-directory_stack} set {TCLENV(PROC:profrep)} {P TclX-profrep} set {TCLENV(PROC:pushd)} {P TclX-directory_stack} set {TCLENV(PROC:read_file)} {P TclX-stringfile_functions} set {TCLENV(PROC:recursive_glob)} {P TclX-globrecur} set {TCLENV(PROC:saveprocs)} {P TclX-developer_utils} set {TCLENV(PROC:setf)} {F /usr/local/tcl/distribObj.tcl} set {TCLENV(PROC:showproc)} {P TclX-show_procedures} set {TCLENV(PROC:showprocs)} {P TclX-show_procedures} set {TCLENV(PROC:tk_bindForTraversal)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_butDown)} {F /usr/local/lib/tk/button.tcl} set {TCLENV(PROC:tk_butEnter)} {F /usr/local/lib/tk/button.tcl} set {TCLENV(PROC:tk_butLeave)} {F /usr/local/lib/tk/button.tcl} set {TCLENV(PROC:tk_butUp)} {F /usr/local/lib/tk/button.tcl} set {TCLENV(PROC:tk_entryBackspace)} {F /usr/local/lib/tk/entry.tcl} set {TCLENV(PROC:tk_entryBackword)} {F /usr/local/lib/tk/entry.tcl} set {TCLENV(PROC:tk_entrySeeCaret)} {F /usr/local/lib/tk/entry.tcl} set {TCLENV(PROC:tk_firstMenu)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_getMenuButtons)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_invokeMenu)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_listboxSingleSelect)} {F /usr/local/lib/tk/listbox.tcl} set {TCLENV(PROC:tk_mbPost)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_mbUnpost)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_menus)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_nextMenu)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_nextMenuEntry)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_textBackspace)} {F /usr/local/lib/tk/text.tcl} set {TCLENV(PROC:tk_textIndexCloser)} {F /usr/local/lib/tk/text.tcl} set {TCLENV(PROC:tk_textResetAnchor)} {F /usr/local/lib/tk/text.tcl} set {TCLENV(PROC:tk_textSelectTo)} {F /usr/local/lib/tk/text.tcl} set {TCLENV(PROC:tk_traverseToMenu)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tk_traverseWithinMenu)} {F /usr/local/lib/tk/menu.tcl} set {TCLENV(PROC:tkdemo)} {P Tk-demo} set {TCLENV(PROC:tkerror)} {F /usr/local/lib/tk/tkerror.tcl} set {TCLENV(PROC:union)} {P TclX-set_functions} set {TCLENV(PROC:unknown)} {F /usr/local/tcl/init.tcl} set {TCLENV(PROC:write_file)} {P TclX-stringfile_functions} set {TCLENV(inUnknown)} {0} global {TCLINIT} set {TCLINIT} {/usr/local/tcl/TclInit.tcl} global {TCLPATH} set {TCLPATH} {/usr/local/tcl} global {alertBox} set {alertBox(activeBackground)} {} set {alertBox(activeForeground)} {} set {alertBox(after)} {0} set {alertBox(anchor)} {nw} set {alertBox(background)} {} set {alertBox(button)} {0} set {alertBox(font)} {} set {alertBox(foreground)} {} set {alertBox(justify)} {center} set {alertBox(toplevelName)} {.alertBox} global {aname} set {aname} {rel} global {auto} set {auto} {1} global {auto_rescan} set {auto_rescan} {off} global {avalue} set {avalue} {} global {c} set {c} {.append.buttons .append.3 .append.2 .append.1 .append.0} global {childs} set {childs} {.append.buttons .append.3 .append.2 .append.1 .append.0} global {cl} set {cl} {49} global {class} set {class} {DD_ADM} global {classname} set {classname} {EMPLOYEE} global {curclass} set {curclass} {49} global {currentdb} set {currentdb} {accessrtdb} global {databases} set {databases} {{{datname template1}} {{datname postgres}} {{datname accessrtdb}}} global {e} set {e} {4} global {el} set {el} {0} global {fsBox} set {fsBox(activeBackground)} {} set {fsBox(activeForeground)} {} set {fsBox(all)} {0} set {fsBox(background)} {} set {fsBox(button)} {0} set {fsBox(extensions)} {0} set {fsBox(font)} {} set {fsBox(foreground)} {} set {fsBox(internalPath)} {/tmp_mnt/home/sauer/tcl} set {fsBox(name)} {result.txt} set {fsBox(path)} {/tmp_mnt/home/sauer/tcl} set {fsBox(pattern)} {*} set {fsBox(scrollActiveForeground)} {} set {fsBox(scrollBackground)} {} set {fsBox(scrollForeground)} {} set {fsBox(scrollSide)} {left} set {fsBox(showPixmap)} {0} global {fsBoxExtensions} set {fsBoxExtensions} {0} global {i} set {i} {4} global {interactiveSession} set {interactiveSession} {0} global {l} set {l} {4} global {lab} set {lab} {-text text Text { } rel} global {list3} set {list3} {instances} global {mode} set {mode} {query} global {nc} set {nc} {4} global {nrattr} set {nrattr} {4} global {nrofentries} set {nrofentries} {4} global {ok} set {ok} {yes} global {p} set {p} {.append.1} global {programName} set {programName} {wish} global {query} set {query} {append EMPLOYEE (name = "Joe", salary = 1400, age = 40) append EMPLOYEE (name = "Sam", salary = 1200, age = 29)} global {res} set {res} {CAPPEND 150912} global {result} set {result} {append DD_ADM (field = "PAT_WK_PH_X" , typname = "decimal(5,0)" , descr = "Patient's work phone extension")} global {rpcFile} set {rpcFile} {} global {split} set {split} { , } global {temp} set {temp} { retrieve () from where } global {temp_append} set {temp_append} {append ()} global {temp_create} set {temp_create} {create ()} global {temp_function} set {temp_function} {} global {temp_retrieve} set {temp_retrieve} {\\\"retrieve () from\\\"} global {yesNoBox} set {yesNoBox(activeBackground)} {} set {yesNoBox(activeForeground)} {} set {yesNoBox(afterNo)} {0} set {yesNoBox(afterYes)} {0} set {yesNoBox(anchor)} {n} set {yesNoBox(background)} {} set {yesNoBox(button)} {1} set {yesNoBox(font)} {*times-bold-r-normal*24*} set {yesNoBox(foreground)} {} set {yesNoBox(justify)} {center} # please don't modify the following # variables. They are needed by xf. global {autoLoadList} set {autoLoadList(main.tcl)} {0} global {internalAliasList} set {internalAliasList} {{databasemenu .frame0.menubutton1.m.m} {attrlist .frame14.frame16.frame.listbox1} {classlist .frame14.frame15.frame.listbox1} {valuelist .frame14.frame17.frame.listbox1} {label3 .frame14.frame17.label20} {qtext .frame21.frame.text2} {classentry .frame14.frame15.entry4} {attrentry .frame14.frame16.entry3} {valueentry .frame14.frame17.entry2} {funclist .frame14.frame0.frame.listbox1}} global {moduleList} set {moduleList(main.tcl)} {} global {preloadList} set {preloadList(xfInternal)} {} global {symbolicName} set {symbolicName(databasemenu)} {.frame0.menubutton1.m.m} set {symbolicName(root)} {.} global {xfWmSetPosition} set {xfWmSetPosition} {} global {xfWmSetSize} set {xfWmSetSize} {} global {xfAppDefToplevels} set {xfAppDefToplevels} {} } # initialize global variables InitGlobals # display/remove toplevel windows. ShowWindow. # load default bindings. if {[info exists env(XF_BIND_FILE)] && "[info procs XFShowHelp]" == ""} { source $env(XF_BIND_FILE) } # parse and apply application defaults. XFLocalLoadAppDefs Main XFLocalSetAppDefs # eof #