[Lazarus] Unused units clarification

Juha Manninen juha.manninen62 at gmail.com
Sat Oct 25 12:56:35 CEST 2014


This is related to the "Request feature" thread answer from Mattias at
October 3.

On Fri, Oct 3, 2014 at 10:27 AM, Mattias Gaertner
<nc-gaertnma at netcologne.de> wrote:
> The units with initialization/finalization sections are shown with a
> battery like icon, while those without are shown with a book icon.
>
> Feel free to improve it with a checkbox "hide units with
> initialization/finalization sections".

I did that in r46659, although I phrased a "positive" sentence:
  [x] Show units with initialization/finalization sections
which is checked by default.
Does it work correctly?

The meaning of those battery and book icons is not obvious for a new user.
I had an idea of adding a "Legend" icon and label to describe them.
The images come from resources already loaded, like this :

  UnitsTreeView.StateImages := IDEImages.Images_16;
  ImgIDInitialization := IDEImages.LoadImage(16, 'ce_initialization');

ImgIDInitialization is the index for the battery icon. It is used
later for TreeView nodes.
I would need something like TLegendLabel which takes an Images list
and index and shows an icon with a text, without duplicating a
resources.
If somebody was interested to make such component, I would add it to
LazControls.
It could be used in many places in the IDE to explain meanings of
different icons.

It is also possible there is component suitable for this task but I
don't know how to use it.
I have not programmed so much with graphics.

Juha




More information about the Lazarus mailing list