Author Topic: 2015 color scheme switching  (Read 2672 times)

0 Members and 1 Guest are viewing this topic.

kenkrupa

  • Newt
  • Posts: 84
2015 color scheme switching
« on: April 19, 2014, 02:25:25 PM »
Trying to provide alternate icons for the new dark scheme. I'm not equipped for providing resource dll's, as suggested elsewhere, so I came up another scheme. My idea is to provide two cuix files, and swap as needed between a MenuUnload and a MenuLoad. This works as expected for the ribbon icons, but the toolbars (using the same bmp's) seem to remain unchanged. I have tried deleting the mnr file in between also, and AutoCAD creates a new one, but still no change in the toolbar button image. Going to CUI to look at it, the toolbar icon is shown as the correct one, same as for the ribbon. But so far I can't find how to make the toolbar images update. Anyone know what's going on here? Where the heck can the toolbars be getting the wrong images from?

kenkrupa

  • Newt
  • Posts: 84
Re: 2015 color scheme switching
« Reply #1 on: April 19, 2014, 03:07:52 PM »
Found the answer myself! (Even a blind squirrel will find a nut once in a while.) The ribbon was always getting its images from the bmp's in the cuix, but the toolbars were finding the bmp files still on my search path. Once I removed them, the toolbars would also take the images from the cuix, and give the expected result. With that, the swap, together with deleting both the .mnr and _light.mnr file in between, seems to work.

Crank

  • Water Moccasin
  • Posts: 1503
Re: 2015 color scheme switching
« Reply #2 on: April 19, 2014, 03:21:56 PM »
The 2 color schemes already use different .CUIx files.
YOUMENU.cuix for the dark icons and YOURMENU_light.cuix for the light ones.

As usual this isn't finished by Autodesk, because the CUI doesn't have the option to define 2 sets of icons.
If you're using .dll files for your icons then you'll have to create a YOURMENU.dll and a YOURMENU_light.dll to make it work.

If making 2 .dll files is to much work (my cuix has about 1000 special icons :P) then this is what you can try (NOT TESTED):
  • First compile your menu with the light icons
  • Make a copy of YOURMENU_light.cuix and YOURMENU_light.mnr
  • Close Autocad
  • Rename YOURMENU.cuix to YOURMENU.zip
  • unzip this file , replace the light icons for the dark ones.
  • Make a new zip file and rename it to YOURMENU.cuix again
  • Start Autocad and recompile YOURMENU
  • Now place the copies of files YOURMENU_light.cuix , YOURMENU_light.mnr and copies of the new YOURMENU.cuix and YOURMENU.mnr in a new folder.
  • Make sure that this folder is read-only
  • In OPTIONS make this the ENTERPRISE search path
In theory this should work , but you'll have to do it all over again if you want to change something. So I'll stick to the light icons until Autodesk solves this. ;)
Vault Professional 2023     +     AEC Collection

snownut2

  • Swamp Rat
  • Posts: 971
  • Bricscad 22 Ultimate
Re: 2015 color scheme switching
« Reply #3 on: April 19, 2014, 03:22:21 PM »
(Even a blind squirrel will find a nut once in a while.)

Why do you think they hide their nuts in all sorts of places in the fall, so no matter where they look they have a good chance of finding them through to winter months..(at least in the snow belt)

kenkrupa

  • Newt
  • Posts: 84
Re: 2015 color scheme switching
« Reply #4 on: April 19, 2014, 03:28:14 PM »
The 2 color schemes already use different .CUIx files.
YOUMENU.cuix for the dark icons and YOURMENU_light.cuix for the light ones.
I did not know this. I'll see what I can do with it. Thanks.

kenkrupa

  • Newt
  • Posts: 84
Re: 2015 color scheme switching
« Reply #5 on: April 19, 2014, 04:51:08 PM »
The 2 color schemes already use different .CUIx files.
YOUMENU.cuix for the dark icons and YOURMENU_light.cuix for the light ones.
I did not know this. I'll see what I can do with it. Thanks.
Well, I don't see anything happening with a mymenu_light.cuix file. I see AutoCAD creating a mymenu_light.mnr file, whether I have a mymenu_light.cuix file or not. But I don't see it doing anything with the mymenu_light.cuix file.

This is what does work for me. I created the two .cuix versions, opening the cuix with WinZip to get the right bmp's in each. I can then unload one, swap the two files, delete both mymenu.mnr and mymenu_light.mnr, and reload the cuix (now swapped). So, I will go with this, and create a routine to make it happen.

Crank

  • Water Moccasin
  • Posts: 1503
Re: 2015 color scheme switching
« Reply #6 on: April 20, 2014, 04:03:08 AM »
If you delete the .mnr files MYMENU.cuix is recompiled again. Then MYMENU.cuix and MYMENU_light.cuix will have the same icons again.
Like I've descibed you'll have to split both versions first, so both .mnr files contain different sets of icons. Then protect them so they can't be compiled.
Vault Professional 2023     +     AEC Collection