Sizer help (min sizes, proportionality, and window resizing)

Harvey Chapman hchapman-wx-users at 3gfp.com
Wed May 7 09:31:13 PDT 2008


On May 7, 2008, at 10:59 AM, Vadim Zeitlin wrote:

> However if you really want the labels to be cut off when the window  
> is too
> small (rather than preventing it from becoming so small), then you do
> indeed need to set the minimal size (say 5 or 10 pixels) for the  
> spacers as
> they don't have any minimal size by default.


Thanks for the hint on setting a minimum size on the entire window. I  
used the code below to do that. I'm not sure if I can do it to the  
immediately parent sizer since I'm using XML. I'm not sure if I'd want  
to either since it kind of defeats the purpose of the XML.

I tried:

win->SetMinSize(win->GetEffectiveMinSize());

on all three labels right at startup, but after the frame had been  
shown. It had not effect. I don't know how to do the same to the  
spaces. The problem lies with the proportional flag. Is it possible to  
get wxWidgets to respect a minimum size if a proportional flag is set?

Thanks for the help,

R.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 194 bytes
Desc: This is a digitally signed message part
Url : http://lists.wxwidgets.org/pipermail/wx-users/attachments/20080507/05da6ddb/PGP.pgp


More information about the wx-users mailing list