Monday, January 19, 2015

Unicode output in Eclipse console

After much googling and trying I finally found the trivial (and obvious) solution on how to correctly display unicode characters in the Eclipse console window. One simply has to specify UTF-8 output in the Run Configuration (click on the image to enlarge it):

There is no special code (e.g. PrintWriter with UTF-8 format) required. Something like

System.out.println("\u00C6\u00D8\u00C5") // Danish letters Æ Ø Å 

will work just fine.