tkinter: invisible PanedWindow "sashes" on OS X

Arnaud Delobelle arnodel at gmail.com
Thu Mar 21 16:59:05 EDT 2013


On 21 March 2013 18:42, Christian Gollwitzer <auriocus at gmx.de> wrote:
> Am 21.03.13 15:37, schrieb Arnaud Delobelle:
>
>> Hi Python List,
>>
>> I'm trying to use PanedWindow on OS X (10.8.3).  I've started with the
>> effbot docs example (http://effbot.org/tkinterbook/panedwindow.htm),
>> namely:
>>
>> ----------
>> from Tkinter import *
>>
>> m = PanedWindow(orient=VERTICAL)
>> m.pack(fill=BOTH, expand=1)
>>
>> top = Label(m, text="top pane")
>> m.add(top)
>>
>> bottom = Label(m, text="bottom pane")
>> m.add(bottom)
>>
>> mainloop()
>> ----------
>>
>> I can see two panes alright, but no handle to resize them (or 'sash'
>> as they seem to be called in tkinter).  Is there something else that I
>> should be doing?
>
>
> This is, unfortunately, the platform standard on both OSX and Windows7. You
> can still resize the windows: Just grab the space between the two labels.
> There should be at least a cursor change.

I cannot effect a cursor change with the example above.

> With you example it doesn't work particularly well, because the labels are
> small and have no visible border. Try using e.g. a text widget instead (or
> maybe relief=SUNKEN)

If I use text widgets for the top and bottom panes, then I can get a
resize cursor and I am able to drag the 'sash' up and down.  That's
good enough for me to get started.  Thanks for the suggestion,

-- 
Arnaud



More information about the Python-list mailing list