Have fun... TheMartyuse Tk; use Tk::Tree; use strict; my $Main = MainWindow->new; $Main->title("kuku"); my @win; my $kuku; my $info_m = $Main->Frame(-relief=>'groove',-borderwidth=>'3',)->pack( +-side => 'left', -expand => 1, -fill => 'both',); my $tree = $info_m->Scrolled("Tree")->pack(-side=>'top',-expan +d=>1,-fill=>'both'); #my $win = $Main->Toplevel; $win[0] = $tree -> Checkbutton(-text => "Kaka", -variable => \ +$kuku); $win[1] = $tree -> Checkbutton(-text => "Kaka2"); $win[2] = $tree -> Checkbutton(-text => "Kaka2"); $win[3] = $tree -> Checkbutton(-text => "Kaka2", -variable => +\$kuku); $tree -> add("one", -widget=> $win[0], -itemtype => 'window'); $tree -> add("one.two", -widget=> $win[1], -itemtype => 'windo +w'); $tree -> add("one.two.muku", -widget=> $win[2], -itemtype => ' +window'); $tree -> add("three", -widget=> $win[3], -itemtype => 'window' +); $tree -> add("four",-text=> "four"); $tree -> autosetmode(); MainLoop;
In reply to Re: Tree with checkboxes
by TheMarty
in thread Tree with checkboxes
by perlNoob
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |