[Tkinter-discuss] New Full Tkinter document editor widget --suggestions, comments, etc.

Michael O'Donnell michael.odonnell at uam.es
Tue Mar 25 23:33:23 CET 2008

> I was wondering, since you mentioned the possibility of implementing tables,
> how you would draw the lines.. because I'm making an app right now where I'd
> like to draw some lines between labels in a grid.  I might need lines only
> vertically between labels, or vertically and horizontally between labels, or
> vertically and horizontally between labels and around the grid

You can insert widgets into a Text widget. The table itself could
be a Frame widget, with cells being Label widgets, aligned using grid manager.

But I find that as you get more ambitious, better to use a Canvas widget
instead of a Text widget, which is pretty inflexible. Using a Canvas, you
need to do a lot more work (splitting text into lines, positioning lines on the
canvas, etc.), but you can do almost anything you can think of with a Canvas.


More information about the Tkinter-discuss mailing list