[Interest] How to produce a cluster of radio buttons?

Tony Rietwyk tony at rightsoft.com.au
Fri Aug 31 08:25:51 CEST 2012


If you set the enclosing Widget size policy to Fixed, then it should use the
minimum required for its layout anyway.   You can also play with the
layout's size constraint property.  

Tony.


> Sent: Friday, 31 August 2012 4:05 PM
> 
> On Fri, Aug 31, 2012 at 11:24 AM, Shriramana Sharma <samjnaa at gmail.com>
> wrote:
> > radioWidth = refPtArray [ 0 ] [ 0 ] . sizeHint () . width ()
> > refPtWidget . setFixedSize ( radioWidth * 3 - 10, radioWidth * 3 - 10
> > )
> >
> > Actually the last line should read radioWidth * 3 + 1 if I am to go by
> > uic's default output but that's too much spacing for my
> > taste/requirement and so I reduced this.
> 
> Silly me -- those above lines should actually change width to height
> throughout and change -10 to +2 (but there should be a better way to do
this
> than arbitrarily insert +2 or -10 or whatever).
> 
> --
> Shriramana Sharma




More information about the Interest mailing list