Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 5 of 5 total
Thread TSizer horizontal
Wed, Apr 6 2016 8:20 AMPermanent Link

Matthew Jones




Attachments: SizerTest.zip
Wed, Apr 6 2016 8:23 AMPermanent Link

Matthew Jones

For those using the web interface, this is the content I posted:

Matthew Jones wrote:

> I'm having trouble getting TSizer to work in a way that makes sense to
> me. I am probably just not using it right, but welcome some input.
>
> I have a panel at the top (like a title), and a panel at the bottom
> (that I want to resize). In the middle is a panel that will take up
> all the rest of the space. The TSizer is in horizontal mode (the
> description of which says it will control the size in a horizontal
> direction, but it is of course a vertical direction when in horizontal
> mode! That's a hard one to document nicely!).
>
> Anyway, either I can get it to resize the bottom panel, but the
> opposite way to the mouse, or it changes from the design location and
> hugs the top panel but controls the height properly.
>
> In the attached project, click on the sizer and change the layoutorder
> to 2 to see the different effect (I have saved it set to 3).
>
> Where am I going wrong?

(If anyone can tell me why XanaNews is breaking this, let me know what
to do!)

--

Matthew Jones
Thu, Apr 14 2016 10:00 AMPermanent Link

Matthew Jones

Matthew Jones wrote:

> > I'm having trouble getting TSizer to work in a way that makes sense
> > to me. I am probably just not using it right, but welcome some
> > input.

Anyone got thoughts on this? I really need a sizer for a box at the
bottom, and would rather have the standard one work properly.

--

Matthew Jones
Thu, Apr 14 2016 11:13 AMPermanent Link

Uli Becker

Matthew,

> Anyone got thoughts on this? I really need a sizer for a box at the
> bottom, and would rather have the standard one work properly.

Change your layout like this.

LayoutOrder:
Panel1
Panel2
Sizer
Panel3

ALL LayoutPositions = TopLeft

All LayoutConsumptions = Bottom except Panel3 (Top)

Set the Control property of the sizer to BasicPanel2, not to BasicPanel3.

Attached a modified version of your sample project (frmSizerTest2 should
work).

Hope that helps.

Uli






Attachments: SizerModified.zip
Thu, Apr 14 2016 11:32 AMPermanent Link

Matthew Jones

Uli Becker wrote:

> Change your layout like this.

Perfect, thanks. So the key is that the bottom (which I then set to
stretch to the bottom right), must be seeking the top, not the bottom
as would be normal. As usual, easy when you know how.

--

Matthew Jones
Image