Hello,
I stumbled upon a weird behaviour in Tk::Text, when trying to move with the keyboard through hidden text, and I think it might be a bug.
Consider the following code:
use strict; use warnings; use Tk; my $mw = MainWindow->new(-title => "Bug?"); my $frame = $mw->Frame() ->pack(-side => "left", -expand => 1, -fill => 'both'); my $text = $frame->Scrolled('Text') ->pack(-expand => 1, -fill => 'both'); my $data; for (my $i = 1; $i <= 20; $i++) { $data .= "abcdefghi $i \n"; } $text->insert('end',$data); $text->tagConfigure("invisible",-elide => 'true'); $text->tagAdd("invisible",'7.0','13.0'); MainLoop();
If you stand on line #6, and move with the arrows down, you jump straight to line #13, as expected. Same thing when you start from #13 and move up. If you stand on line 6 and move to the right, the cursor disappears, which makes sense (even if I'd rather have it jump to #13 as well). However, if after the cursor disappears, you try to move up or down, you immediately get errors.
Is that a bug? If so, where should I report it? (CPAN?)
Thanks :)
In reply to Tk::Text - moving through hidden text by anna_black
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |