Dark Theme confusion

So I'd like to try the dark theme - greyed out comments are just weird.

I load Jeff Thompsons' darktheme from github and it's in the 'Arduino/lib/theme/syntax' folder. The description states "Revised for Arduino version 1.6.6+, not tested with earlier versions." at the top. I've got v 1.8.2. Further down it is stated "The newest version of the Arduino IDE makes creating custom themes trickier: you now need to edit the theme.txt file, an XML file inside the syntax folder, and the button files. "

From a cursory scan of the default file and the dark file they appear structurally the same but the color settings are, of course, different.

Is there a setting somewhere to select the theme file?

Do I need to rename dark to default?

Basically, what are the mechanics of changing the theme?

dougp:
Is there a setting somewhere to select the theme file?

Not that I know of, you just need to replace the current theme files with the new ones. I don't think there's any easy way to switch between multiple installed themes.

dougp:
Do I need to rename dark to default?

No.

dougp:
Basically, what are the mechanics of changing the theme?

Here are a collection of some other themes that can be installed the same way:

Here's some documentation and a test sketch if you want to modify the Arduino IDE theme:

Thank you. I'll report my results.

Got it! ;D

Karma thanks to you.

A new issue has arisen. I am prevented from tweaking colors in the theme file. The colors for the matching brackets are perverse.

I can view the file with the XML editor, the one that shows the fancy colors but cannot change anything.

I can change things using notepad but am denied access when hitting 'save' (the altered file).

OS - Win7 pro

Continue here or, start a new thread?

arduino forum 5.PNG
arduino forum 6.PNG

p.s. I think there should be auto-karma just for going through the harangue of posting pics here. >:(

arduino forum 6.PNG

Have you tried it with the Arduino IDE not running? It works for me using Windows even with the IDE running so that's probably not the issue.

Make sure the file is not open in any other program such as this XML editor you mentioned.

pert:
Have you tried it with the Arduino IDE not running?

That was the first issue I cleared up. I got an 'in use by others' type of message because the IDE was active. Cleared that.

pert:
Make sure the file is not open in any other program such as this XML editor you mentioned.

Tried it both ways, notepad only and xml editor only. Same result either way.

On a hunch I checked and found the program files folder was set to read only. I changed this and got part way through the (many) files and folders in there and started getting a lot of 'couldn't change the settings for file X' messages. I clicked 'ignore' a few times then went to 'ignore all'. When it finished I still couldn't do any editing.

No doubt it's something simple, ya just gotta know where the switch for it is.

Maybe this needs a new thread, I dunno.

I've managed to make a few changes in the dark theme .xml file. I had to copy the file to the desktop, make the changes there, then copy back to the syntax folder. It's laborious but it works.

This theme looks like an unfinished project. Partly because there's a 'fix me' comment embedded. Partly because some of the color combinations don't work. One thing I changed was the colors used to highlight matching brackets, etc.

A related issue: If you cursor on to say, a closing curly brace and the opening mate for that is off-screen at the top a box is shown presenting the code of the matching off-screen line. The non-keyword text that appears there is invisible.


Question - what is the term for the message box? If I knew what to look for I could tinker with the colors but, most of that file is a mystery.

I tried to make the image bigger but couldn't.

dougp:
Question - what is the term for the message box?

That "message box" feature is more recent than any change to the theme files (it was only introduced in Arduino IDE 1.8.2) so you won't find theme settings specifically for it. It looks like some other theme properties are being reused there since obviously the colors aren't hardcoded. It's probably just using the same theme properties as used in the editor for that text. I've been calling the "message box" a "tooltip".

dougp:
most of that file is a mystery.

I've done my best to document the theme properties here:

if you find the purpose of any of the properties I've documented as "Doesn't appear to have any effect." please let me know and I'll update the documentation.

pert:
I've done my best to document the theme properties here:

If you find the purpose of any of the properties I've documented as "Doesn't appear to have any effect." please let me know and I'll update the documentation.

Just for giggles I checked a few. These, among others:

editor.literal1.style - Doesn't appear to have any effect.
editor.literal2.style - Doesn't appear to have any effect.
editor.variable.style - Doesn't appear to have any effect.

don't even appear in the dark theme file.

Oh, well perhaps a future version will shed some light.

Those properties are in theme.txt.

There are two sections of the documentation:

  • Settings found in lib/theme/theme.txt
  • Settings found in lib/theme/syntax/default.xml

For now I'll just live with it. It makes my head hurt looking at that. :confused:

Hello,

Does the Arduino IDE have a function where you can install themes is much the same way as VS Code can ?

Another Question

Can you use VS Code to code for the Arduino and upload from that instead of using the Arduino IDE ?

Thanks

edit C:\Program Files (x86)\Arduino\lib\theme\syntax\default.xml with notepad (run in administration mode)

problem :

replace:

you can change it if you want that:

In order to see the tooltip you need to edit the following in the theme.txt file:

editor.fgcolor = #d9d9d9

What is the situation on Arduino themes?
I see a "theme" setting in preferences, but the only choice is "default"
is GitHub - jeffThompson/DarkArduinoTheme: A dark theme for the Arduino IDE – no longer maintained :( still the real only option, and, does it work well on 1.8.10 ?