Search code examples
c++htmlcssuser-interfacewidget

How can web technology be used for a C++ application GUI?


Can web technologies be used for a desktop application written in a traditional language like C++? I'd guess that they can, though I've not been able to find any evidence of this. I understand Adobe Air can make desktop apps using Flash, but it uses web languages like php etc. What I'd like to do is to be able to build my GUI elements - edit boxes, sliders, menus and so on, using html/CSS - instead of native widgets - in an application that is otherwise built in the conventional way - using Visual Studio for example.

Does anyone know if this has been done, if there's any software that makes it easier, or if there are any objections to this approach?


Solution

  • Qt is moving in this direction, with CSS-like styling and a forthcoming "declarative" UI mechanism.

    In addition, you can drive your app with Javascript via QtScript.

    You could also use QtWebKit to provide an HTML based UI, it's possible to bridge between C++ code and Javascript too.