xcb_create_pixmap(3)
π xcb_create_pixmap β bestie, we're making a pixmap π
okay so. you're in the XCB part of the man pages (xcb_create_pixmap(3), she's from the XCB Requests collection, very demure) and you want to know how to conjure a pixmap out of thin air. sit down, grab a strawberry π, let's go.
β¨ NAME β¨
xcb_create_pixmap β Creates a pixmap π
β¨ SYNOPSIS β¨
#include <xcb/xproto.h>
πΈ Request function πΈ
xcb_void_cookie_t xcb_create_pixmap(xcb_connection_t *conn,
uint8_t depth, xcb_pixmap_t pid, xcb_drawable_t drawable,
uint16_t width, uint16_t height);
β¨ REQUEST ARGUMENTS β¨
connβ your XCB connection to X11, the whole vibe pipeline π«ΆdepthβTODOπ bestie the docs literally just say TODO, I cannot make it up for you, that would be lying and lying is not slaypidβ the ID you'll use to refer to your brand new pixmap later. you gotta make it withxcb_generate_idfirst, no freelancing πdrawableβ the drawable we're stealing the screen fromwidthβ how wide the new pixmap is gonna beheightβ and how tall. width and height, iconic duo, no notes
β¨ DESCRIPTION β¨
Creates a pixmap. periodt. β¨
but here's the lore: that pixmap can only be used on the same screen that drawable lives on, and only with drawables of the same depth. it's giving exclusive friend group, iykyk. no crossing screens, no mixing depths, the pixmap does not fraternize outside its lane π¦
β¨ RETURN VALUE β¨
Returns an xcb_void_cookie_t. so if errors happen, you don't get them handed to you here β you have to go handle them in the event loop, bestie. that's just the deal π
but wait, there's an option: if you'd rather handle errors directly with xcb_request_check, then use xcb_create_pixmap_checked instead. pick your fighter. see xcb-requests(3) for the full details π
β¨ ERRORS β¨
xcb_alloc_error_tβ the X server could not allocate the resources you asked for. (no memory? π that's the vibe it's giving)xcb_drawable_error_tβ the drawable you named (a Window or a Pixmap) does not exist. it's not there. it ghosted you πxcb_value_error_tβTODO: reasons?and honestly? the man page itself is asking. we don't know either π
β¨ SEE ALSO β¨
xcb-requests(3), xcb_generate_id(3) π
β¨ AUTHOR β¨
Generated from xproto.xml. Contact xcb@lists.freedesktop.org for corrections and improvements. (so if something's off, tell the humans, not me π)
lowkey important reminder: thatdepthfield beingTODOand thatxcb_value_error_treason beingTODO: reasons?are literally in the original docs. I'm not hiding anything from you, bestie, that's just how it was shipped. no cap.
okay that's the whole page, you ate that π go forth and create pixmaps responsibly. this was xcb_create_pixmap(3) from X Version 11, libxcb 1.17.0, mwah π
β¨π¦
π¦ where this page comes from
- alpine 3.22: libxcb-doc 1.17.0-r0 Β· MIT
- alpine 3.23: libxcb-doc 1.17.0-r1 Β· MIT
- alpine 3.24: libxcb-doc 1.17.0-r2 Β· MIT
- arch rolling: libxcb 1.17.0-1 Β· X11
- centos-stream 10: libxcb-devel 1.17.0-3.el10 Β· X11
- debian trixie: libxcb-doc 1.17.0-2
- fedora 43: libxcb-devel 1.17.0-6.fc43 Β· X11
- fedora 43: libxcb-devel 1.17.0-6.fc43 Β· X11
- fedora 44: libxcb-devel 1.17.0-7.fc44 Β· X11
- fedora 44: libxcb-devel 1.17.0-7.fc44 Β· X11
- nixpkgs unstable: libxcb 1.17.0
- opensuse-leap 16.0: libxcb-devel-doc 1.17.0-160000.2.2 Β· MIT
- ubuntu questing: libxcb-doc 1.17.0-2build1
- ubuntu resolute: libxcb-doc 1.17.0-2ubuntu1
- ubuntu stonking: libxcb-doc 1.17.0-2ubuntu1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms