$lb=Paw::Listbox-new($height, $width, [$colored], [$name]);>
Parameter
$height => Number of rows $width => Number of columns $colored => 1 turns on the colored mode (see also "add_row") default=0 [optionally] $name => Name of the widget [optionally]
Example
$lb=Paw::Listbox->new(width=>10, height=>15, colored=>1);
deletes all entrys out of the listbox
$listbox->clear_listbox();
adds a data-row into the listbox. When the color mode is activated, you can give a second parameter as color-pair number. Alternatively you can give a refernce to an array to the listbox and it will put gradually each array element into the box. If the color mode is on, each second element of the array must be a color-pair number.
$listbox->add_row("Test", 3);
deletes the row with the number "$number". Start counting at zero.
$listbox->del_row(4);
swaps the $first and the $second row of the listbox.
$listbox->change_rows($lower, $upper);
returns the number of data-rows in the listbox.
$data=$listbox->number_of_data();
returns an array of all pushed data-rows, either the linenumbers or the data.
@data_rows=$listbox->get_pushed_rows("linenumbers");
returns an array with the complete contents of the listbox.
@full_data=$listbox->get_all_rows();
the widget moves to the new absolute screen position. if you set only one of the two parameters, the other one keeps the old value.
$listbox->abs_move_widget( new_x=>5 ); #y-pos is the same
returns an array of two values, the x-position and the y-position of the widget.
($xpos,$ypos)=$listbox->get_widget_pos();
activates the border of the widget (optionally also with shadows).
$widget->set_border("shade"); or $widget->set_border();
To install Paw, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Paw
CPAN shell
perl -MCPAN -e shell install Paw
For more information on module installation, please visit the detailed CPAN module installation guide.