[Lazarus] MDI implementation

Felipe Monteiro de Carvalho felipemonteiro.carvalho at gmail.com
Thu Nov 17 09:26:14 CET 2011


On Thu, Nov 17, 2011 at 8:24 AM, Graeme Geldenhuys
<graemeg.lists at gmail.com> wrote:
> And now it's really funny. I got such a lot of sh*t from many lazarus
> developers about my custom drawn toolkit and how wrong that it
> compared to Lazarus "native" toolkit. Yet now somebody is working on
> implementing a custom drawn widgetset backend in the LCL. How ironic!

Well, I personally think that the LCL umbrella is big enough to fit
all tastes. There is no need to fight, people that prefer one or
another way are free to develop the widgetsets which they prefer. And
then each person can decide what to use:

1> Only native widgets
or
2> Only custom drawn widgets (futurely)

And we have a unique feature, which I've never heard of a framework having:

3> The hability to mix native and non-native widgets, which is very
powerful for my projects, for example see this:

http://wiki.lazarus.freepascal.org/fpbrowser#Screenshots

fpBrowser in Mac OS X has access to the native menus, but the native
TPageControl is undesirable in a browser. fpBrowser requires a
TPageControl with a reliable look and feel across platforms, so it
must be custom drawn. It also requires 2 features: Close Buttons and
also the Add Button for adding new tabs. The Add button is not just an
extra tab, since it's look can be anything depending on the Theme and
it also doesn't receive the close button. The native TPageControl in
Carbon/Cocoa cannot provide the required features.

So here I optimized fpBrowser by using a mix of Lazarus controls: a
native TMenu, but a non-native TPageControl.

Since quite a long time we already have the hability to mix native and
non-native Canvas support, TCanvas is the native one,
TLazIntfImage+TFPImageCanvas is the non-native one. I just expanded
this concept more broadly.

-- 
Felipe Monteiro de Carvalho




More information about the Lazarus mailing list