Asked  7 Months ago    Answers:  5   Viewed   32 times

I would like to write a Java terminal application that does screen manipulation. Are there any good libraries out there that allow you to manipulate the screen like curses in the *nix/C world?

Minimal features I'm looking for are windowing and user input support.

In feature-speak, I'd like to have a region of the terminal where some data is regularly updated while (at the same time) the user can enter commands/text in some other part of the screen.



There is Charva, which links to native code but has an api based on Swing. The screenshots show lots of text windows, so that looks useful.

Tuesday, June 1, 2021
answered 7 Months ago

If you were using JGraph, you should give a try to JGraphT which is designed for algorithms. One of its features is visualization using the JGraph library. It's still developed, but pretty stable. I analyzed the complexity of JGraphT algorithms some time ago. Some of them aren't the quickest, but if you're going to implement them on your own and need to display your graph, then it might be the best choice. I really liked using its API, when I quickly had to write an app that was working on graph and displaying it later.

Tuesday, June 1, 2021
answered 7 Months ago

Per default the of your gradle build is not wired up with the of the run (JavaExec) task. You can do the following:

// build.gradle (Groovy syntax)
run {
    standardInput =

// build.gradle.kts (Kotlin syntax)
tasks.named<JavaExec>("run") {
    standardInput = System.`in`
Sunday, June 13, 2021
answered 6 Months ago

First when you write, don't use writeln(). Use write(). Second, you can use a "r" to Carriage Return without using n which is a New line. The carriage return should put you back at the beginning of the line.

Wednesday, June 16, 2021
answered 6 Months ago

There is a wcurses. I've never tried it but it may meet your needs. It sounds like it doesn't have full curses compatibility, but may be close enough. Also it might not be using the DOS terminal, but opening a GUI window and drawing monospaced text inside.

Other windows text mode options are:

  • The console module;
  • wconio -- based on Borland's C conio library.

I believe both are windows only.

Wednesday, July 28, 2021
answered 4 Months ago
Only authorized users can answer the question. Please sign in first, or register a free account.
Not the answer you're looking for? Browse other questions tagged :