Hi gurus,
...
I wonder if Lazarus could used each installed package as an external library basis....
but it can not, currently.
so my question is:
1. Why? what is the problem to make Lazarus/FreePascal able to import class/component from external library?
2. Is there any plan to achieve that?
================
Background:
By my limited knowledge of Lazarus, all component installed in Lazarus will be compiled inside Lazarus IDE (lazarus.exe).
I don't know why this design was chosen, .. is it because FreePascal Compiler/Linker's limitation or maybe it because of another difficulty on compiling/linking imported external library (*.bpl / *.lpl) into a bigger binary (*.exe) ...?
Whatever the reason, in my humble opinion : I believe that we can solve & do that someday in future.
Anyway,
I found a demo somewhere in internet, that show loading a form from external library.
the form is not only shown, but it shown embeded in other form.
I imagine that we can use above similar technique for Lazarus designer: a component loaded from a library (*.bpl /*.lpl) and then placed in Lazarus form designer by such code:
TControl(LoadedComponent).parent := CurrentDesignerForm;
Another benefit of loading/storing lazarus compiled package into an external library is
there will no need for restarting lazarus when a desing-time-package installed.
though, I am fine of restarting lazarus; my machine is fast enough for wait Lazarus restart.
Bytheway,
A big chance if Lazarus could load a component from external library is:
* new kind of Lazarus Designer.
I imagine that the form designer is in true GTK (for example) appearance including GTK themes;
or in true QT appearance including QT toolbar (which is beautiful)
dropped to the form designer (TForm1) from Lazarus component palette.
In other word, the designer will in true selected widgetset configuration while the IDE is may in another widgetset.
It was done in Delphi7 wich is ech form designer is not a part of the IDE,
but the form designer is loaded from external library: so D7 can switch between GDI / QT, per project basis.
---------------
Back to topic, I wonder if it was possible ? and What are requirement for make it possible?
Any explanation, disagree, idea, complaint, proof or critique are welcome.
(sorry again for my bad english)
x2nie