EtheaDev / IconFontsImageList

Four advanced components to simplify use of Icon Fonts as images and ImageList: TIconFontImage, TIconFontsImageCollection, TIconFontsVirtualImageList, TIconFontsImageList (for VCL and FMX). Full support for High-DPI apps. Rendering optimized with GDI+
Apache License 2.0
218 stars 55 forks source link

Multi size icons or Small/Large icons #16

Closed SoyYako closed 4 years ago

SoyYako commented 4 years ago

Hi, Sorry for my poor english.

We have 24px or 32px icon images for the toolbar buttons, but only 16px for the MenuBar or PopMenu. So, we have 2 IconFontsImageList, one for 32px icons and other for 16px.

First, load in DESIGN mode (manyually by CharMap tool) the 32px IconFontsImageList. Next, in RUNTIME mode, fill a second IconFontsImageList for 16px icons like this:

IconFontsImageList16.Clear; IconFontsImageList16.Assign( IconFontsImageList 32 );

But, this forces us to duplicate the component. Perhaps if 2 new properties were included, such as SamallIconSize=nn and LargeIconSize=nn in the same IconFontsImageList its a solution,

any suggestion?

carloBarazzetta commented 4 years ago

Hi, I'm working on a solution based on TVirtualImageList and TImageCollection (available only from Delphi 10.3) to define an TIconFontsImageCollection (the list of the icons to use) and a VirtualImageList that uses the collection at specific size (and request a specific new size when the DPI of the form changes). Stay tuned!

carloBarazzetta commented 4 years ago

Today I've pushed a new version, with big refactoring and new components... Please test with the new version 2.2: now you can use native Delphi VirtualImageList linked to IconFontsImageCollection, to resolve every problems with multiple forms, multiple monitors with different DPI or multiple imagelist with different icon sizes. Look also to the new supporto for Categories. Please give me a feed-back ASAP, because I've made many changes!

carloBarazzetta commented 4 years ago

Any comment @SoyYako ? Can I close this issue?