[Lazarus] Component palette enhancements
Michael Van Canneyt
michael at freepascal.org
Fri Apr 8 14:30:11 CEST 2022
On Fri, 8 Apr 2022, Sven Barth via lazarus wrote:
> Marco van de Voort via lazarus <lazarus at lists.lazarus-ide.org> schrieb am
> Fr., 8. Apr. 2022, 11:58:
>
>>
>> IOW in which cases is disambiguation in the class registration of the
>> generated app needed?
>>
>>
>> Sure, the IDE is also a FPC/Lazarus app, but it has more leeway for
>> solutions that doesn't require changes to the way EVERY APP streams its
>> forms.
>>
>
> The use case that Michael has in mind is that inside an app you have a
> StdCtrls.TButton and a MyControls.TButton. Right now one *must* rename ones
> own even though the full name including unit name is unique.
>
> Solving this would at the same time allow the IDE to have a TButton for
> both the LCL and e.g. Web Components Library. Right now they need to be
> named differently like WebCtrls.TWButton.
Exactly so. I can't explain it clearer than this.
Streaming destroys the namespaces that units offer.
And while I've been aware of this issue for a long time and have studied the
solution, the second problem is now becoming acute:
I have 2 TJSONDatasets and 2 TRESTDatasets... (and more will follow)
The solution (activate unit scoped identifiers for streaming) is just taking
existing concepts to their logical conclusion.
It's simply a pity Borland didn't go all the way when they designed the
streaming; All I am proposing is to complete the work.
(in a backwards compatible manner, to boot)
Michael.
More information about the lazarus
mailing list