mirror of
https://github.com/esp8266/Arduino.git
synced 2025-06-16 11:21:18 +03:00
Making editor font size apply to serial monitor and console (Paul Stoffregen)
http://code.google.com/p/arduino/issues/detail?id=550
This commit is contained in:
@ -88,7 +88,9 @@ public class EditorConsole extends JScrollPane {
|
|||||||
Color bgColor = Theme.getColor("console.color");
|
Color bgColor = Theme.getColor("console.color");
|
||||||
Color fgColorOut = Theme.getColor("console.output.color");
|
Color fgColorOut = Theme.getColor("console.output.color");
|
||||||
Color fgColorErr = Theme.getColor("console.error.color");
|
Color fgColorErr = Theme.getColor("console.error.color");
|
||||||
Font font = Theme.getFont("console.font");
|
Font consoleFont = Theme.getFont("console.font");
|
||||||
|
Font editorFont = Preferences.getFont("editor.font");
|
||||||
|
Font font = new Font(consoleFont.getName(), consoleFont.getStyle(), editorFont.getSize());
|
||||||
|
|
||||||
stdStyle = new SimpleAttributeSet();
|
stdStyle = new SimpleAttributeSet();
|
||||||
StyleConstants.setForeground(stdStyle, fgColorOut);
|
StyleConstants.setForeground(stdStyle, fgColorOut);
|
||||||
|
@ -62,7 +62,9 @@ public class SerialMonitor extends JFrame implements MessageConsumer {
|
|||||||
|
|
||||||
getContentPane().setLayout(new BorderLayout());
|
getContentPane().setLayout(new BorderLayout());
|
||||||
|
|
||||||
Font font = Theme.getFont("console.font");
|
Font consoleFont = Theme.getFont("console.font");
|
||||||
|
Font editorFont = Preferences.getFont("editor.font");
|
||||||
|
Font font = new Font(consoleFont.getName(), consoleFont.getStyle(), editorFont.getSize());
|
||||||
|
|
||||||
textArea = new JTextArea(16, 40);
|
textArea = new JTextArea(16, 40);
|
||||||
textArea.setEditable(false);
|
textArea.setEditable(false);
|
||||||
@ -225,4 +227,4 @@ public class SerialMonitor extends JFrame implements MessageConsumer {
|
|||||||
}
|
}
|
||||||
}});
|
}});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user