xcb_input_grab_device(3)
π xcb_input_grab_device β the XCB Requests girlies' guide π
okay so bestie, we're in the xcb_input_grab_device(3) zone today, part of the XCB Requests family, and honestly? it's giving "grab that device" and we're obsessed. no cap.
β¨ NAME β¨
xcb_input_grab_device β bestie the docs literally left this one blank, it's just vibes and a dash. we move. π
πΈ SYNOPSIS πΈ
first up, the include, as always:
#include <xcb/xinput.h>
π Request function π
xcb_input_grab_device_cookie_t
xcb_input_grab_device(xcb_connection_t *conn,
xcb_window_t grab_window, xcb_timestamp_t time,
uint16_t num_classes, uint8_t this_device_mode,
uint8_t other_device_mode, uint8_t owner_events,
uint8_t device_id, const xcb_input_event_class_t *classes);
π¦ Reply datastructure π¦
typedef struct xcb_input_grab_device_reply_t {
uint8_t response_type;
uint8_t xi_reply_type;
uint16_t sequence;
uint32_t length;
uint8_t status;
uint8_t pad0[23];
} xcb_input_grab_device_reply_t;
β Reply function β
xcb_input_grab_device_reply_t
*xcb_input_grab_device_reply(xcb_connection_t *conn,
xcb_input_grab_device_cookie_t cookie, xcb_generic_error_t **e);
π REQUEST ARGUMENTS π
connβ your XCB connection to X11. the whole link-up, the main character of the connection-verse fr fr.grab_windowβ TODO: NOT YET DOCUMENTED. yeah. the manpage said nothing. we're all just sitting here. πtimeβ TODO: NOT YET DOCUMENTED. still nothing bestie, not a single crumb.num_classesβ TODO: NOT YET DOCUMENTED. the silence is loud.this_device_modeβ TODO: NOT YET DOCUMENTED. undoc'd and unbothered.other_device_modeβ TODO: NOT YET DOCUMENTED. also no thoughts, just a placeholder.owner_eventsβ TODO: NOT YET DOCUMENTED. we know nothing, and honestly that's iconic of the maintainers.device_idβ TODO: NOT YET DOCUMENTED. yeah, the one you'd most wanna know about. nope. πclassesβ TODO: NOT YET DOCUMENTED. same energy, same emptiness.
π REPLY FIELDS π
response_typeβ the type of this reply, and in this case it'sXCB_INPUT_GRAB_DEVICE. lowkey the most useful thing here: this field also lives in thexcb_generic_reply_t, so you can use it to tell your replies apart from each other. vibe check your replies, basically. β¨sequenceβ the sequence number of the last request that got processed by the X11 server. the receipts, if you will.lengthβ the length of the reply, counted in words. and btw a word here is4bytes, in case anyone was about to do math wrong. π§xi_reply_typeβ TODO: NOT YET DOCUMENTED. no crumbs. πstatusβ TODO: NOT YET DOCUMENTED. also blank, also tragic.
π«Ά DESCRIPTION π«Ά
...and that's it. that's the section. literally empty. the DESCRIPTION section has left the chat. π
π RETURN VALUE π
Returns an xcb_input_grab_device_cookie_t. slay. but listen β errors? you have to handle those yourself when you call the reply function xcb_input_grab_device_reply.
If you'd rather handle errors in the event loop instead (valid, honestly), use xcb_input_grab_device_unchecked. and for the full tea on how requests work, go read xcb-requests(3). iykyk.
π ERRORS π
This request does never generate any errors. periodt. zero errors, zero drama.
π₯ SEE ALSO π₯
...nothing. the SEE ALSO section is a ghost town. bestie. π
π AUTHOR π
Generated from xinput.xml. if you've got corrections and improvements, contact xcb@lists.freedesktop.org β they want your notes, fr fr.
and that's the whole page bestie!! this one shipped with X Version 11, libxcb 1.17.0, and that sweet xcb_input_grab_device(3) energy. mwah. go grab that device. πβ¨π¦π
π¦ 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