Help with using Ncurses and C++
Hello, I have just spend the last few hours researching on both the list archives and using google without much success. I am looking at moving a project from a real-time (sort of) version of Windows NT to run under SuSE Linux 9.1.
From the OS perspective everything looks good, however one small subject is messing me up. Most of the code is written in C, compiled under C++ and it is our intention to rewrite to OO type C++. And while this also is pretty straight forward we are stumbling on a small problem. Most of the time the system runs with little input from the users, however there are quite a few setup screens that need to be on terminal type screens. We are using QT for the more complex setup screens but need to use Ncurses for the runtime stuff. Has anyone had an experience using Ncurses in a C++ class type programming?
I have found quite a few wrappers and such but all seem to have been dropped around late 2000 or in one case 2003. What are people actually using for this type of development? Would appreciate any help you could give and if you have a better suggestion would appreciate that as well. Thanks for your time, Charley
On Friday 21 May 2004 22:01, Charley wrote:
I have just spend the last few hours researching on both the list archives and using google without much success. I am looking at moving a project from a real-time (sort of) version of Windows NT to run under SuSE Linux 9.1. From the OS perspective everything looks good, however one small subject is messing me up. Most of the code is written in C, compiled under C++ and it is our intention to rewrite to OO type C++. And while this also is pretty straight forward we are stumbling on a small problem. Most of the time the system runs with little input from the users, however there are quite a few setup screens that need to be on terminal type screens. We are using QT for the more complex setup screens but need to use Ncurses for the runtime stuff. Has anyone had an experience using Ncurses in a C++ class type programming?
Have a look at the YaST2 NCurses UI. In fact, YaST2 uses an UI abstraction that provides both a Qt based and a NCurses based UI - if you use it from YCP, that is. Install the source RPMs for yast2-core, yast2-ncurses, yast2-qt. In the yast2-core source directory, look at libyui/doc/ and libyui/doc/examples to get an idea of what this looks like. One caveat, though: The YaST2 engine isn't anything you might want to call "small". That abstraction level comes at a price. ;-) But even if you don't want to use it like this, it might give you some ideas how to approach your task. CU -- Stefan Hundhammer <sh@suse.de> Penguin by conviction. YaST2 Development SuSE Linux AG Nuernberg, Germany
participants (2)
-
Charley
-
Stefan Hundhammer