Tk::Optionbox 0.09 review
DownloadSYNOPSIS use Tk; use Tk::Optionbox my $current_class; my @all_classes = qw(cat dog bird); my $demo_xpm;
|
|
SYNOPSIS
use Tk;
use Tk::Optionbox
my $current_class;
my @all_classes = qw(cat dog bird);
my $demo_xpm;
my $mw = MainWindow->new();
# prepare some graphics
setup_pixmap();
# create a demo
my $optionbox = $mw->Optionbox (
-text => "Class",
-image => $demo_xpm, # use this line for personal pics or
#-bitmap => '@' . Tk->findINC('cbxarrow.xbm'));
-command => &class_cb,
-options => [ @all_classes ],
-variable => $current_class,
-tearoff => '1',
-rows => 10,
-activate => '0',
)->pack;
Tk::MainLoop;
sub class_cb
{
print "class_cb called with [@_], $current_class = >$current_class
Tk::Optionbox 0.09 keywords