Commit Graph

9408 Commits

Author SHA1 Message Date
Enrico Weigelt, metux IT consult
79eaedbcc0 (!1654) Xnest: replace xnestRecolorCursor() by xcb_recolor_cursor()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
7cf927e8d3 (!1654) Xnest: replace XFreeCursor() by xcb_free_cursor()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
b529df0316 (!1654) Xnest: replace XStoreColors() by xcb_store_colors()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
ee7294afda (!1654) Xnest: replace XQueryColors() by xcb_query_colors()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
db89fa2d73 (!1654) Xnest: replace XSetWindowColormap() by xcb_change_window_attributes()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
23a925b261 (!1654) Xnest: replace XSetWMColormapWindows() by xcb_icccm_set_wm_colormap_windows_checked()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
f168791525 (!1654) Xnest: use XIDs directly, instead of Xlib's GC
Now that no Xlib drawing functions used anymore, we can finally switch over
to using GC XID's directly, instead of Xlib's GC struct.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
e4dde4e4f0 (!1654) Xnest: GC: set stipple filling via xcb_change_gc
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:57 +01:00
Enrico Weigelt, metux IT consult
e971675a7e (!1654) Xnest: replace XSetClipMask() by xcb_change_gc()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
7118972472 (!1654) Xnest: replace XSetClipRectangles() by xnset_set_clip_rectangles()
Use XCB for setting clip rectangles.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
08b2375d62 (!1654) Xnest: replace XSetDashes() by xnest_set_dashes()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
d71caf6b0c (!1654) Xnest: replace XChangeGC() by xcb_change_gc()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
68bf006556 (!1654) Xnest: replace XChangeKeyboardControl() by xcb_change_keyboard_control()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
c82daa2203 (!1654) Xnest: replace XChangePointerControl() by xcb_change_pointer_control
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
8b7d51ca86 (!1654) Xnest: replace XChangeWindowAttributes() by xcb_aux_change_window_attributes()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
75ee287896 (!1654) Xnest: replace XDrawImageString() by xcb_image_text_8()
Replace XDrawImageString() by xcb_image_text_8(), as well as their 16-bit
counterparts.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
d6c5149db3 (!1654) Xnest: replace XDrawString[8|16]() by xcb_poly_text_[8|16]()
Replace XDrawString8() by xcb_poly_text_8(), as well as XDrawString16()
by xcb_poly_text_16(). Some care needs to be taken to prepend the xTextElt
header before sending the request out.

GC operation handlers don't need to care about poly-strings or length
above 254, as this is already handled by their caller, doPolyText().

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
d73b5cf0b0 (!1654) Xnest: replace XFillRectangles() by xcb_poly_fill_rectangle()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
b00c3c4412 (!1654) Xnest: directly pass ClearArea request to upstream server
Instead of going through mi machinery, just pass the ClearArea
request to the upstream window.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
070d6fc7e2 (!1654) Xnest: replace XFillArcs() by xcb_poly_fill_arc()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
2165c94b09 (!1654) Xnest: replace XFillPolygon() by xcb_fill_poly()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
5ee023c783 (!1654) Xnest: replace XCopyPlane() by xcb_copy_plane()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
ea9cba16ba (!1654) Xnest: replace XCopyArea() by xcb_copy_area()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
cb787debb1 (!1654) Xnest: replace XDrawArcs() by xcb_poly_arc()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
779338fdf2 (!1654) Xnest: replace XDrawRectangles() by xcb_poly_rectangle()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
8d0cf26eff (!1654) Xnest: replace XDrawSegments() by xcb_poly_segment()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
844cb7913e (!1654) Xnest: replace XDrawLines() by xcb_poly_line()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
f49e0cf6a7 (!1654) Xnest: replace XDrawPoints() by xcb_poly_point()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
729c353aca (!1654) Xnest: replace XCreateColormap() / XFreeColormap() by xcb
Use xcb_create_colormap() and XFreeColormap() instead of XCreateColormap()
and XFreeColormap().

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
ad13d78571 (!1654) Xnest: use xcb instead of XShapeCombineRegion() and XShapeCombineMask()
Using xcb_shape_rectangles() and xcb_shape_mask() instead of Xlib's
XShapeCombineRegion() and XShapeCombineMask().

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
eaf59d152d (!1654) Xnest: use xcb_put_image() for PutImage requests
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
3109df1671 (!1654) Xnest: use xcb_put_image() for creating cursors
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
699cef88dc (!1654) Xnest: replace XCreatePixmapCursor() by xcb_create_cursor()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
ce0cf3f0b8 (!1654) Xnest: replace XConfigureWindow() calls by xcb_configure_window()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
33243832f1 (!1654) Xnest: use xcb for creating / destroying pixmaps
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
e6960e1cb1 (!1654) Xnest: replace XBell() by xcb_bell()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
8126a7fec3 (!1654) Xnest: use xcb for (un)mapping windows
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
2c72377eb1 (!1654) Xnest: replace XCreateWindow() by use xcb_create_window()
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
00e8dbf33d (!1654) Xnest: fetch root visual ID from screen data
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
27cf9f2743 (!1654) Xnest: fetch keycode min/max from setup data
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
b3ea348878 (!1654) Xnest: fetch image metrics from xcb connection setup data
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
747d70862f (!1654) Xnest: fetch default screen's root window from screen info
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
1780835812 (!1654) Xnest: add helper for retrieving GC XID on upstream connection
Upcoming patches will need to retieve GC's XIDs on the upstream connection.
Moving this out into separate .c file, in order to not creating more
dependencies on Xlib headers, which we wanna get rid of.

For now, looking at the Xlib GC structure, attached to our DDX GCs.
When all users of the Xlib GC have gone (ie. moved all consumers to xcb),
we'll create the GC via xcb directly, thus replacing the Xlib GC struct
by XID - the interface of this helper will remain the same.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
7731fd2ace (!1654) Xnest: fetch default colormap from xcb screen info
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
834d9fef60 (!1654) Xnest: fetch root window depth from screen info
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
6eeb73d1e2 (!1654) Xnest: fetch display size from xcb setup data
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
3ab241481b (!1654) Xnest: fetch BlackPixel and WhitePixel from xcb setup data
Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
1aa18793ec (!1654) Xnest: fetch xcb setup data
Fetching the setup data from xcb instead of Xlib, storing in our own struct,
holding all information needed for one particular upstream connection.
For now, there's only one, but future multi-upstream implementation will
change this to an array (and storing pointers to particular upstream in
various places).

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
938e34302c (!1654) Xnest: use XCB_EVENT_MASK_* defines
Use xcb's defines instead of Xlib's ones.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00
Enrico Weigelt, metux IT consult
0187586176 (!1654) Xnest: use XCB*_NONE instead of None
Use xcb's defines instead of Xlib's ones.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
2025-02-19 20:01:56 +01:00