Skip to content

Commit 10aba52

Browse files
committed
Making editor font size apply to serial monitor and console (Paul Stoffregen)
http://code.google.com/p/arduino/issues/detail?id=550
1 parent eb380de commit 10aba52

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

Diff for: app/src/processing/app/EditorConsole.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,9 @@ public EditorConsole(Editor editor) {
8888
Color bgColor = Theme.getColor("console.color");
8989
Color fgColorOut = Theme.getColor("console.output.color");
9090
Color fgColorErr = Theme.getColor("console.error.color");
91-
Font font = Theme.getFont("console.font");
91+
Font consoleFont = Theme.getFont("console.font");
92+
Font editorFont = Preferences.getFont("editor.font");
93+
Font font = new Font(consoleFont.getName(), consoleFont.getStyle(), editorFont.getSize());
9294

9395
stdStyle = new SimpleAttributeSet();
9496
StyleConstants.setForeground(stdStyle, fgColorOut);

Diff for: app/src/processing/app/SerialMonitor.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,9 @@ public void actionPerformed(ActionEvent e) {
6262

6363
getContentPane().setLayout(new BorderLayout());
6464

65-
Font font = Theme.getFont("console.font");
65+
Font consoleFont = Theme.getFont("console.font");
66+
Font editorFont = Preferences.getFont("editor.font");
67+
Font font = new Font(consoleFont.getName(), consoleFont.getStyle(), editorFont.getSize());
6668

6769
textArea = new JTextArea(16, 40);
6870
textArea.setEditable(false);
@@ -225,4 +227,4 @@ public void run() {
225227
}
226228
}});
227229
}
228-
}
230+
}

0 commit comments

Comments
 (0)