Tickit::Widget::HSplit - an adjustable horizontal split between two widgets
Tickit::Widget::HSplit
use Tickit; use Tickit::Widget::HSplit; use Tickit::Widget::Static; my $hsplit = Tickit::Widget::HSplit->new( top_child => Tickit::Widget::Static->new( text => "Text above" ), bottom_child => Tickit::Widget::Static->new( text => "Text below" ), ); Tickit->new( root => $hsplit )->run;
This container widget holds two child widgets, displayed one above the other. The two widgets are displayed with a horizontal split bar between them, which reacts to mouse click-drag events, allowing the user to adjust the proportion of space given to the two widgets.
The default style pen is used as the widget pen. The following style pen prefixes are also used:
The pen used to render the horizontal split area
The following style keys are used:
The number of lines of spacing between the top and bottom child widgets
The following style tags are used:
Set when a mouse drag resize operation is occurring
Constructs a new Tickit::Widget::HSplit object.
Takes the following named arguments
Child widgets to use
Returns the child widget used in the top half of the display.
Returns the child widget used in the bottom half of the display.
Paul Evans <leonerd@leonerd.org.uk>
To install Tickit::Widgets, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Tickit::Widgets
CPAN shell
perl -MCPAN -e shell install Tickit::Widgets
For more information on module installation, please visit the detailed CPAN module installation guide.