Xlib / X11 compatibility layer proposed for Haiku OS

 The developers of the open-source Haiku operating system , which continues to evolve from BeOS, have prepared an initial implementation of the Xlib compatibility layer, which allows you to run X11 applications in Haiku without using an X server. The layer is implemented through emulation of Xlib functions by translating calls to the high-level Haiku graphical API.As it stands, most of the commonly used Xlib APIs are provided by the layer, but some of the calls remain stubbed out for now. The layer allows you to compile and run applications based on the GTK library, but the quality of the layout of the elements in the windows still needs to be improved. The processing of input using the keyboard and mouse clicks has not yet been brought to a working view (only the processing of the mouse movement event has been added).Haiku's Qt library support has previously been implemented by creating a native Qt port that runs on top of the Haiku API. But for GTK support, the use of X11 emulation is considered the preferred option, since the internals of GTK are not so well abstracted and creating a separate GTK backend for Haiku will require significant resources. As a way out, the possibility of creating an X11 server port for Haiku was considered, but this approach was deemed impractical in conditions where the X11 API can be implemented directly on top of the Haiku API. X11 was chosen as a long-term stable and unchanging protocol, while experiments with Wayland are still ongoing, it is required to create its own server implementation and not all necessary protocol extensions are finally approved.




When running through a layer of simpler applications on Tcl / Tk and wxWidgets, still unresolved problems are noted, but the appearance is already closer to normal:




Recall that the Haiku project was created in 2001 in response to the curtailment of the development of the BeOS OS and developed under the name OpenBeOS, but was renamed in 2004 due to claims related to the use of the BeOS trademark in the name. The system is directly based on BeOS 5 technologies and is aimed at binary compatibility with applications for this OS. The source code for most of the Haiku OS is distributed under the free MIT license , with the exception of some libraries, media codecs and components borrowed from other projects.

The system is focused on personal computers, uses its own kernel, built on the basis of a hybrid architecture, optimized for high responsiveness to user actions and efficient execution of multithreaded applications. OpenBFS is used as a file system, which supports extended file attributes, journaling, 64-bit pointers, support for storing meta tags (for each file, you can save attributes in the form key = value, which makes the file system look like a database) and special indexes to speed up the selection on them. "B + tree" trees are used to organize the directory structure. From the BeOS code to Haiku, the Tracker file manager and the Deskbar are included, the sources of which were opened after the discontinuation of BeOS development.

https://github.com/waddlesplash/xlibe/tree/master/xlib