|
sub create_listbox { my ($frame, $title, @entries) = @_; my $inner_frame = $frame->Frame(); my $label = $inner_frame->Label( '-text' => $title, '-width' => $listbox_width, ); $label->pack('-side' => 'top', @fillx); my $listbox = $inner_frame->Listbox( '-width' => $listbox_width, '-height' => $listbox_height, ); $listbox->insert('end', @entries); $listbox->pack('-side' => 'top', @expandx); return ($inner_frame, $listbox); } |
$listbox_width und $listbox_height wurden
entsprechend der vorgegebenen Angaben festgelegt.
Das erspart etwaige Scrollbars.
|
Copyright © 1996 - 2003 Andreas Borchert, in HTML konvertiert am 01.10.2003 |