Skip to content

Commit 9a86598

Browse files
authored
Make PrintStream use UTF-8 on every platform
Let's see if this fixes #1249
1 parent 0c43ebf commit 9a86598

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

java/src/processing/mode/java/Commander.java

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -88,18 +88,8 @@ public Commander(String[] args) {
8888
int task = HELP;
8989
boolean embedJava = true;
9090

91-
if (Platform.isWindows()) {
92-
// On Windows, it needs to use the default system encoding.
93-
// https://github.com/processing/processing/issues/1633
94-
systemOut = new PrintStream(System.out, true);
95-
systemErr = new PrintStream(System.err, true);
96-
} else {
97-
// OS X formerly used MacRoman or something else useless.
98-
// (Not sure about Linux, but this has worked since 2.0)
99-
// https://github.com/processing/processing/issues/1456
100-
systemOut = new PrintStream(System.out, true, StandardCharsets.UTF_8);
101-
systemErr = new PrintStream(System.err, true, StandardCharsets.UTF_8);
102-
}
91+
systemOut = new PrintStream(System.out, true, StandardCharsets.UTF_8);
92+
systemErr = new PrintStream(System.err, true, StandardCharsets.UTF_8);
10393

10494
int argOffset = 0;
10595
for (String arg : args) {

0 commit comments

Comments
 (0)