xcb_randr_add_output_mode(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_randr_add_output_mode β€” the XCB Requests manual, bestie edition ✨

okay so you're here because you want to add a mode to an output in RandR, and the manual page for it is... a little sparse. not me reading it. anyway, this is xcb_randr_add_output_mode(3) from the XCB Requests crew, and we're gonna walk through every single crumb of it together. no crumbs left behind. πŸ“


🌸 NAME 🌸

xcb_randr_add_output_mode β€” literally the function that adds an output mode. that's it. that's the name section. the original left it blank after the dash, and honestly? we respect the mystery. πŸ’€


πŸ¦‹ SYNOPSIS πŸ¦‹

first things first, you gotta pull in the header:

#include <xcb/randr.h>

✨ Request function ✨

here's the main character herself:

xcb_void_cookie_t xcb_randr_add_output_mode(xcb_connection_t *conn,
       xcb_randr_output_t output, xcb_randr_mode_t mode);

she returns an xcb_void_cookie_t and takes three args. slay. πŸ’–


πŸŽ€ REQUEST ARGUMENTS πŸŽ€

one bullet per argument, no gatekeeping:

  • conn β€” your XCB connection to X11. your link to the mothership, the little thread connecting you to the display server. hold her gently. 🫢
  • output β€” the original literally says TODO: NOT YET DOCUMENTED. so like... we don't know. ngl the manpage is keeping secrets from us. πŸ™ˆ
  • mode β€” same energy, bestie. TODO: NOT YET DOCUMENTED. the lore is unfinished. 😭
not me documenting a manpage that refuses to document itself. iconic behaviour honestly.

🌈 DESCRIPTION 🌈

okay so this section is... empty. nothing. a void. the original has the heading and then just vibes. the way that i cannot add a single technical claim here without inventing it β€” periodt. so we sit in the silence together. 🧚


πŸ’œ RETURN VALUE πŸ’œ

she returns an xcb_void_cookie_t. that's your little receipt for the request. πŸ’Œ

here's the important part though: errors (if any) have to be handled in the event loop. you don't get them handed to you directly, you gotta go find them.

but wait β€” if you'd rather handle errors directly with xcb_request_check instead, use xcb_randr_add_output_mode_checked. πŸ‘‘

and for the full deets, go read xcb-requests(3). iykyk.


πŸ”₯ ERRORS πŸ”₯

this request does never generate any errors.

like, at all. zero. none. a clean slate, a flawless queen. πŸ’…βœ¨


⭐ SEE ALSO ⭐

the original lists... nothing. no references, no cross-links, no little friends to visit. we love a lone wolf. 🐺 (well β€” except xcb-requests(3) up in RETURN VALUE, which you already met.)


πŸ‘‘ AUTHOR πŸ‘‘

Generated from randr.xml. if you spot something wrong and want to help make it better, contact xcb@lists.freedesktop.org for corrections and improvements. they're literally asking for your help, bestie. go be the change. 🌸


and that's the whole page!! thank you for coming to my ted talk. this was xcb_randr_add_output_mode(3) from X Version 11, shipped with libxcb 1.17.0. stay hydrated, read your cookies, and go handle those errors in the event loop. mwah πŸ’–