[Lazarus] Component palette enhancements

Sven Barth pascaldragon at googlemail.com
Wed Apr 6 17:07:49 CEST 2022


Michael Van Canneyt via lazarus <lazarus at lists.lazarus-ide.org> schrieb am
Mi., 6. Apr. 2022, 14:47:

>
>
> On Wed, 6 Apr 2022, Sven Barth via lazarus wrote:
>
> > Michael Van Canneyt via lazarus <lazarus at lists.lazarus-ide.org> schrieb
> am
> > Mi., 6. Apr. 2022, 12:56:
> >
> >>
> >> 1. Currently a component is identified by its class name.
> >>
> >>     This should be enhanced: a component must be identified with
> >> UnitName.Name.
> >>     a unit name is a "namespace" and so MyControls.TButton <>
> >> StdCtrls.TButton.
> >>
> >>     Currently there are several component name clashes in the pas2js and
> >> FPC class trees.
> >>
> >
> > The streaming system can't differentiate by unit name, so this simply
> isn't
> > possible.
>
> I know that.
>
> We simply need to adapt the streaming system so it can,
> I already studied that, it's fairly trivial:
>
> * When writing: write UnitName.ComponentName instead of ComponentName.
>    A trivial change, which can be done in a backward compatible manner.
>
> * When reading, there are 2 lines that must be changed:
>    One in GetClass and one in TReader.FindComponentClass.
>
> * To handle the text format, 2 lines need changing.
>
> So this is not exactly lots of work.
>

But then this needs to be in FPC first and there it will only be officially
available once 3.4.0 is released. And since Lazarus supports the last two
releases it would need to be handled in a way that allows the user to cater
to older FPC versions as well.



> > 3. Please add a search edit in the component palette, as delphi has it:
> >>     typing in that edit should reduce the visible tabs to show only tabs
> >> that have a
> >>     component with the typed text in the classname, just like the one on
> >> the component window...
> >>     (the component window is IMO not really usable if you are not using
> a
> >> docked IDE)
> >>
> >
> > Why don't you use the component list instead of the palette then? This
> > already provides a search.
>
> If you read my message correctly, you'll see that I know this.
> Additionally my last sentence tells you why I don't use it...
>

Gotta admit that I had only skimmed the last sentence ^^'

Regards,
Sven

>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20220406/0bf56c77/attachment.htm>


More information about the lazarus mailing list