Help Regarding GUI
- From: raaki <hemanth004@xxxxxxxxx>
- Date: Fri, 12 Oct 2007 03:19:21 -0700
Hi friends
i am newbie toTcl/Tk .i need some help regarding GUI design with tcl/
tk.i want to design a gui with a List of 5 fields and display it with
default values and intial dir, and when running the script the gui is
displayed such that i can edit (mean a browse option to change files
or direct).
i wrote a script with an array such that i am able to create the GUI
with the required fields and also with browse option,but when i browse
only the fifth label is getting updated .i dont know what error is
behind,can u guys help me to find the error
set listOfFields [list ABSOLUTE_PATH_NAMES ANNOTATE_LOAD_SLEW
BA_DIR BLACKBOXES SUB ]
foreach field $listOfFields {
set f ".frame-$field"
frame $f
button $f.label -width 30 -text "$field:" -bg NavajoWhite2 -fg Navy
-relief raised -command daa
label $f.entry -textvariable data($field) -relief sunken -bg
NavajoWhite -fg Navy -anchor nw
pack $f.label -side left
pack $f.entry -side left -fill x -expand 1
bind $f.entry <Return> [list validate_field $field.]
pack $f -side top -fill x
}
proc daa {} {
global data
global initialdir
set data($field) [tk_chooseDirectory -initialdir ~ -title "choose
directory"]
}
please also help me how to fit a scrollbar in the GUI which it
displays when running the script
Regards
raaki
.
- Follow-Ups:
- Re: Help Regarding GUI
- From: Bryan Oakley
- Re: Help Regarding GUI
- From: roland . frank
- Re: Help Regarding GUI
- Prev by Date: Re: Pack/grid sensitive to order of creation, possible bug?
- Next by Date: Re: Tcl as a configuration language?
- Previous by thread: Pack/grid sensitive to order of creation, possible bug?
- Next by thread: Re: Help Regarding GUI
- Index(es):