Go Down

Topic: Auto format spaces to indent (Read 51 times) previous topic - next topic

tmcfalls

How do you change the number of spaces  to indent in the latest version of ide?

Thanks



pert

  • Open {Arduino IDE installation folder}/lib/formatter.conf in a text editor.
  • Change line 11 according to your preference.
  • Save the file.
  • Restart the Arduino IDE.



Everything in the Arduino IDE installation folder is lost every time you update to a new version of the Arduino IDE. For this reason, any modifications you make to {Arduino IDE installation folder}/lib/formatter.conf need to be redone every time. Luckily, there is another place you can store that file which will not be affected by IDE updates. You can find the location of this folder by clicking the link at the line following File > Preferences > More preferences can be edited directly in the file. Save the modified formatter.conf to that location.

Go Up