Skip to content

Commit

Permalink
added comment
Browse files Browse the repository at this point in the history
  • Loading branch information
jurgenvinju committed Apr 7, 2024
1 parent 2b41cf8 commit 8ee828c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/org/rascalmpl/repl/TerminalProgressBarMonitor.java
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,9 @@ private static class ANSI {
static boolean isUTF8enabled(PrintWriter writer, InputStream in) {
try {
int pos = getCursorPosition(writer, in);
writer.write("あ");
// Japanese A (あ) is typically 3 bytes in most encodings, but should be less than 3 ANSI columns
// on screen if-and-only-if unicode is supported.
writer.write("あ");
writer.flush();
int newPos = getCursorPosition(writer, in);
int diff = newPos - pos;
Expand Down

0 comments on commit 8ee828c

Please sign in to comment.