java - Extended Ascii doesn't work in console! -


for example system.out.println("╚"); displays ?, same goes system.out.println("\u255a");

why doesn't work? stdout indeed support these characters don't it.

see this question. when java’s default character encoding not utf-8 — case, seems, on windows , os x, not linux — characters fail encode converted question marks. can pass correct switch (-dfile.encoding=utf-8 on terminals, don’t have windows box in front of me) jvm’s command line, or can set environment variable. portably determining should might impossible, if know run on win32 console, example, can choose charset explicitly encode characters before writing them standard output, or can directly write bytes need.


Comments

Popular posts from this blog

linux - Mailx and Gmail nss config dir -

c# - Is it possible to remove an existing registration from Autofac container builder? -

php - Mysql PK and FK char(36) vs int(10) -