xcb_alloc_color_cells(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_alloc_color_cells(3) πŸ’–

okay so bestie, welcome to the XCB Requests manual, page xcb_alloc_color_cells(3). grab a boba, we're allocating color cells today ✨


🌸 NAME 🌸

xcb_alloc_color_cells β€” and that's literally it, the original page has no description here, so like. the name is the name. no cap.


✨ SYNOPSIS ✨

first up, you gotta pull in the header:

#include <xcb/xproto.h>

πŸŽ€ Request function

xcb_alloc_color_cells_cookie_t
       xcb_alloc_color_cells(xcb_connection_t *conn, uint8_t contiguous,
       xcb_colormap_t cmap, uint16_t colors, uint16_t planes);

πŸ¦‹ Reply datastructure

typedef struct xcb_alloc_color_cells_reply_t {
    uint8_t  response_type;
    uint8_t  pad0;
    uint16_t sequence;
    uint32_t length;
    uint16_t pixels_len;
    uint16_t masks_len;
    uint8_t  pad1[20];
} xcb_alloc_color_cells_reply_t;

🫢 Reply function

xcb_alloc_color_cells_reply_t
       *xcb_alloc_color_cells_reply(xcb_connection_t *conn,
       xcb_alloc_color_cells_cookie_t cookie, xcb_generic_error_t **e);

πŸ’… Reply accessors

uint32_t *xcb_alloc_color_cells_pixels(const
       xcb_alloc_color_cells_request_t *reply);

int xcb_alloc_color_cells_pixels_length(const
       xcb_alloc_color_cells_reply_t *reply);

xcb_generic_iterator_t xcb_alloc_color_cells_pixels_end(const
       xcb_alloc_color_cells_reply_t *reply);

uint32_t *xcb_alloc_color_cells_masks(const
       xcb_alloc_color_cells_request_t *reply);

int xcb_alloc_color_cells_masks_length(const
       xcb_alloc_color_cells_reply_t *reply);

xcb_generic_iterator_t xcb_alloc_color_cells_masks_end(const
       xcb_alloc_color_cells_reply_t *reply);

πŸ”₯ REQUEST ARGUMENTS πŸ”₯

  • conn β€” your XCB connection to X11. the whole line to the server, basically. iconic.
  • contiguous β€” TODO: NOT YET DOCUMENTED. yeah bestie, they really left us on read with this one 😭
  • cmap β€” TODO: NOT YET DOCUMENTED. same energy, no info here πŸ™ˆ
  • colors β€” TODO: NOT YET DOCUMENTED. still nothing. the docs said "mystery" and dipped πŸ’€
  • planes β€” TODO: NOT YET DOCUMENTED. and that's the last one. four for four, the docs are mysterious fr fr.

πŸ‘‘ REPLY FIELDS πŸ‘‘

  • response_type β€” what kind of reply this is. in this case it's XCB_ALLOC_COLOR_CELLS. this field also lives 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 processed. like a little timestamp but for requests.
  • length β€” how long the reply is, in words. and a word is 4 bytes, so do your math πŸ’…
  • pixels_len β€” TODO: NOT YET DOCUMENTED. πŸ™ˆ
  • masks_len β€” TODO: NOT YET DOCUMENTED. 😭

🧚 DESCRIPTION 🧚

bestie… there is genuinely nothing here. the original page has a DESCRIPTION heading and then just. silence. no thoughts, head empty, literally nothing to report 🌸


🌈 RETURN VALUE 🌈

it hands you back an xcb_alloc_color_cells_cookie_t. cute, right? but plot twist: errors have to be handled when you call the reply function xcb_alloc_color_cells_reply.

and if you'd rather catch your errors in the event loop instead? use xcb_alloc_color_cells_unchecked. see xcb-requests(3) for the deets, iykyk 🫢


πŸ’€ ERRORS πŸ’€

this request does never generate any errors. not one. zero. clean sheet. slay ✨


⭐ SEE ALSO ⭐

…nothing listed. bestie, the well is dry. moving on πŸŽ€


πŸ’œ AUTHOR πŸ’œ

Generated from xproto.xml. Contact xcb@lists.freedesktop.org for corrections and improvements β€” so if you spot something sus, that's who you dm πŸ“§


and that's the whole page, bestie!! this was X Version 11, libxcb 1.17.0, page xcb_alloc_color_cells(3). periodt πŸ’…βœ¨πŸ¦‹