Resizing drawings in a wxFrame
Robert Amesz
sheershion at mailexpire.com
Fri Jan 25 09:34:18 EST 2002
Duncan Smith wrote:
> I have a general query about resizing drawings in a wxFrame. I
> have tried the usual? dc.SetUserScale(x/548.0, y/364.0) (where my
> original window is of size 548, 364). The trouble is that on a
> resize parts of the drawing tend to disappear behind toolbars and
> statusbars. I have tinkered a lot without much success. Does it
> just require more tinkering, or is there an obvious / standard
> solution I'm missing? Thanks in advance for any help.
I'm only guessing here, but can't you use
dc.SetDeviceOrigin(0, height_of_toolbar)
to set the origin just past the toolbar?
Also, I believe the client area you get when yo call GetClientSize() or
GetClientSizeTuple() is the area *including* both the toolbar and
statusbar, in which case you'd have to substract the height of those
two from the usable height of the client area.
However it might be simpler just to put your drawing on a wxPanel
instead, and put that panel on the wxFrame.
Robert Amesz
More information about the Python-list
mailing list