Skip to content

Commit 67b65dd

Browse files
author
Federico Fissore
committed
Restored background color when switching off "external editor" flag in preferences. Fixes #3197
1 parent e8eb06a commit 67b65dd

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

app/src/processing/app/Editor.java

+3-4
Original file line numberDiff line numberDiff line change
@@ -477,14 +477,13 @@ public void applyPreferences() {
477477

478478
if (external) {
479479
// disable line highlight and turn off the caret when disabling
480-
Color color = Theme.getColor("editor.external.bgcolor");
481-
textarea.setBackground(color);
480+
textarea.setBackground(Theme.getColor("editor.external.bgcolor"));
482481
textarea.setHighlightCurrentLine(false);
483482
textarea.setEditable(false);
484483

485484
} else {
486-
boolean highlight = PreferencesData.getBoolean("editor.linehighlight");
487-
textarea.setHighlightCurrentLine(highlight);
485+
textarea.setBackground(Theme.getColor("editor.bgcolor"));
486+
textarea.setHighlightCurrentLine(PreferencesData.getBoolean("editor.linehighlight"));
488487
textarea.setEditable(true);
489488
}
490489

0 commit comments

Comments
 (0)