Just another Perl shrine | |
PerlMonks |
Tk BrowseEntry with only the arrow button visible?by elef (Friar) |
on Dec 22, 2013 at 21:06 UTC ( [id://1068124]=perlquestion: print w/replies, xml ) | Need Help?? |
elef has asked for the wisdom of the Perl Monks concerning the following question:
Is there an easy way to use a BrowseEntry widget without the first item/current selection being displayed? I just want the arrow button to be visible until it's clicked. I tried -width => 1, but it doesn't work. The text field is small but it still shows up. I also tried to hack the .pm but it's not working (not correctly, anyway). I modified it so that the $e LabEntry widget is not packed (commented out line 77: $e->pack(-side => 'right', -fill => 'x', -expand => 1);). This works, but it causes the listbox to show up at the edge of the screen instead of below the button. This must be because the position is determined based on the position of the $e widget:
Fixing this so that $x1 and $y1 are set based on the position of the button is beyond my reach. Is there a simpler solution? Is there a different drop-down list widget that is displayed as only a button?
Back to
Seekers of Perl Wisdom
|
|