Skip to content

Commit ccb17c5

Browse files
committed
avoid another "Zero length string passed to TextLayout constructor" error, other notes
1 parent 29bc3cb commit ccb17c5

4 files changed

Lines changed: 22 additions & 1 deletion

File tree

build/build.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -561,7 +561,8 @@
561561

562562
<!-- Sets dock icon when debugging (not launched via launch svcs) -->
563563
<option value="-Xdock:icon=$APP_ROOT/Contents/Resources/processing.icns" />
564-
<!-- Don't think these actually make any difference. -->
564+
<!-- Don't think these actually make any difference.
565+
(The apple.awt.application.name property is used.)-->
565566
<!--
566567
<option value="-Xdock:name=Processing" />
567568
-->

core/src/processing/awt/PGraphicsJava2D.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1942,6 +1942,10 @@ protected float textWidthImpl(char buffer[], int start, int stop) {
19421942
if (textFont == null) {
19431943
defaultFontOrDeath("textWidth");
19441944
}
1945+
// Avoid "Zero length string passed to TextLayout constructor" error
1946+
if (start == stop) {
1947+
return 0;
1948+
}
19451949

19461950
Font font = (Font) textFont.getNative();
19471951
// System.out.println(font);

core/todo.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,16 @@
11
0248 (3.0.2)
22

3+
andres
4+
X Stop button in OpenGL exported applications does not use preference settings
5+
X https://github.com/processing/processing/issues/4064
6+
X Export without a stop button using P3D or P2D
7+
X https://github.com/processing/processing/issues/4056
38

9+
10+
_ fix menu bar hiding in exported JavaFX apps
11+
_ just call it around setup time?
12+
_ should fullScreen() set width and height to displayWidth/Height
13+
_ or is that being set/unset used for any state info?
414
_ when calling exit(), if sketch has halted w/ exception, force the quit
515
_ otherwise have to double-quit with cmd-q on OS X
616
_ simple test case: using size() inside setup() from Eclipse

todo.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
0248 (3.0.2)
22

33

4+
contribs
5+
X add "full screen" option to the Editor on OS X
6+
X https://github.com/processing/processing/issues/3993
7+
X https://github.com/processing/processing/pull/4078
8+
9+
410
more contribs
511
_ question about PDE_pt-br instead of PDE_pt
612
_ https://github.com/processing/processing/issues/4018

0 commit comments

Comments
 (0)