Zitat von Graeme Geldenhuys <[EMAIL PROTECTED]>:
> On 23/07/07, Mattias Gärtner <[EMAIL PROTECTED]> wrote:
> > The lfm reader/writer was at hand at the time. Nowadays we could use the
> xml
> > reader/writer too, although that is less human readable.
> > Using pascal source as file format would be possible and has some
> advantages but
> > some disadvantages as well.
>
>
> Mattias, these are the things I would like to find out. What are the
> advantages and disadvantages of using a single pascal unit for code
> and form designer information. Like I mentioned before, calling a
> private method from the constructor to build the GUI. The form
> designer maintains that private method's content.
Lots of details. Here are some categories (this is not a complete list):
- Sub components: You can do it with "With" or with full path. A "With" has the
disadvantage, that if a property is removed from a class, the code can execute
without error.
- Custom data (e.g. TStrings, TBitmap).
- creation of components. Have a look the TReader code to understand the
problems. A simple Button1:=TButton.Create(Root); will not work.
- Parent property
- Usability: If the format is pascal, people might try some pascal things. But
the IDE parser will probably not understand it or worse: misunderstand it. It
will work at runtime, but not at design time, so people will blame the IDE.
- But there is one big advantage: We might provide a LCL without RTTI. Then
smart linking would work much better.
Mattias
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives