- root->root.xid, geom->width, geom->height, geom->depth);
+ root->root, geom->width, geom->height, geom->depth);
- rootwin.window = root->root;
- white = xcb_gcontext_new(c);
- black = xcb_gcontext_new(c);
+ rootwin = root->root;
+ white = xcb_generate_id(c);
+ black = xcb_generate_id(c);
pthread_create(&thr, 0, event_thread, 0);
pthread_create(&thr, 0, event_thread, 0);
windows[idx].width = 300;
line[0].x = xo = windows[idx].width / 2;
windows[idx].height = 300;
windows[idx].width = 300;
line[0].x = xo = windows[idx].width / 2;
windows[idx].height = 300;
values[1] = XCB_EVENT_MASK_BUTTON_RELEASE | XCB_EVENT_MASK_EXPOSURE;
values[2] = XCB_EVENT_MASK_BUTTON_PRESS;
values[1] = XCB_EVENT_MASK_BUTTON_RELEASE | XCB_EVENT_MASK_EXPOSURE;
values[2] = XCB_EVENT_MASK_BUTTON_PRESS;
- xcb_create_window(c, depth, windows[idx].w.window, root->root,
+ xcb_create_window(c, depth, windows[idx].w, root->root,
/* x */ 0, /* y */ 0,
windows[idx].width, windows[idx].height,
/* border */ 0, XCB_WINDOW_CLASS_INPUT_OUTPUT,
/* visual */ root->root_visual,
mask, values);
/* x */ 0, /* y */ 0,
windows[idx].width, windows[idx].height,
/* border */ 0, XCB_WINDOW_CLASS_INPUT_OUTPUT,
/* visual */ root->root_visual,
mask, values);
windows[idx].width, windows[idx].height);
xcb_poly_fill_rectangle(c, windows[idx].p, white, 1, &rect);
windows[idx].width, windows[idx].height);
xcb_poly_fill_rectangle(c, windows[idx].p, white, 1, &rect);