xcb_x_print_p..._printer_list(3)
π xcb_x_print_p..._printer_list(3) π
okay bestie, buckle up β this is a page from XCB Requests, and the whole vibe is X Print, the X11 printing extension. yes, printing. from X11. iconic of her honestly. π
β¨ NAME β¨
xcb_x_print_print_get_printer_list β and that's it. that's the whole description. the manpage literally left it blank, no cap. we're all just out here vibing with an empty tagline. π«Ά
πΈ SYNOPSIS πΈ
first things first, you gotta bring in the header:
#include <xcb/xprint.h>
π¦ Request function π¦
this is the one you actually call to ask for the printer list:
xcb_x_print_print_get_printer_list_cookie_t
xcb_x_print_print_get_printer_list(xcb_connection_t *conn,
uint32_t printerNameLen, uint32_t localeLen, const
xcb_x_print_string8_t *printer_name, const
xcb_x_print_string8_t *locale);
π¦ Reply datastructure π¦
here's the lil struct the server sends back, all laid out:
typedef struct xcb_x_print_print_get_printer_list_reply_t {
uint8_t response_type;
uint8_t pad0;
uint16_t sequence;
uint32_t length;
uint32_t listCount;
uint8_t pad1[20];
} xcb_x_print_print_get_printer_list_reply_t;
π¦ Reply function π¦
and this is how you go pick up that reply, bestie:
xcb_x_print_print_get_printer_list_reply_t
*xcb_x_print_print_get_printer_list_reply(xcb_connection_t *conn,
xcb_x_print_print_get_printer_list_cookie_t cookie,
xcb_generic_error_t **e);
π¦ Reply accessors π¦
the little helper functions that reach into the reply for you:
int xcb_x_print_print_get_printer_list_printers_length(const
xcb_x_print_print_get_printer_list_reply_t *reply);
xcb_x_print_printer_iterator_t
xcb_x_print_print_get_printer_list_printers_iterator(const
xcb_x_print_print_get_printer_list_reply_t *reply);
π REQUEST ARGUMENTS π
connβ the XCB connection to X11. your link to the whole server situation, the main character of every XCB call honestly.printerNameLenβ TODO: NOT YET DOCUMENTED. π nobody wrote it down bestie, we just don't know.localeLenβ TODO: NOT YET DOCUMENTED. also a mystery. the docs ghosted us fr fr.printer_nameβ TODO: NOT YET DOCUMENTED. πlocaleβ TODO: NOT YET DOCUMENTED. four for four, the whole argument list is un-documented and we respect the consistency lowkey.
π REPLY FIELDS π
response_typeβ the type of this reply, which in this case isXCB_X_PRINT_PRINT_GET_PRINTER_LIST. this same field also lives in thexcb_generic_reply_t, and it's how you tell your replies apart from each other when they're all showing up in your inbox at once. πsequenceβ the sequence number of the last request that got processed by the X11 server. it's giving receipt number.lengthβ how long the reply is, measured in words. and before you ask: a word is 4 bytes. β¨listCountβ TODO: NOT YET DOCUMENTED. π
β DESCRIPTION β
...okay so there is literally nothing here. the DESCRIPTION section is empty. the page said "I'm not gonna explain myself" and moved on. no notes, honestly. π
π RETURN VALUE π
this function hands you back an xcb_x_print_print_get_printer_list_cookie_t. cookies are the whole XCB thing β you get the cookie now, you cash it in later.
and that means: any errors? you have to deal with them when you call the reply function, xcb_x_print_print_get_printer_list_reply.
if you'd rather handle your errors in the event loop instead, use xcb_x_print_print_get_printer_list_unchecked β it skips the automatic error handling. the deets are in xcb-requests(3) if you want the full lore. π
π ERRORS π
good news bestie: this request never generates any errors. not one. zero. it's the chillest request at the function. β¨π¦
π SEE ALSO π
...yeah. this section is empty too. the page is just out here with no friends. we support her anyway. π«Ά
π AUTHOR π
Generated from xprint.xml. If you've got corrections or improvements, hit up xcb@lists.freedesktop.org β they'd love to hear from you. π§
and that's the whole page, babe. generated from xprint.xml, straight out of X Version 11, running libxcb 1.17.0 β so if you were wondering which version of this un-documented masterpiece you're reading, it's that one. periodt. π
β¨
π¦ 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