C ++ main loop of abstraction

Since almost every GUI uses a main loop to execute code (which, for example, changes the user interface), is there a library to abstract the actual implementation? Like std::thread , it would be great to have a common interface no matter which GUI you use.

1 Bonus point for OpenSource and 2 for permissive license (BSD, MIT, ...).

+4
source share
2 answers

Zinc is a library that I used many years ago, so it has been around for quite some time (more than 10 years).

Zinc comes with full source code as an object-oriented independent platform of the C ++ platform and is used to implement graphical user interfaces (GUIs) for cross-platform applications. Zinc is a scalable and customizable, full-featured toolkit for creating event-driven GUI applications. Zinc is available for embedded and desktop platforms. Zinc for embedded platforms is available for real-time operating systems such as Wind River VxWorks. Zinc uses the look of its own platform for zinc objects.

+2
source

If you are looking for a fast general-purpose event loop, you can use libev http://software.schmorp.de/pkg/libev.html .

If you are instead looking for a set of shell functions that provide a consistent interface with event loops of different graphical interfaces (e.g., Gtk, Windows, Cocoa, etc.), you can watch wxWidgets http://www.wxwidgets.org / processes it (if so).

+2
source

Source: https://habr.com/ru/post/1434383/


All Articles