xcb_get_pointer_control(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_get_pointer_control β€” bestie edition πŸ’–

okay so we're doing xcb_get_pointer_control(3) today, and it lives in the XCB Requests section of the manual. it's literally the "hey X11 server, spill the tea about the pointer" request. pointer acceleration, threshold, all that. let's go πŸ¦‹


✨ NAME ✨

xcb_get_pointer_control β€” and bestie, the original manpage leaves this description completely blank. not a single word. it's giving mystery, it's giving enigmatic main character πŸ•΅οΈβ™€οΈπŸ’… so we're rolling with it.


🌸 SYNOPSIS 🌸

first things first, you gotta bring the header in, no cap:

#include <xcb/xproto.h>

πŸŽ€ Request function

xcb_get_pointer_control_cookie_t
       xcb_get_pointer_control(xcb_connection_t *conn,
ok so yes, the original really does just cut off there mid-sentence πŸ’€ i am NOT finishing it for them, that would be inventing facts and we don't do that here. iconic behaviour tbh.

πŸŽ€ Reply datastructure

typedef struct xcb_get_pointer_control_reply_t {
    uint8_t  response_type;
    uint8_t  pad0;
    uint16_t sequence;
    uint32_t length;
    uint16_t acceleration_numerator;
    uint16_t acceleration_denominator;
    uint16_t threshold;
    uint8_t  pad1[18];
} xcb_get_pointer_control_reply_t;

πŸŽ€ Reply function

xcb_get_pointer_control_reply_t
       *xcb_get_pointer_control_reply(xcb_connection_t *conn,
       xcb_get_pointer_control_cookie_t cookie,
       xcb_generic_error_t **e);

πŸ’œ REQUEST ARGUMENTS πŸ’œ

  • conn β€” the XCB connection to X11. that's it. that's the whole list. she's low-maintenance πŸ’–

🌈 REPLY FIELDS 🌈

  • response_type β€” the type of this reply, which in this case is XCB_GET_POINTER_CONTROL. this field is also chillin' in the xcb_generic_reply_t, so you can use it to tell your replies apart from each other. very "which one of y'all is this" energy πŸ‘‘
  • sequence β€” the sequence number of the last request the X11 server actually processed. the receipts, basically 🧾
  • length β€” how long the reply is, measured in words. and bestie, a word here is 4 bytes. remember that, it's on the test ✨
  • acceleration_numerator β€” TODO: NOT YET DOCUMENTED. yeah. the original literally says that. not me being lazy, that's just what it says πŸ™ˆ
  • acceleration_denominator β€” TODO: NOT YET DOCUMENTED. same vibe, same blankness πŸ’€
  • threshold β€” TODO: NOT YET DOCUMENTED. three for three, we love a mystery πŸŽ€

πŸ¦‹ DESCRIPTION πŸ¦‹

so... the original manpage has nothing under DESCRIPTION. like, zero. empty. a whole section and not one character of prose.

i'm not gonna make stuff up, because making up technical claims is not the vibe β€” so we're both just gonna sit here and appreciate the silence together 🫢✨


⭐ RETURN VALUE ⭐

she returns an xcb_get_pointer_control_cookie_t. and listen β€” errors have to be handled when you call the reply function xcb_get_pointer_control_reply.

if you'd rather handle your errors in the event loop instead, use xcb_get_pointer_control_unchecked. see xcb-requests(3) for the deets πŸ’…


πŸ”₯ ERRORS πŸ”₯

this request does never generate any errors. not one. she is unproblematic, she is drama-free, she is the moment πŸ‘‘πŸŒΈ


πŸ’« SEE ALSO πŸ’«

bestie. there is nothing here. the original lists no references. an empty SEE ALSO. we respect it, we move on πŸ•ŠοΈ


πŸ’– AUTHOR πŸ’–

generated from xproto.xml. contact xcb@lists.freedesktop.org for corrections and improvements πŸ“§


okay so that's the whole page!! this one shipped as X Version 11, libxcb 1.17.0, and the footer tag is xcb_get_pointer_control(3) πŸŽ€βœ¨ thanks for reading bestie, go forth and query that pointer control, ily, periodt πŸ’…πŸ¦‹πŸ’œ