Arrange xcb bindings properly
This commit is contained in:
+6
-6
@@ -9,21 +9,21 @@ let spawn cmd =
|
||||
| _pid -> ()
|
||||
|
||||
let () =
|
||||
let conn = Xcb.Functions.connect () in
|
||||
let conn = Xcb.Connection.connect () in
|
||||
|
||||
print_endline "connected";
|
||||
print_endline "Connected to X";
|
||||
|
||||
Xcb.Functions.window_attribute_setup conn;
|
||||
Xcb.Utils.setup conn;
|
||||
|
||||
if Xcb.Functions.flush conn <= 0 then exit 1;
|
||||
if Xcb.Connection.flush conn <= 0 then exit 1;
|
||||
|
||||
spawn [| "kitty" |];
|
||||
|
||||
while true do
|
||||
if Xcb.Functions.flush conn <= 0 then exit 1;
|
||||
if Xcb.Connection.flush conn <= 0 then exit 1;
|
||||
Unix.sleepf 0.01
|
||||
done;
|
||||
|
||||
Xcb.Functions.disconnect conn;
|
||||
Xcb.Connection.disconnect conn;
|
||||
|
||||
print_endline "done"
|
||||
|
||||
Reference in New Issue
Block a user