libyui-ncurses
|
Public Member Functions | |
virtual void | setLanguage (const std::string &language, const std::string &encoding=std::string()) override |
virtual std::string | askForExistingDirectory (const std::string &startDir, const std::string &headline) override |
virtual std::string | askForExistingFile (const std::string &startWith, const std::string &filter, const std::string &headline) override |
virtual std::string | askForSaveFileName (const std::string &startWith, const std::string &filter, const std::string &headline) override |
virtual void | beep () override |
virtual void | redrawScreen () override |
virtual void | initConsoleKeyboard () override |
virtual void | setConsoleFont (const std::string &console_magic, const std::string &font, const std::string &screen_map, const std::string &unicode_map, const std::string &language) override |
virtual int | runInTerminal (const std::string &command) override |
virtual int | displayWidth () override |
virtual int | displayHeight () override |
virtual int | displayDepth () override |
virtual long | displayColors () override |
virtual int | defaultWidth () override |
virtual int | defaultHeight () override |
virtual bool | isTextMode () override |
virtual bool | hasImageSupport () override |
virtual bool | hasIconSupport () override |
virtual bool | hasAnimationSupport () override |
virtual bool | hasFullUtf8Support () override |
virtual bool | richTextSupportsTable () override |
virtual bool | leftHandedMouse () override |
virtual void | setApplicationTitle (const std::string &title) override |
virtual void | openUI () override |
virtual void | closeUI () override |
Protected Member Functions | |
NCApplication () | |
virtual | ~NCApplication () |
Friends | |
class | YNCursesUI |
|
protected |
Constructor.
Use YUI::app() to get the singleton for this class.
|
protectedvirtual |
Destructor.
|
overridevirtual |
Open a directory selection box and prompt the user for an existing directory.
'startDir' is the initial directory that is displayed.
'headline' is an explanatory text for the directory selection box. Graphical UIs may omit that if no window manager is running.
Returns the selected directory name or an empty std::string if the user canceled the operation.
Implemented from YApplication.
|
overridevirtual |
Open a file selection box and prompt the user for an existing file.
'startWith' is the initial directory or file.
'filter' is one or more blank-separated file patterns, e.g. "*.png *.jpg"
'headline' is an explanatory text for the file selection box. Graphical UIs may omit that if no window manager is running.
Returns the selected file name or an empty std::string if the user canceled the operation.
Implemented from YApplication.
|
overridevirtual |
Open a file selection box and prompt the user for a file to save data to. Automatically asks for confirmation if the user selects an existing file.
'startWith' is the initial directory or file.
'filter' is one or more blank-separated file patterns, e.g. "*.png *.jpg"
'headline' is an explanatory text for the file selection box. Graphical UIs may omit that if no window manager is running.
Returns the selected file name or an empty std::string if the user canceled the operation.
Implemented from YApplication.
|
overridevirtual |
Beep.
Reimplemented from YApplication.
|
overridevirtual |
Initialize the (text) console keyboard.
Reimplemented from YApplication.
|
overridevirtual |
To mix TUI (NCurses) with stdio, enclose the UI parts within openUI/closeUI
Reimplemented from YApplication.
|
overridevirtual |
Redraw the screen.
Reimplemented from YApplication.
|
overridevirtual |
Run a shell command (typically an interactive program using NCurses) in a terminal (window).
Here in the NCurses UI, this shuts down the NCurses lib, runs the command and then restores the status of the NCurses lib so that the next instance of the NCurses lib from the started command doesn't interfere with the NCurses UI's instance.
Reimplemented from YApplication.
|
overridevirtual |
Set the application title
Reimplemented from YApplication.
|
overridevirtual |
Set the (text) console font according to the current encoding etc. See the setfont(8) command and the console HowTo for details.
Reimplemented from YApplication.
Moving that code from YNCursesUI to this class turned out to be impossible (or at least a lot more work than it's worth) that I finally gave it up.
|
overridevirtual |
Set language and encoding for the locale environment ($LANG).
'language' is the ISO short code ("de_DE", "en_US", ...).
'encoding' an (optional) encoding ("utf8", ...) that will be appended if present.
Reimplemented from YApplication.