SDL_HINT_VIDEO_X11_EXTERNAL_WINDOW_INPUT(3)

πŸ’… SDL_HINT_VIDEO_X11_EXTERNAL_WINDOW_INPUT(3) β€” SDL3 FUNCTIONS πŸŽ€

okay bestie, welcome to the SDL3 hint page, this one lives in the SDL3 functions section of the manual and it's genuinely so niche but so real.


✨ NAME ✨

SDL_HINT_VIDEO_X11_EXTERNAL_WINDOW_INPUT β€” a variable controlling whether SDL should call XSelectInput() to enable input events on X11 windows wrapped by SDL windows.

like. it's the little switch that decides whether SDL pokes X11 about input or just trusts that somebody else already did. πŸ’–


🌸 SYNOPSIS 🌸

#include <SDL3/SDL_hints.h>

#define SDL_HINT_VIDEO_X11_EXTERNAL_WINDOW_INPUT "SDL_VIDEO_X11_EXTERNAL_WINDOW_INPUT"

yes the macro is just the string, that's the whole vibe, no cap. ✨


πŸ¦‹ DESCRIPTION πŸ¦‹

so the variable can be set to the following values, and there are literally two of them, pick one:

  • "0" β€” don't call XSelectInput(), assuming the native window code has done it already. i.e. somebody else handled it, we're just gonna trust them πŸ™ˆ
  • "1" β€” call XSelectInput() to enable input events. (default)
πŸ’€ heads up bestie: this hint should be set before creating a window. setting it after is giving "too late, the window's already out here living its life" energy.

πŸ‘‘ AVAILABILITY πŸ‘‘

this hint is available since SDL 3.2.10. so if you're on something older, it's simply not giving, sorry babe. 😭


🫢 SEE ALSO 🫢

(nothing extra here, the original page keeps it minimal, and honestly, respect.)


Simple Directmedia Layer made this, it's SDL 3.4.18, and the page is SDL_HINT_VIDE..._WINDOW_INPUT(3) β€” that's the source, the version, and the date all wrapped up in one cute little sign-off. periodt. πŸ’…βœ¨πŸŽ€πŸ¦‹πŸŒΈπŸ”₯

πŸ“¦ where this page comes from