| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -794,26 +794,27 @@ public int xToOffset(int line, int x) { | |||
| 794 | 794 | } | |
| 795 | 795 | } | |
| 796 | 796 | ||
| 797 | + | ||
| 797 | 798 | /** | |
| 798 | 799 | * Converts a point to an offset, from the start of the text. | |
| 799 | 800 | * @param x The x co-ordinate of the point | |
| 800 | 801 | * @param y The y co-ordinate of the point | |
| 801 | 802 | */ | |
| 802 | - public int xyToOffset(int x, int y) | ||
| 803 | - { | ||
| 803 | + public int xyToOffset(int x, int y) { | ||
| 804 | 804 | int line = yToLine(y); | |
| 805 | 805 | int start = getLineStartOffset(line); | |
| 806 | 806 | return start + xToOffset(line,x); | |
| 807 | 807 | } | |
| 808 | 808 | ||
| 809 | + | ||
| 809 | 810 | /** | |
| 810 | 811 | * Returns the document this text area is editing. | |
| 811 | 812 | */ | |
| 812 | - public final SyntaxDocument getDocument() | ||
| 813 | - { | ||
| 813 | + public final SyntaxDocument getDocument() { | ||
| 814 | 814 | return document; | |
| 815 | 815 | } | |
| 816 | 816 | ||
| 817 | + | ||
| 817 | 818 | /** | |
| 818 | 819 | * Sets the document this text area is editing. | |
| 819 | 820 | * @param document The document | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -438,6 +438,12 @@ public FontMetrics getFontMetrics(SyntaxStyle style) { | |||
| 438 | 438 | } | |
| 439 | 439 | ||
| 440 | 440 | ||
| 441 | + // fry [160806 for 3.2] | ||
| 442 | + public int getLineHeight() { | ||
| 443 | + return fm.getHeight() + fm.getDescent(); | ||
| 444 | + } | ||
| 445 | + | ||
| 446 | + | ||
| 441 | 447 | // /** | |
| 442 | 448 | // * Sets the font for this component. This is overridden to update the | |
| 443 | 449 | // * cached font metrics and to recalculate which lines are visible. | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -2358,6 +2358,14 @@ public Point getSketchLocation() { | |||
| 2358 | 2358 | // } | |
| 2359 | 2359 | ||
| 2360 | 2360 | ||
| 2361 | + public boolean isDebuggerEnabled() { | ||
| 2362 | + return false; | ||
| 2363 | + } | ||
| 2364 | + | ||
| 2365 | + | ||
| 2366 | + public void toggleBreakpoint(int lineIndex) { } | ||
| 2367 | + | ||
| 2368 | + | ||
| 2361 | 2369 | /** | |
| 2362 | 2370 | * Check if the sketch is modified and ask user to save changes. | |
| 2363 | 2371 | * @return false if canceling the close/quit operation | |
@@ -2930,18 +2938,6 @@ public boolean isHalted() { | |||
| 2930 | 2938 | static Color bgColorError; | |
| 2931 | 2939 | ||
| 2932 | 2940 | ||
| 2933 | - /* | ||
| 2934 | - public void toolTipError(JComponent comp, String message) { | ||
| 2935 | - setToolTip(comp, message, true); | ||
| 2936 | - } | ||
| 2937 | - | ||
| 2938 | - | ||
| 2939 | - public void toolTipWarning(JComponent comp, String message) { | ||
| 2940 | - setToolTip(comp, message, false); | ||
| 2941 | - } | ||
| 2942 | - */ | ||
| 2943 | - | ||
| 2944 | - | ||
| 2945 | 2941 | public void statusToolTip(JComponent comp, String message, boolean error) { | |
| 2946 | 2942 | if (font == null) { | |
| 2947 | 2943 | font = Toolkit.getSansFont(9, Font.PLAIN); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,4 +1,4 @@ | |||
| 1 | - 0252 (3.1.3?) | ||
| 1 | + 0252 (3.2) | ||
| 2 | 2 | X some Table cleanup based on other CSV parsing work | |
| 3 | 3 | X use StandardCharsets.UTF_8 instead of getting encoding by name | |
| 4 | 4 | X PApplet.main(Blah.class) now works | |
@@ -7,6 +7,14 @@ _ do the same for the other data classes | |||
| 7 | 7 | _ note the difference between this and toJSONObject() or toJSONArray() | |
| 8 | 8 | _ or is that the better way to handle it? hm | |
| 9 | 9 | ||
| 10 | + jakub | ||
| 11 | + X Fix resizing targets for async save | ||
| 12 | + X https://github.com/processing/processing/pull/4607 | ||
| 13 | + X https://github.com/processing/processing/issues/4578 | ||
| 14 | + | ||
| 15 | + _ disable OpenGL ES on Linux? | ||
| 16 | + _ https://github.com/processing/processing/issues/4584 | ||
| 17 | + | ||
| 10 | 18 | ||
| 11 | 19 | _ Can't render PGraphics object using image() within a PDF | |
| 12 | 20 | _ https://github.com/processing/processing/issues/4473 | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -126,7 +126,8 @@ protected JavaEditor(Base base, String path, EditorState state, | |||
| 126 | 126 | ||
| 127 | 127 | getJavaTextArea().setMode(jmode); | |
| 128 | 128 | ||
| 129 | - initPDEX(); | ||
| 129 | + preprocessingService = new PreprocessingService(this); | ||
| 130 | + pdex = new PDEX(this, preprocessingService); | ||
| 130 | 131 | ||
| 131 | 132 | Toolkit.setMenuMnemonics(textarea.getRightClickPopup()); | |
| 132 | 133 | ||
@@ -146,18 +147,12 @@ public void caretUpdate(CaretEvent e) { | |||
| 146 | 147 | }); | |
| 147 | 148 | } | |
| 148 | 149 | ||
| 149 | - | ||
| 150 | + | ||
| 150 | 151 | public PdePreprocessor createPreprocessor(final String sketchName) { | |
| 151 | - return new PdePreprocessor(sketchName); | ||
| 152 | + return new PdePreprocessor(sketchName); | ||
| 152 | 153 | } | |
| 153 | 154 | ||
| 154 | - | ||
| 155 | - protected void initPDEX() { | ||
| 156 | - preprocessingService = new PreprocessingService(this); | ||
| 157 | - pdex = new PDEX(this, preprocessingService); | ||
| 158 | - } | ||
| 159 | - | ||
| 160 | - | ||
| 155 | + | ||
| 161 | 156 | protected JEditTextArea createTextArea() { | |
| 162 | 157 | return new JavaTextArea(new PdeTextAreaDefaults(mode), this); | |
| 163 | 158 | } | |
@@ -1195,12 +1190,13 @@ public void handleContinue() { | |||
| 1195 | 1190 | } | |
| 1196 | 1191 | ||
| 1197 | 1192 | ||
| 1198 | - /** Toggle a breakpoint on the current line. */ | ||
| 1199 | - public void toggleBreakpoint() { | ||
| 1200 | - debugger.toggleBreakpoint(getCurrentLineID().lineIdx()); | ||
| 1201 | - } | ||
| 1193 | + // /** Toggle a breakpoint on the current line. */ | ||
| 1194 | + // public void toggleBreakpoint() { | ||
| 1195 | + // toggleBreakpoint(getCurrentLineID().lineIdx()); | ||
| 1196 | + // } | ||
| 1202 | 1197 | ||
| 1203 | 1198 | ||
| 1199 | + @Override | ||
| 1204 | 1200 | public void toggleBreakpoint(int lineIndex) { | |
| 1205 | 1201 | debugger.toggleBreakpoint(lineIndex); | |
| 1206 | 1202 | } | |
@@ -1430,7 +1426,8 @@ public void actionPerformed(ActionEvent e) { | |||
| 1430 | 1426 | item.addActionListener(new ActionListener() { | |
| 1431 | 1427 | public void actionPerformed(ActionEvent e) { | |
| 1432 | 1428 | Logger.getLogger(JavaEditor.class.getName()).log(Level.INFO, "Invoked 'Toggle Breakpoint' menu item"); | |
| 1433 | - toggleBreakpoint(); | ||
| 1429 | + // TODO wouldn't getCaretLine() do the same thing with less effort? | ||
| 1430 | + toggleBreakpoint(getCurrentLineID().lineIdx()); | ||
| 1434 | 1431 | } | |
| 1435 | 1432 | }); | |
| 1436 | 1433 | debugMenu.add(item); | |
@@ -1522,8 +1519,8 @@ public void actionPerformed(ActionEvent e) { | |||
| 1522 | 1519 | } | |
| 1523 | 1520 | ||
| 1524 | 1521 | ||
| 1522 | + @Override | ||
| 1525 | 1523 | public boolean isDebuggerEnabled() { | |
| 1526 | - //return enableDebug.isSelected(); | ||
| 1527 | 1524 | return debugEnabled; | |
| 1528 | 1525 | } | |
| 1529 | 1526 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments