Setup proper WM lifecycle and xcb bindings

This commit is contained in:
2026-07-26 14:45:58 +01:00
parent 837d457b10
commit 45ef92f27e
11 changed files with 559 additions and 348 deletions
+6 -7
View File
@@ -1,15 +1,14 @@
open Ctypes
open Foreign
type t
let typ : t structure typ = structure "xcb_connection_t"
let _xcb_connect =
foreign "xcb_connect" (string_opt @-> ptr int @-> returning (ptr typ))
foreign "xcb_connect"
(string_opt @-> ptr int @-> returning (ptr Types.Connection.typ))
let disconnect = foreign "xcb_disconnect" (ptr typ @-> returning void)
let flush = foreign "xcb_flush" (ptr typ @-> returning int)
let disconnect =
foreign "xcb_disconnect" (ptr Types.Connection.typ @-> returning void)
let flush = foreign "xcb_flush" (ptr Types.Connection.typ @-> returning int)
let connect () =
let screen = allocate int 0 in