[Python-bugs-list] [ python-Bugs-491183 ] ScrolledText.grid() doesn't work

noreply@sourceforge.net noreply@sourceforge.net
Mon, 10 Dec 2001 08:43:13 -0800


Bugs item #491183, was opened at 2001-12-10 08:34
You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=491183&group_id=5470

Category: Tkinter
Group: None
>Status: Closed
>Resolution: Accepted
Priority: 5
Submitted By: Jeff Epler (jepler)
>Assigned to: Guido van Rossum (gvanrossum)
Summary: ScrolledText.grid() doesn't work

Initial Comment:
Using grid methods on ScrolledText widgets does not
work as expected.  It either fails to pack a widget, or
can even cause Tk to lock up.

The problem is that the .grid method is being called on
the text widget, not the frame widget.  This can lead
to the well-known lockup in Tk when a frame's children
are managed by both the pack and grid managers.  Even
if it doesn't lock up, the frame is never placed within
the intended widget.

Program fragment:
>>> import ScrolledText
>>> s = ScrolledText.ScrolledText()
>>> s.grid(row=0, column=0, rowspan=2)

The following patch uses the same hack to copy the
'grid' and 'place' geometry manager methods to the
ScrolledText instance as is already used for the 'pack'
manager.

----------------------------------------------------------------------

>Comment By: Guido van Rossum (gvanrossum)
Date: 2001-12-10 08:43

Message:
Logged In: YES 
user_id=6380

Thanks! I see no harm in applying this, so done --
ScrolledText 1.11 it is.

----------------------------------------------------------------------

You can respond by visiting: 
http://sourceforge.net/tracker/?func=detail&atid=105470&aid=491183&group_id=5470