From 1c5538c3c554ffef6ce1694183ffd7d89e8735fc Mon Sep 17 00:00:00 2001 From: benfry Date: Wed, 30 Jul 2003 00:24:59 +0000 Subject: [PATCH] trying to disable text anti-aliasing on macosx --- processing/app/PdeEditorConsole.java | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/processing/app/PdeEditorConsole.java b/processing/app/PdeEditorConsole.java index e0098946e..bcf01ac4f 100644 --- a/processing/app/PdeEditorConsole.java +++ b/processing/app/PdeEditorConsole.java @@ -59,7 +59,21 @@ public class PdeEditorConsole extends JScrollPane { public PdeEditorConsole(PdeEditor editor) { this.editor = editor; - consoleTextPane = new JTextPane(); + consoleTextPane = new JTextPane() { + public void paint(Graphics g) { +#ifdef JDK13 + if (PdeBase.platform == PdeBase.MACOSX) { + if (PdeBase.getBoolean("editor.console.antialias", + false) == false) { + Graphics2D g2 = (Graphics2D) g; + g2.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, + RenderingHints.VALUE_TEXT_ANTIALIAS_OFF); + } + } +#endif + super.paint(g); + } + }; consoleTextPane.setEditable(false); consoleDoc = consoleTextPane.getStyledDocument();