[Lazarus] When adding a packages it adds to uses clause
graemeg.lists at gmail.com
Tue Jul 8 09:04:53 CEST 2008
2008/7/8 Mattias Gaertner <nc-gaertnma at netcologne.de>:
> The IDE adds the package to the uses section of the program *once* and
> only for the convenience of the programmer. If he don't
> like it, he can remove it. Just like any unit or CreateForm statement,
> that the IDE adds too.
A convenience for the programmer, at an expence of a much larger
executable. And yes, I do remove the unit, but sometimes I forget. One
good thing like you said, it only happens once, when the packages was
added to the project.
> The Register procedures are not called by this.
> As Vincents already said:
> It's added to call the initialization sections.
My mistake, I got confused between initialization section and the
Register() funcion (used for registering with the IDE).
>> When deploying apps over the internet every byte counts! No need to
>> follow Microsoft's idea of creating every application with bucket
>> loads of bloat.
> Then decide what initializations you needs and remove the unneeded.
> But keep in mind, if the package changes, you have to add/remove/rename
> units yourself.
Sorry, I lost you on the last statement. Could you explain. I use a
package called fpgui_toolkit.lpk. I can add, remove or change units,
and it doesn't affect the projects using that packages. I simply need
to recompile those projects.
- Graeme -
fpGUI - a cross-platform Free Pascal GUI toolkit
More information about the Lazarus