summaryrefslogtreecommitdiff
path: root/src/xlib-wayland-test.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/xlib-wayland-test.c')
-rw-r--r--src/xlib-wayland-test.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/src/xlib-wayland-test.c b/src/xlib-wayland-test.c
new file mode 100644
index 0000000..0eb0452
--- /dev/null
+++ b/src/xlib-wayland-test.c
@@ -0,0 +1,28 @@
+#include <stdlib.h>
+#include <stdio.h>
+
+#include "Xlib-wayland.h"
+
+int main(int argc, char *argv[])
+{
+ Display *display;
+ Window win;
+ XID root = 1; /* FIXME */
+
+ display = XOpenDisplay(NULL);
+ printf("opened display %p\n", display);
+ win = XCreateWindow(display, root,
+ 100, 100, 200, 200, 0, 24,
+ InputOutput, NULL, 0, NULL);
+
+ printf("created window %d\n", win);
+
+ XMapWindow(display, win);
+
+ while (1)
+ XNextEvent(display, NULL);
+
+ XCloseDisplay(display);
+
+ return 0;
+}