There is no general Java way to do fancy screen control, because Java was
not intended for this kind of purpose. You may be able to send ANSI escape
sequences, but not all operating systems understand them.
You should be able to read one character at a time from System.in. The one
thing to watch out for is that System.in may be buffered.
Of course, if your operating system already processes data on a
line-by-line basis rather than character-by-character (both Windows and
Unix do by default), then you might have to turn that off first.
On Fri, 01 Aug 2003 17:26:02 +0000, Patrick Brown wrote:
I was just wondering what classes/methods are used to clear the
screen
of the console. Also, how can you take input from the keyboard so that
the enter key need not be used. ( e.g. the arrows for a snake-race game
)
--
Keep American Families united! Support H.R. 539 and H.R. 832
For more information, see
http://www.kkeane.com/lobbyspousal-faq.shtml