We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2a5bf0e commit e6fdc3cCopy full SHA for e6fdc3c
app/src/processing/app/Editor.java
@@ -2016,6 +2016,11 @@ private boolean handleSave2() {
2016
statusNotice(tr("Saving..."));
2017
boolean saved = false;
2018
try {
2019
+ if (PreferencesData.getBoolean("editor.autoformat_currentfile_before_saving")) {
2020
+ Tool formatTool = getOrCreateToolInstance("cc.arduino.packages.formatter.AStyle");
2021
+ formatTool.run();
2022
+ }
2023
+
2024
boolean wasReadOnly = sketchController.isReadOnly(BaseNoGui.librariesIndexer.getInstalledLibraries(), BaseNoGui.getExamplesPath());
2025
String previousMainFilePath = sketch.getMainFilePath();
2026
saved = sketchController.save();
0 commit comments