How to control Pmw.ScrolledText scrollbar position?

Dieter Maurer dieter at handshake.de
Mon Jun 26 16:48:33 EDT 2000


Maytag Repairman <maytagrepairman at yahoo.com> writes on Wed, 21 Jun 2000 22:06:46 GMT:
> I have this program that I've written which uses Pmw.ScrolledText.
> There are buttons on my GUI which take data from entry fields and
> insert, replace, and append data in a data structure.  The ScrolledText
> is cleared and the updated data structure is displayed in a user-
> friendly format.  Unfortunately, the scrollbar always ends up at the
> top after this operation but the area of most interest to the user is
> the point where the operation on the data structure took place.  I
> can't figure out how to control the position of the scrollbar to move
> it to the area of interest.
You can use the TextWidget's (! not the scrollbar's) "yview"
command to adjust the viewport of the widget. It will
automatically adjust the scrollbar.


Dieter



More information about the Python-list mailing list