View Single Post
Old 09-14-2023, 10:01 AM   #205
Nicolas F
Groupie
Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.Nicolas F once ate a cherry pie in a record 7 seconds.
 
Posts: 161
Karma: 1842
Join Date: Jan 2016
Device: Kobo Glo HD
Quote:
Originally Posted by kovidgoyal View Post
Themeing means the user installs an icon theme that has support for your plugin, then get_icons() will use icons from that theme if available, falling back to the icons in the plugin zip file when no icon is found in the theme.
Thanks for answering,

yes I've mad the material and highlight themes for calibre a few years ago but the for-dark-theme / for-light-theme icons don't seem to work for themes.

It works with thiago.eec's plugins but I downloaded the Interface Plugin Demo from calibre website (Interface Plugin Demo.zip) and it doesn't see the custom icons.

The code for the demo plugin is
Code:
icon = get_icons('images/icon.png', 'Interface Plugin Demo')
If I understand it correctly I should be able to use "images/Interface Plugin Demo/icon-for-dark-theme.png" and get the icon in dark mode.

thiago.eec's plugin that works doesn't seem to use the default implementation.
Nicolas F is offline   Reply With Quote