Commit 7f59b0aedcce9fc2e00b3db93c09a36693d13ce5

Thomas de Grivel 2023-11-13T19:53:11

wip

diff --git a/libc3/buf_parse.c b/libc3/buf_parse.c
index af65af5..acc1374 100644
--- a/libc3/buf_parse.c
+++ b/libc3/buf_parse.c
@@ -1961,6 +1961,15 @@ sw buf_parse_map_key (s_buf *buf, s_tag *dest)
     dest->data.str = str;
     goto ok;
   }
+  if ((r = buf_parse_sym_str(buf, &str)) < 0)
+    goto clean;
+  if (r > 0) {
+    result += r;
+    dest->type = TAG_SYM;
+    dest->data.sym = str_to_sym(&str);
+    str_clean(&str);
+    goto ok;
+  }
   if ((r = buf_parse_tag(buf, &tag)) <= 0)
     goto restore;
   if ((r = buf_parse_comments(buf)) < 0)
diff --git a/libc3/window/cairo/xcb/window_cairo_xcb.c b/libc3/window/cairo/xcb/window_cairo_xcb.c
index 80ea3bc..529207a 100644
--- a/libc3/window/cairo/xcb/window_cairo_xcb.c
+++ b/libc3/window/cairo/xcb/window_cairo_xcb.c
@@ -31,6 +31,7 @@ bool window_cairo_xcb_event (s_window_cairo *window,
   xcb_button_press_event_t     *event_button;
   xcb_configure_notify_event_t *event_config;
   xcb_key_press_event_t        *event_key;
+  xcb_motion_notify_event_t    *event_motion;
   switch (event->response_type & ~0x80) {
   case XCB_BUTTON_PRESS:
     event_button = (xcb_button_press_event_t *) event;
@@ -68,6 +69,10 @@ bool window_cairo_xcb_event (s_window_cairo *window,
       return false;
     }
     break;
+  case XCB_MOTION_NOTIFY:
+    event_motion = (xcb_motion_notify_event_t *) event;
+    if (! window->motion(window, event_motion->event_x,
+                         event_motion->event_y)
   default:
     printf("event type %d\n", event->response_type & ~0x80);
   }
@@ -98,6 +103,7 @@ bool window_cairo_xcb_run (s_window_cairo *window)
   uint32_t value_list[1] = {XCB_EVENT_MASK_BUTTON_PRESS |
                             XCB_EVENT_MASK_EXPOSURE |
                             XCB_EVENT_MASK_KEY_PRESS |
+                            XCB_EVENT_MASK_POINTER_MOTION |
                             XCB_EVENT_MASK_STRUCTURE_NOTIFY};
   xcb_create_window(conn, XCB_COPY_FROM_PARENT, xcb_window,
                     screen->root, window->x, window->y,