in reply to Re^2: Extensibility of Tk::TableMatrix
in thread Extensibility of Tk::TableMatrix
There is a number of tk widgets to deal with task, and tablelist widget is one of them (another alternatives could be treeview from tile package and tktable).
look at description of tablelist - it is really powerful - it allows editing with text or checkbutton or 'edit' widget.use strict; use Tcl::Tk; my $int = new Tcl::Tk; my $mw = $int->mainwindow; # the tablelist widget is described at # http://docs.activestate.com/activetcl/8.5/tablelist/tablelistWidget. +html $int->pkg_require('tablelist'); $int->Eval('namespace import tablelist::*'); my $w_t = $mw->Scrolled('tablelist',-columns =>[0, "First Column", 0, +"Another column"], -stretch =>'all', -background =>'white')->pack(-fill=>'both', + -expand=>1, -side=>'top'); $w_t->columnconfigure(0, -editable=>1); $w_t->columnconfigure(1, -editable=>1); $w_t->insert('end', ["row $_;", "$_ bla bla"]) for 'a'..'zzz'; $int->MainLoop;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Extensibility of Tk::TableMatrix
by elef (Friar) on Feb 07, 2011 at 12:38 UTC | |
by vkon (Curate) on Feb 08, 2011 at 15:24 UTC | |
by elef (Friar) on Feb 08, 2011 at 21:11 UTC | |
by vkon (Curate) on Feb 08, 2011 at 21:45 UTC | |
by elef (Friar) on Feb 09, 2011 at 13:25 UTC | |
|