[Lazarus] AlignTop/AlignBottom issue

Maxim Ganetsky ganmax at narod.ru
Mon May 25 22:45:34 CEST 2015


25.05.2015 20:13, Giuliano Colla пишет:
> AlignTop and AlignBottom do not appear to behave as they should.
>
> When you have several controls contained in another control, you would
> expect that each AlignTop or AlignBottom would stack the control in the
> first free position: with AlignBottom on top of the stack of the other
> bottom aligned components, with AlignTop at the bottom of the stack of
> the other top aligned components.
>
> On the contrary, it happens that "sometimes", in an unpredictable but
> reproducible way, the control which should go in one place goes to a
> different one, either becoming topmost or bottommost, or being inserted
> between other components.
>
> This occurs both at design time, making it sometimes very difficult to
> lay out the components as desired, and at runtime, disrupting the
> desired order of the components.
> The only workaround I've found is to set Align to alNone, and to
> painfully calculate the Top property of each component from the Top and
> Height properties of the others.
>
> This, besides not being Delphi compatible, is quite annoying.
>
> Should I open an issue in the bugtracker, with the usual small example
> to demonstrate the issue?

I guess it won't harm.

-- 
Best regards,
  Maxim Ganetsky                  mailto:ganmax at narod.ru




More information about the Lazarus mailing list