GUI/TUI linux library

前端 未结 8 1285
别那么骄傲
别那么骄傲 2020-12-30 14:01

Is there any UI library that can be to build both a text user interface (ncurses) and graphical user interface (GTK? QT?) from the same source? I know that debconf can be us

8条回答
  •  误落风尘
    2020-12-30 14:10

    The library that powers YaST independence to do ncurses, gtk and qt with one codebase provides what you are looking for, and it is not tied to YaST itself.

    Actually libyui only requires the standard C++ library and phtreads (IIRC). The UI plugins require of course the respective libraries (Qt, ncurses). YaST uses libyui via a set of YCP bindings that export a YCP like API on top of libyui.

    The library is a bit lowlevel (one layer below an event loop), my colleage Klaus Kämpf wrote about using it some time ago in his blog, including binding to scripting languages it using swig.

    The only part that is SUSE specific is the packaging, so you would need to package it yourself. Stackoverflow did not allow me to link more than once. The code of the library is linked from Klaus blog. Replace libyui for "qt" and "ncurses" for the plugin's code.

    Also google for "YaST Independence From YCP" to find a blog entry from Andreas Jäger on the subject.

提交回复
热议问题