[Lazarus] fpGUI
Sven Barth
pascaldragon at googlemail.com
Mon Jan 17 09:34:09 CET 2011
Am 17.01.2011 07:43, schrieb Graeme Geldenhuys:
> Op 2011-01-17 04:50, Hans-Peter Diettrich het geskryf:
>>> In fpGUI there is no "new AutoSize" and also there is no "FormCreate",
>>> because in fpGUI the convention is to create controls in "AfterCreate"
>>> which is a virtual method and not an event.
>>
>> So fpGUI has no Delphi compatible FormCreate handlers?
>
> By FormCreate, I assume you mean TForm.OnCreate event and FormCreate
> (which can actually have any name) being the event handler for OnCreate?
> Is so, obviously yes, fpGUI does have the OnCreate event.
>
>
>>> Also fpGUI does not rely on component streaming and thus the
>>> visibility of component fields can be as low as private without problems.
>>
>> This is what FPC disallows. When the code in AfterCreate sets a property
>> of a child control, then that property must be at least public.
>
> I think he worded it wrong. I assume he meant that "component fields"
> being the componens dropped on a designer form. Under Delphi and Lazarus
> those field variables must be located in the Published section of a
> Form. In fpGUI they are by default Private and in fact can be in any
> visibility section of a Form.
Thanks for explaining my bad wording. :)
Regards,
Sven
More information about the Lazarus
mailing list