xcb_set_clip_rectangles(3)

πŸ“¦
version 1.17.0 Β· 4 versions
, in alpine 3.22, alpine 3.23, alpine 3.24, arch rolling, centos-stream 10, debian trixie, fedora 43, fedora 44, nixpkgs unstable, opensuse-leap 16.0, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– xcb_set_clip_rectangles β€” bestie edition πŸ’–

okay so we're in the xcb_set_clip_rectangles(3) page, part of XCB Requests, and yes bestie this one is a whole mood. it sets the clip rectangles on a graphics context. that's the vibe. let's go πŸ¦‹


✨ NAME ✨

xcb_set_clip_rectangles β€” the request that tells your GC which rectangles are allowed to get painted on πŸ’…

(ngl the original NAME section is literally just the function name and then nothing, so. that's the tea. no cap.)


✨ SYNOPSIS ✨

first, you gotta pull in the header, obviously:

#include <xcb/xproto.h>

πŸŽ€ Request function πŸŽ€

here's the whole signature, character for character, don't @ me:

xcb_void_cookie_t xcb_set_clip_rectangles(xcb_connection_t *conn,
       uint8_t ordering, xcb_gcontext_t gc, int16_t clip_x_origin,
       int16_t clip_y_origin, uint32_t rectangles_len, const
       xcb_rectangle_t *rectangles);

look at that. iconic. she's giving function. πŸ”₯


✨ REQUEST ARGUMENTS ✨

kay so here's every single one of them, and I'm not skipping a single lil guy:

  • conn β€” the XCB connection to X11. that's your whole link to the server, your main character connection πŸ’–
  • ordering β€” it's one of the following values, and bestie I need you to know the docs are straight up not written yet for every single one of these, so I'm passing along the exact energy:
    • XCB_CLIP_ORDERING_UNSORTED β€” TODO: NOT YET DOCUMENTED.
    • XCB_CLIP_ORDERING_Y_SORTED β€” TODO: NOT YET DOCUMENTED.
    • XCB_CLIP_ORDERING_YX_SORTED β€” TODO: NOT YET DOCUMENTED.
    • XCB_CLIP_ORDERING_YX_BANDED β€” TODO: NOT YET DOCUMENTED.
    • TODO: NOT YET DOCUMENTED.

yeah there's a lil extra TODO floating there at the end. it's in the original, so it's here too. we don't erase history πŸ’€

  • gc β€” TODO: NOT YET DOCUMENTED.
  • clip_x_origin β€” TODO: NOT YET DOCUMENTED.
  • clip_y_origin β€” TODO: NOT YET DOCUMENTED.
  • rectangles_len β€” TODO: NOT YET DOCUMENTED.
  • rectangles β€” TODO: NOT YET DOCUMENTED.
fr fr the entire argument list is undocumented upstream. that's not me being lazy, that's literally what the page says. I'm just the messenger 🫢

✨ DESCRIPTION ✨

so. um. the DESCRIPTION section is empty. like, nothing. void. a blank space. the original page has the heading and then straight up nothing under it. and I'm not gonna invent lore, so: it's empty, bestie. we move. 🧚


✨ RETURN VALUE ✨

she returns an xcb_void_cookie_t. and because it's a void cookie, any errors (if there even are any) have to be handled over in the event loop, not right here at call time.

and if you'd rather handle errors directly with xcb_request_check instead? use xcb_set_clip_rectangles_checked for that. go check xcb-requests(3) for the details, iykyk ✨


✨ ERRORS ✨

good news bestie: this request does never generate any errors. we love a low-drama king πŸ‘‘


✨ SEE ALSO ✨

...the original SEE ALSO section is empty too. no references, no cross-links, nothing. a whole blank. πŸ’€


✨ AUTHOR ✨

Generated from xproto.xml. if you've got corrections and improvements, hit up xcb@lists.freedesktop.org β€” they're the ones you wanna talk to 🌸


okay that's the whole page!! go set those clip rectangles, you gorgeous thing πŸŒˆπŸ’œ

this has been xcb_set_clip_rectangles(3) from X Version 11, libxcb 1.17.0 πŸ’– β€” mwah, stan the XCB devs, periodt. πŸŽ€πŸ¦‹βœ¨