Koen,
In the following snippet I would think that the WGroupBox'es would be the same
height:
WVBoxLayout *vbl= new WVBoxLayout;
root()->setLayout(vbl, AlignTop);
{ // Row
WHBoxLayout *hbl= new WHBoxLayout;
vbl->addLayout(hbl);
{ // Widget #1
WGroupBox *gb= new WGroupBox("box 1", root());
hbl->addWidget(gb);
{ // Widget #1 contents
WVBoxLayout *vbl= new WVBoxLayout;
gb->setLayout(vbl, AlignTop);
vbl->addStretch();
WLineEdit *le= new WLineEdit(gb);
vbl->addWidget(le);
vbl->addStretch();
}
}
{ // Widget #2
WGroupBox *gb= new WGroupBox("box 2", root());
hbl->addWidget(gb);
{ // Widget #2 contents
WVBoxLayout *vbl= new WVBoxLayout;
gb->setLayout(vbl, AlignTop);
vbl->addStretch();
WSelectionBox *sb= new WSelectionBox(gb);
sb->setVerticalSize(20);
vbl->addWidget(sb);
vbl->addStretch();
}
}
}
On Wednesday 11 January 2012, Koen Deforche wrote:
> Hey John,
>
> 2012/1/5 John D. Robertson <[email protected]>:
> > I have a WVBoxLayout with several WHBoxLayout children. I want the
> > widgets controlled by a given WHBoxLayout to all be the same height, but
> > it's OK for sibling WHBoxLayout's to be different heights.
> >
> > I can't figure out how to do this - what am I missing?
>
> What should determine the height of a single WHBoxLayout then? only
> its contents or also excess space (in the WVBoxLayout) that is to be
> redistributed across all child layouts ?
>
> And what part is not working currently ? Perhaps you can share the
> code snipped that does the layout ?
>
> Regards,
> koen
--
=============================================================
John D. Robertson, Computer / Engineering Consultant
Robertson & Robertson Consultants, Inc.
3637 West Georgia Rd.
Pelzer, SC 29669
Phone: (864) 243-2436
Email: [email protected]
WWW: http://www.rrci.com
Blog: http://oopinc.blogspot.com
------------------------------------------------------------------------------
RSA(R) Conference 2012
Mar 27 - Feb 2
Save $400 by Jan. 27
Register now!
http://p.sf.net/sfu/rsa-sfdev2dev2
_______________________________________________
witty-interest mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/witty-interest