Tkinter : resizing Text widget with main window

Erik de Castro Lopo nospam at
Tue Mar 20 08:52:40 CET 2001

Rick Pasotto wrote:
> On Thu, 15 Mar 2001 19:38:12 GMT in comp.lang.python, Erik de Castro Lopo wrote:
> > Hi all,
> >
> > How does one force a Tkinter.Text widget to be resized whenever
> > the main window is resized?
> t=Text(width=30,height=12) # sets the initial size
> t.pack(expand=1,fill='both')

That may work for widgets which are pack()ed, but what about
widgets which are place in the parent window using grid ()?

This does work for grid ().

Erik de Castro Lopo     nospam at      (Yes its valid)
"I've got an idea! Sun, Oracle, and IBM hold down MS while Linux 
gets to kick them!" -- Lou Grinzo on

More information about the Python-list mailing list