• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

Dynamic icons for Indesign plugin custom palette

Contributor ,
Jul 25, 2022 Jul 25, 2022

Copy link to clipboard

Copied

Hi,

I would like to understand what is the idrc_PNGA and idrc_PNGD folders inside of .InDesignPlugin files on Mac. Are these part of standard structure of .InDesign plugins? An additional question I have is about immutability of .idrc files inside of this folder. Is idrc_PNGA an appropriate folder to dynamically modify the .idrc files from within our plugin logic with updated .png images or is there another folder in here somewhere that is appropriate for such intent. Also, given that the plugins are signed and notarized before shipment, it certainly does not feel right to update these sub folders dynamically, but I am not an expert and hence not sure.

 

asaxena_1-1658741481207.png

Please advice.

Thanks

Views

208

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Aug 28, 2022 Aug 28, 2022

Copy link to clipboard

Copied

[Moderator moved from End of Life Business Catalyst to InDesign.]

 

Nancy O'Shea— Product User, Community Expert & Moderator

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Contributor ,
Mar 24, 2023 Mar 24, 2023

Copy link to clipboard

Copied

Hi,

 

Checking back if there is any recommendation on my question.

 

Thank you

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Guide ,
Mar 29, 2023 Mar 29, 2023

Copy link to clipboard

Copied

LATEST

When you search the SDK for the text"PNGA", you'll find plenty example .fr resource files, plus declarations for kPNGArtRsrcType.

In short, PNGA is for the light UI, PNGD is for dark UI. There is also a hard wired ID offset for HiDPI versions (scale 2x on Mac, or 1.5x on Windows). Once upon a time there was also PNGR and PNGK for mouse-over variants (with subtle colour changes).

When you follow the symbolic names of those IDs within the examples, you'll find other resources where widgets refer to the icons. The appropriate interface has setters so you can change the ID to a different preexisting icon - if that is dynamic enough.

Besides, there are other headers to custom draw PNG icons, you find them by searching for "PNGArt" .

Finally, while PNG is still supported the new hot icon format (think of UI scaling) is a subset of SVG, matching resource types conveniently declared directly below kPNGArtRsrcType and friends.

 

PS: You are not supposed to modify resources after compilation, in an appropriately administered system these folders are readonly. Use custom draw if you dynamically load your icons from somewhere else.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines