[Lazarus] TSplitter

Martin lazarus at mfriebe.de
Sat Aug 21 18:56:40 CEST 2010


  On 21/08/2010 15:14, Bernd Kreuss wrote:
> On 21.08.2010 15:52, Richard Saunders wrote:
>
>> that's
>> the way it started and always has been and I think its too late to
>> change now.
> Interestingly the TSplitter actually *has* already the ability to be
> used with anchor docking in the way I (and many others) would have
> expected it from the beginning on. The only thing that is wrong in my
> eyes is the default still being set to the old delphi behavior instead
> of using the new (and more consistent and powerful) anchor docking behavior.
Well one target is Delphi compatibility (not at every price, but 
probably at this price).

That means:
a) the ability to set it via align
b) if any other ability is given, possibly the means to auto-adjust the 
align according to  (derive the align from)  the new method.
(otherwise people now used to the align, will be confused, if the 
stumble upon splitters not using it)

Anchors to me are same as (if not even more) confusing as the align method.
And I do remember 10 or 20 years back having taken some time to figure 
it out (as I have an aversion against reading docs; so strictly: my fault)

Anchors are more complex than (and can be seen as an extension of) 
align. If the simple align is not intuitive, the complex anchors can 
never be. (even if to a few people including you, they would have been, 
simply by random chance of the order in which you discovered things)

IMHO the most intuitive way (but it would break delphi compatibility, so 
it will not happen):
- remove align and anchor properties completly; and have a property for 
the left/right (or above/below) controls, that should be affected

Alternatively (I thing that once existed as TPairSplitter) a splitter, 
that is like a big panel, but with 2 child areas divided by the build in 
splitter. that way, you just drop the controls into the splitters child 
area.

Then again, there is documentation too, and there a bigger problems than 
that.

Martin




More information about the Lazarus mailing list