On 11/25/13 11:23 AM, Ricardo Aráoz wrote: > El 25/11/13 15:50, Paul McNett escribió: >> On 11/25/13 9:00 AM, Ricardo Aráoz wrote: >>> El 25/11/13 11:20, Paul McNett escribió: >>>> On 11/24/13 11:36 AM, Ed Leafe wrote: >>>>> On Nov 24, 2013, at 12:56 PM, Ricardo Aráoz <ricar...@gmail.com> wrote: >>>>> >>>>>> Hi, having some trouble setting up a grid sizer. Just can't find what >>>>>> I'm doing >>>>>> wrong. >>>>>> I've simplified the thing down to a form with 3 rows. First and second >>>>>> row are >>>>>> text boxes while the third row has an edit box. I want the first two >>>>>> rows to keep >>>>>> their original sizes whilst the third should grow in both dimensions. >>>>> That doesn't sound possible. The expansion properties apply to the entire >>>>> column >>>>> or row, not to individual cells. >>>> I've found hierarchical box sizers to be more useful for things like this. >>>> In this >>>> case you'd have an outer vertical sizer, a horizontal sizer for each row, >>>> and >>>> vertical sizers for each cell. For the last cell, do the >>>> sizer.append1x(edtBox), but >>>> for the first two, just do sizer.append(ctrl). For the horizontal row >>>> sizer, do >>>> sizer.append1x(). >>>> >>>> >>> Thanks, yes I've tried that. >>> But how do you align the columns in this design? I mean, the first column >>> would be >>> labels of different sizes. Do you find out a maximum width and then set all >>> the >>> widths to that value? But then what happens with internationalization, or >>> different >>> font sizes across platforms? I mean, it seems that then you would be >>> loosing the >>> flexibility of sizers. Or is there some other smart way to deal with this I >>> haven't >>> thought about? >> When you change the caption of the label, if you've never set the width of >> the label >> explicitly, the label knows how wide it needs to be to display itself >> horizontally. >> The next time the sizer asks, it communicates this, and the sizer takes that >> into >> account when laying itself out. >> >> That said, I've found that with labels particularly, this doesn't always >> work, but I >> think it is at a lower-level than Dabo where it fails, and never looked very >> hard for >> an answer. >> > > Sorry, I didn't made myself clear. I mean that I want all labels to be > aligned in the > same column (either left center or right aligned) and I want all labels to be > properly aligned with the input controls. I've never been able to accomplish > both > things with box sizers, I can either align them by row or by column but not > both, > unless I define a static width in the label column. That's what a gridSizer > gives me > that box sizers won't.
You are correct. Paul _______________________________________________ Post Messages to: Dabo-users@leafe.com Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/dabo-users Searchable Archives: http://leafe.com/archives/search/dabo-users This message: http://leafe.com/archives/byMID/5293a945.2090...@ulmcnett.com