Perl: the Markov chain saw | |
PerlMonks |
Re^3: Tk hidden bindingby zentara (Archbishop) |
on Jul 24, 2011 at 11:12 UTC ( [id://916391]=note: print w/replies, xml ) | Need Help?? |
I would think that your newline is replaced by \x{13} in my Tk version. But why should a newline be printed anyway? This brings up a good point, what do YOU expect to happen when you press a <control s> in the TextUndo widget? The normal behavior, on my Tk ( version Tk-804.029_500 ) , with no extra bindings associated with it, is to print what appears to be an underscore line segment, not a newline. It is not a dash or hyphen. Repeated presses of <control s> create a continuous line looking like an underscore (at the bottom of the font area). Do you want this behaviour? If you want to stop all text insertion, with a <control s>, try this and see what happens. I get NO insertion of any kind into the TextUndo widget. Notice I'm getting the REAL widget, not the Scrolled one.
To address the point that you saw no difference in binding to a Scrolled or standard TextUndo widget, notice the difference in behavior in this script, where I bind to the Scrolled widget. I get the foo to the console, plus the underscore line gets printed to the TextUndo.
I'm not really a human, but I play one on earth. Old Perl Programmer Haiku ................... flash japh
In Section
Seekers of Perl Wisdom
|
|