newbie with major "lambda" problem (perhaps a scope problem as well)

Joe Potter jm7potter at hotmail.com
Fri Jun 29 20:53:17 EDT 2001


On Fri, 29 Jun 2001 16:44:19 -0700, "John Roth" <johnroth at ameritech.net> wrote:

>If I understand what you want to do, you want a scrolling panel at the
>top, and three command buttons below (or above) the panel, right?
>The issue here is that the buttons' action procedures need access to
>the class instance, so they should go inside the class. That means the
>buttons themselves should go inside the class.
>
>That means you need to build everything inside the class. In other words,
>you can't build the pmw.ScrollingFrame (or whatever) outside it, and then
>use the frame for the contents. You need to build it at the same level
>as the buttons and the data fields, which means inside the class.
>
>There's nothing wrong with building two (or more) levels of widget in the
>same class. You just need to insure that things nest neatly.
>
>John Roth
>


Ah so --- ah so --- ah so !!!

Thanks John.

I have 5 books on Python, including one on just Python and Tkinter and not a word on
this fact! Well, unless I missed it, which is not unlikely at all.


Since the buttons will scroll out of view if I use them in the pmw.ScrollingFrame ---
heck I can use key bindings and just say to heck with the buttons. Problem solved!


Thanks greatly for this tip. Perhaps you should think of doing a book. 


Warmest Regards, Joe





More information about the Python-list mailing list