L505 wrote:
>>Just some thoughts:
>>Someone could create a TReader/TWriter which writes pascal include files
>>instead of lfm.
> 
> 
> I think that's what I was trying to get at too, but didn't know how to put it 
> in words. How
> does delphi do it I wonder?? Is there some open tools api thing that Vladimir 
> is using in
> KOL? I have to look into sources. Some how he writes to an include file in 
> delphi.
> 

I have some idea , excuse me is it looks stupid because I have no
experience with creation of multiplatform GUI library.
I propose (instead of include files) - simple XML parser and all forms
as XML files.

XML parser must be compiled into executable so it must be really tiny
(adding only about 100K into executable)
XML could contain all forms for application,or each form can have own
XML.XML can be included into executable as a resource or lie into
program directory as separate file(s).
( such solution is rapidly developed in wxWindgets multiplatform C++ GUI
- and it have many advantages)


Merging such solution with flattened class hierarchy (only one,two or a
few classes to avoid executable code bloat)
I can see even three classes hierarchy :
TComponent - like in KOL should contain all possible functionality of
visual/non visual controls
TParser - alone GUI creation class (this must be full multiplatform !!)
working with XML files, cooperating with TEventHandler with known,stable
API (platform dependent code hidden inside this class, for each platform
another TParser implementation).Maybe is will be possible to even create
it as shared library (DLL/SO) ?
TEventHandler - just guess :-)
and a couple of special functions and classes

This way executable could be almost always below 1 MB and GUI could be
separated from application code processing.
Another advantage : somebody could inherit new class from TComponent if
executable size is not important for him.

One more idea: separating debug symbols from executable code like in
Delphi is also a way to get non-bloated programs,but I know it's
impossible with current linker and debugger.

Best regards
Boguslaw Brandys

_________________________________________________________________
     To unsubscribe: mail [EMAIL PROTECTED] with
                "unsubscribe" as the Subject
   archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to