wxDesigner: maintaining dialog minimum size

1 view
Skip to first unread message

Jesper Eskilson

unread,
Nov 12, 2002, 11:22:08 AM11/12/02
to wxpytho...@lists.wxwindows.org

Hi!

I have a wxDesigner question. How can you make sure that a dialog designed
in wxDesigner maintains its proper minimum size? By "minimum size" I mean
that the dialog should be able to be resized such that its' contents is
truncated in any way.

Thanks,

/Jesper
--
Jesper Eskilson
Virtutech
http://www.virtutech.com

David Hughes

unread,
Nov 12, 2002, 1:19:00 PM11/12/02
to wxpytho...@lists.wxwindows.org
Jesper Eskilson wrote:

> I have a wxDesigner question. How can you make sure that a dialog
> designed
> in wxDesigner maintains its proper minimum size? By "minimum size" I
> mean
> that the dialog should be able to be resized such that its' contents is

> [not?] truncated in any way.

Call the wxDesigner-created function (eg mywxdialog) from your dialog code
using:

mywxdialog( self, call_fit=true, set_sizer=true )

This will display the dialog at its proper minimum size and will permit
the user to resize it bigger but not smaller. If you want the dialog to
start out bigger than the minimum size, follow the above call with:

self.SetSize(initsizetuple)

where initsizetuple is the size you want. Hope this helps.


Regards,

David Hughes
Forestfield Software Ltd
www.forestfield.co.uk

Jesper Eskilson

unread,
Nov 14, 2002, 3:15:01 PM11/14/02
to wxPytho...@lists.wxwindows.org, d...@forestfield.co.uk, wxpytho...@lists.wxwindows.org
Jesper Eskilson <jo...@virtutech.com> writes:

> d...@forestfield.co.uk (David Hughes) writes:
>
> > where initsizetuple is the size you want. Hope this helps.
>

> It did, thanks. I was thrown of by the fact that the "Test resizable
> dialog" does do this, so the dialog appears to size itself wrong when
> testing it.

Oops. s/does do this/does not do this/

Jesper Eskilson

unread,
Nov 14, 2002, 2:25:27 PM11/14/02
to d...@forestfield.co.uk, wxpytho...@lists.wxwindows.org
d...@forestfield.co.uk (David Hughes) writes:

> where initsizetuple is the size you want. Hope this helps.

It did, thanks. I was thrown of by the fact that the "Test resizable


dialog" does do this, so the dialog appears to size itself wrong when
testing it.

/Jesper

Jesper Eskilson

unread,
Nov 14, 2002, 3:15:01 PM11/14/02
to wxPytho...@lists.wxwindows.org, d...@forestfield.co.uk, wxpytho...@lists.wxwindows.org
Jesper Eskilson <jo...@virtutech.com> writes:

> d...@forestfield.co.uk (David Hughes) writes:
>
> > where initsizetuple is the size you want. Hope this helps.
>
> It did, thanks. I was thrown of by the fact that the "Test resizable
> dialog" does do this, so the dialog appears to size itself wrong when
> testing it.

Oops. s/does do this/does not do this/

/Jesper

Reply all
Reply to author
Forward
0 new messages