| Text-Snippet documentation | view source | Contained in the Text-Snippet distribution. |
Text::Snippet::TabStop::Cursor - Provides a bi-directional iterator interface for moving from one tab-stop to it's siblings
version 0.04
Maintains a reference to the snippet that this cursor is iterating over.
Returns true/false depending on whether the cursor can move to a previous tab stop.
Moves the cursor to the previous tab stop and returns that tab stop. You can only iterate one element off the end of the underlying set of tab stops.
Returns true/false depending on whether the cursor can move to a subsequent tab stop.
Moves the cursor to the next tab stop and returns that tab stop. You can only iterate one element off the end of the underlying set of tab stops.
Returns the tab stop the cursor is currently pointing at. When the cursor
is first created, this method will always return undef until next
has been called at least once.
Returns an ArrayRef reflecting the line/column position relative to
the beginning of the snippet. Both numbers are zero-based so a tab
stop starting on the first line, first character would return a value
of [0,0].
Returns an integer reflecting the current cursor position where 0 is the first character of the snippet and each character is counted up until the current position of the cursor.
Returns true if this tab stop is a "terminal" tab stop (i.e. once the user iterates to this tab stop, the iterator should be restored and normal editing should resume).
Brian Phillips <bphillips@cpan.org>
This software is copyright (c) 2010 by Brian Phillips.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
| Text-Snippet documentation | view source | Contained in the Text-Snippet distribution. |