Tickit - Terminal Interface Construction KIT
Tickit
use Tickit; use IO::Async::Loop; my $loop = IO::Async::Loop->new; my $tickit = Tickit->new; $loop->add( $tickit ); # Create some widgets # ... $tickit->set_root_widget( $rootwidget ); $tickit->run;
Constructs a new Tickit framework container object.
Takes the following named arguments at construction time:
Passed to the Tickit::Term constructor.
Returns the underlying Tickit::Term object.
Installs a callback to invoke if the given key is pressed, overwriting any previous callback for the same key. The code block is invoked as
$code->( $key )
If $code is missing or undef, any existing callback is removed.
$code
undef
As a convenience for the common application use case, the Ctrl-C key is bound to a callback that calls the loop_stop method on the underlying IO::Async::Loop object the Tickit is a member of. This usually has the effect of cleanly stopping the application.
Ctrl-C
loop_stop
IO::Async::Loop
To remove this binding, simply bind another callback, or remove the binding entirely by setting undef.
Returns the Tickit::RootWindow.
Sets the root widget for the application's display. This must be a subclass of Tickit::Widget.
Set up the screen and generally prepare to start running
Shut down the screen after running
A shortcut to the common usage pattern, combining the start method with loop_forever on the containing IO::Async::Loop object.
start
loop_forever
Paul Evans <leonerd@leonerd.org.uk>
To install Tickit, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Tickit
CPAN shell
perl -MCPAN -e shell install Tickit
For more information on module installation, please visit the detailed CPAN module installation guide.