|
From: Philip J. <pj...@un...> - 2012-01-31 03:47:20
|
On Jan 17, 2012, at 7:17 PM, Sheng Qiang Xu wrote: > I'm using jython 2.5.1 and my OS is windows XP and language is Chinese. > > When using java.lang.System.console().readline() to input text, I can only input a character (the behavior seems like pressing enter) and the console jumps to next line. > > Could somebody pls help to take a look at this? > Thanks. You probably have an incorrect input encoding value set on your platform. You can see what Jython uses for its input encoding by looking at the value of sys.stdin.encoding. You can try forcing it to say UTF-8 by passing "-Dpython.console.encoding=UTF-8" to Jython -- Philip Jenvey |