[Cuis-dev] [GOODIE] A script to display all icons

Juan Vuletich juan at cuis.st
Mon Mar 27 06:34:48 PDT 2023


Hi Folks,

On 3/27/2023 8:40 AM, Gerald Klix via Cuis-dev wrote:
> Hoi Berhard,
>
> I am not aware of any SVG icons in the base image,
> but I may have missed that.
> However, there are some vector graphic icons.

Yep. You're right.

> For example take the close icon.
> MorphicCanvas>>#drawCloseIcon is responsible for
> drawing it.  In BitBlitCanvas it looks like this:
>
> drawCloseIcon
> | icon |
>     icon := self class windowButtonIcon: #closeIcon size: currentMorph 
> morphWidth.
>     self pvtDrawButtonFaceForm: icon.
>
> #windowButtonIcon: retrives the icon from the theme.
>
> AbstractVectorCanvas>>#drawCloseIcon directly draws
> the red circle with the cross by sending path-messages
> to the canvas. The paths is cached in a class variables.

We've talked in the past about adding more of these. It should be 
possible to take a nice library of SVG icons and extract the paths from 
them, therefore not requiring the SVG package to use them. As usual, 
everything needs time and work!

> My script simply iterates over Theme's methods
> and sends those unary messages that end with 'Icon'.
> If the message send answers a form it creats (sic!)
> an image morph for it. So: Only bitmaps!
>
> It is certainly possible to iterate over
> the IconPathData class variables content and
> draw the path, but this will miss the color
> and may be some icons if this cache is not completely
> filled.
>
> In a nutshell: Discoverability of vector graphic icons
> leaves much to desired
>
>
> HTH,
>
> Gerald

Agreed!

Thanks,

-- 
Juan Vuletich
cuis.st
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich
linkedin.com/in/juan-vuletich-75611b3
twitter.com/JuanVuletich



More information about the Cuis-dev mailing list