Alt-Tickit-Widgets-ObjectPad
view release on metacpan or search on metacpan
lib/Tickit/Widget/Box.pm view on Meta::CPAN
=head1 DESCRIPTION
This subclass of L<Tickit::SingleChildWidget> can apply spacing around the
outside of a given child widget. The size of the Box is controlled by the size
of the child widget bounded by the given limits, allowing it to enforce a
given minimum or maximum size in each of the horizontal and vertical
directions. By setting both the minimum and maximum size to the same value,
the exact size of the child widget can be controlled.
Limits can be specified either as absolute values, or as a percentage of the
maxmium available space.
If the Box is given more space to use than the child widget will consume, the
child will be placed somewhere within the space, at a position that is
controllable using the C<align> and C<valign> properties, as defined by
L<Tickit::WidgetRole::Alignable>.
=head1 STYLE
The default style pen is used as the widget pen.
lib/Tickit/Widget/Box.pm view on Meta::CPAN
method render_to_rb
{
my ( $rb, $rect ) = @_;
$rb->eraserect( $rect );
}
=head1 METHODS
The following methods all accept either absolute sizes, specified in integers,
or percentages, specified in strings of the form C<10%>. If a percentage is
given it specifies a size that is a fraction of the total amount that is
available to the Box.
=head2 $min = $box->child_lines_min
=head2 $box->set_child_lines_min( $min )
=head2 $min = $box->child_cols_min
=head2 $box->set_child_cols_min( $min )
( run in 0.452 second using v1.01-cache-2.11-cpan-10c994e2082 )