• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Knute Snortum
  • Bear Bibeault
Saloon Keepers:
  • Ron McLeod
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Ganesh Patekar
Bartenders:
  • Frits Walraven
  • Carey Brown
  • Tim Holloway

interactive command line

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to build a program with an interactive command line. The screen have to be split in two areas: on the top of the screen, may be displayed the program itself and on the bottom of the screen, an interactive command line. This program is going to run in a console, so I can't use GUI interfaces (swing, awt, etc.). Is there any way to make it? As for now, my difficulty has been how to position the input command line on the correct line of the console view.
 
Ranch Hand
Posts: 1923
Scala Postgres Database Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you use Ansi-Escape-Sequences, it's possible, but complicated.

a) You need an Ansidriver (often found implicitly on Linux, and on older Windows too (Ansi.sys).
b) Ansi was mostly used with 80x25 Displays. I don't know how it works on current machines. Resizing a window may lead to a trashy screen.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!