GUI/TUI linux库 [英] GUI/TUI linux library

查看:425
本文介绍了GUI/TUI linux库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有可以从同一来源构建文本用户界面(ncurses)和图形用户界面(GTK?QT?)的UI库? 我知道debconf可以与各种前端一起使用,我想构建类似但可编程的东西.

解决方案

使用一个代码库为YaST独立性提供ncurses,gtk和qt支持的库提供了您所需要的东西,并且它与YaST本身没有联系. /p>

实际上libyui仅需要标准C ++库和phtreads(IIRC). UI插件当然需要相应的库(Qt,ncurses). YaST通过一组YCP绑定使用libyui,这些绑定在libyui的顶部导出类似API的YCP.

该库有点低级(在事件循环下面一层),我的同事KlausKämpf前段时间在

还用Google搜索来自YCP的Yas独立性",从AndreasJäger查找有关该主题的博客条目.

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 used with various frontends, I would like to build something similar but programmable.

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.

这篇关于GUI/TUI linux库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆