NAME
Tk::HListplus - Another HList derived widget that supports resizing, opening and closing of columns, taking benefit from TK::(Header)ResizeButton
SYNOPSIS
use Tk;
use Tk::HListplus;
my $mw = MainWindow->new();
# CREATE HEADER STYLE 1
my $headerstyle1 = $mw->ItemStyle('window', -padx => 0, -pady => 0);
# CREATE MY HLIST
my $hlist = $mw->Scrolled('HListplus',
-columns=>3,
-header => 1,
-headerstyle => $headerstyle1,
)->pack(-side => 'left', -expand => 'yes', -fill => 'both');
# CREATE HEADER STYLE 2
my $headerstyle = $hlist->ItemStyle('window', -padx => 0, -pady => 0);
$hlist->header('create', 0,
-itemtype => 'resizebutton',
-style => $headerstyle,
-text => 'Test Name',
-activeforeground => 'red',
);
$hlist->header('create', 1,
-itemtype => 'resizebutton',
-style => $headerstyle,
-text => 'Status',
-activebackground => 'orange',
);
Tk::MainLoop;
DESCRIPTION
A HList derived widget that merges the Features of the ResizeButton.
METHODS
- headerCreate()
-
The create command accepts a new, virtual itemtype 'resizebutton', which will lead to a Header-button with a right-side located sensor for resizing. All options suitable for Buttons apply.
In addition, the following options may be specified:
- headerCget()
-
This command allows with -widget to retrieve the Headerbutton-Widget Reference.
OPTIONS
- -command
-
The default command is associated with an open/close function for the selected column. The function is called with a Tk::HeaderResizeButton reference for custom usage.
- -activebackground
-
The background color used for the column Header during active state (Mouse over Header).
- -activeforeground
-
The foreground color used for the column Header during active state (Mouse over Header).
-
The relief used for the column Header Button during selected state (Button pressed).
- -minwidth
-
The minwidth used for the specific column (during resize), default: 30.
- -headerstyle
-
An alternative Header style, which will be ther default for all columns unless you specify -style ... for a dedicated header-create() call column.
AUTHORS
Michael Krause, <KrauseM@gmx.net>
Thanks for Tk::ResizeButton by Shaun Wandler <wandler@unixmail.compaq.com>, Slaven Rezic and Frank Herrmann.
This code may be distributed under the same conditions as Perl.
V0.3 (C) July 2005
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 408:
=cut found outside a pod block. Skipping to next block.