Don't ask to ask, just ask | |
PerlMonks |
Re: how to align the label and entry text box in my tk GUIby kcott (Archbishop) |
on Mar 20, 2017 at 07:46 UTC ( [id://1185226]=note: print w/replies, xml ) | Need Help?? |
G'day fsmendoza, I've always found that Tk::grid, rather than Tk::pack, is the better geometry manager for this task. I would, however, advise that you lay out your GUI with frames (Tk::Frame, or even Tk::LabFrame) using pack. Then, within whichever frame(s) you want for your label and entry widgets, use grid. You should also aim to avoid a monolithic script with all variables having file-scope: not doing so leads to all the same problems experienced with global variables. You're already using lexical variables, which is good; limit their scope within subroutines, anonymous blocks, or similar constructs. — Ken
In Section
Seekers of Perl Wisdom
|
|