From 4b42438eb7d8ef0febccb4c649d6954dfeb6a9fc Mon Sep 17 00:00:00 2001 From: Ben Fry Date: Sat, 29 Jan 2022 07:56:34 -0500 Subject: [PATCH] adding class to debug editor scaling issues --- .../processing/app/syntax/SyntaxDebug.java | 37 +++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 app/src/processing/app/syntax/SyntaxDebug.java diff --git a/app/src/processing/app/syntax/SyntaxDebug.java b/app/src/processing/app/syntax/SyntaxDebug.java new file mode 100644 index 000000000..2a7667569 --- /dev/null +++ b/app/src/processing/app/syntax/SyntaxDebug.java @@ -0,0 +1,37 @@ +package processing.app.syntax; + +import javax.swing.JFrame; +import javax.swing.WindowConstants; +import java.awt.Dimension; + +import processing.app.Platform; +import processing.app.Preferences; +import processing.app.ui.Theme; + + +public class SyntaxDebug extends JFrame { + JEditTextArea area; + + public SyntaxDebug() { + Platform.init(); + Preferences.init(); + Theme.init(); + + area = new JEditTextArea(new PdeTextAreaDefaults(), + new PdeInputHandler(null)); + + area.setText("abcdefghijklmnopqrstuvwxyz0123456789"); + + add(area); + //setMinimumSize(new Dimension(500, 400)); + pack(); + setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE); + setMinimumSize(new Dimension(500, 400)); + setVisible(true); + } + + + static public void main(String[] args) { + new SyntaxDebug(); + } +} \ No newline at end of file