- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
Is there a proper way to create a toolbar icon so that it looks the same whether the Window Elements Color scheme is set to Dark or Light? I can create an icon with certain colors (mostly the background of the icon) and it looks perfect in Light scheme, but if I set my color scheme to Dark, it looks crappy.
All the Autocad icons look correct no matter whether you're in dark or light.
I attached screen shots of icons in both Windows Element Color Scheme settings.
I must have to build the icon bmp a certain way?
Thanks.
¡Resuelto! Ir a solución.
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
Jimmy Bergmark
JTB World - Software development and consulting for CAD and license usage reports
https://jtbworld.com
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
I haven't heard about way. Can you give me some direction, or point me to literature on how to do that? Thank-you
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
Jimmy Bergmark
JTB World - Software development and consulting for CAD and license usage reports
https://jtbworld.com
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
I disagree, the background has nothing to do with the question.
The image attached to the original post shows two bitmaps with different colors. In one the arrow is black in the other is gray.
Those are two different bitmaps, they are not the same bitmap that looks good in both light and dark theme.
The correct answer is to create two sets of bitmaps (I'm pretty sure about this), then (I'm less sure about this) to use COLORTHEME to decide whether to load the light or the dark one. Using COLORTHEME would work when the icons are loaded, but wouldn't help if the user changes theme during the session. I don't know if there is an event triggered when the value of COLORTHEME changes.
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
Dear stefanomenci! You are absolutely right!
We have to make different Icons for Dark and Light Themes, and allow AutoCAD to automatically change them on Toolbars and Ribbons (but not in PopUp Menus still using Light Theme only) when user changes the color Theme.
To achieve this we have to use ICO's but not PNG's (or even more old bad BMP's) and put them to DLL with our "MenuName" as a feile names: "MenuName.dll" for Dark Theme and "MenuName_light.dll" for Light Theme. Also we can use 16x16 and 32x32 icons for small and big Toolbar buttons if you can imagine youself using these very big buttons! ; ))
AutoCAD will change icons according to current Theme.
It seems to me we can't use individual PNG or BMP (or even ICO) files and force AutoCAD change icons from Theme to Theme.
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
Hi @alexKoshman, thanks for the reply.
@alexKoshman wrote:To achieve this we have to use ICO's but not PNG's (or even more old bad BMP's) and put them to DLL with our "MenuName" as a feile names: "MenuName.dll" for Dark Theme and "MenuName_light.dll" for Light Theme
Are you saying that AutoCAD automatically switches dll as soon as the value of COLORTHEME changes, simply by adding the "_light" suffix to the dll name?
Or are you describing your way to store the images on your add-in, and you decide which dll to use when the add-in is first loaded on each session?
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
>>"Is this feature documented?
Yes
https://help.autodesk.com/view/ACD/2021/ENU/?guid=GUID-9AA3EEC1-031C-4E88-A966-4CBC07AD112C
>>"If not, can you show an example?"
If or if not, why not create your own?
Create a Sample1.cuix with a button which refer to the Icon "Test"
Create Sample1.dll with one Icon "Test"
Create another dll Sample1_light.dll,
also with another Icon "Test"
Put all three files in a folder and test it.
Dark will show the one and light will show the other Icon.
If it isn't working, we will help you to find your issue (wrong image name in cuix, old mnr files, whatever)
Sebastian
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
Oh! I do can show it for you!
In AutoCAD Help documentation! : )))
Like this: https://knowledge.autodesk.com/support/autocad/troubleshooting/caas/sfdcarticles/sfdcarticles/The-to...
And that: https://knowledge.autodesk.com/support/autocad-lt/learn-explore/caas/CloudHelp/cloudhelp/2018/ENU/Au...
CADffm! I'm sure you can find that right in your AutoCAD Help by typing "About Managing and Sharing Custom Images"! ; ))
And on this forum: https://forums.autodesk.com/t5/objectarx/how-to-support-autocad-2015-dark-amp-light-themes-for-ribbo...
- Marcar como nuevo
- Favorito
- Suscribir
- Silenciar
- Suscribirse a un feed RSS
- Resaltar
- Imprimir
- Denunciar
>>"In AutoCAD Help documentation!"
Both target pages are not part of the Product documentation, but also a good source.
Kudos for you.
Sebastian