compat.x11
#includeXlib runtime library and public headers built from upstream sources
#include <X11/Xlib.h>
mcpp add compat.x11@1.8.13
Usage
From this repository's own test project — built and run by CI, not written for the website.
#ifdef __linux__
#include <X11/Xlib.h>
#include <X11/keysym.h>
int main() {
const KeySym escape = XStringToKeysym("Escape");
return X_PROTOCOL == 11 && escape == XK_Escape ? 0 : 1;
}
#else
int main() { return 0; }
#endif
tests/examples/gui-stack/tests/x11.cpp · project tests/examples/gui-stack
Build
- targets
X11 (shared)- language
c++23- C standard
c11- import std
- no
- include dirs
., include, include/X11, src, src/xcms, src/xkb, src/xlibi18n, modules/im/ximcp, modules/lc/def, modules/lc/gen, modules/lc/Utf8, modules/om/generic
Sources (11)
src/*.csrc/xcms/*.csrc/xkb/*.csrc/xlibi18n/*.c!src/xlibi18n/XlcDL.c!src/xlibi18n/XlcSL.cmodules/im/ximcp/*.cmodules/lc/def/*.cmodules/lc/gen/*.cmodules/lc/Utf8/*.cmodules/om/generic/*.c