summaryrefslogtreecommitdiff
path: root/platform/linuxbsd
diff options
context:
space:
mode:
Diffstat (limited to 'platform/linuxbsd')
-rw-r--r--platform/linuxbsd/README.md2
-rw-r--r--platform/linuxbsd/SCsub10
-rw-r--r--platform/linuxbsd/crash_handler_linuxbsd.cpp106
-rw-r--r--platform/linuxbsd/crash_handler_linuxbsd.h58
-rw-r--r--platform/linuxbsd/dbus-so_wrap.c8
-rw-r--r--platform/linuxbsd/dbus-so_wrap.h6
-rw-r--r--platform/linuxbsd/detect.py141
-rw-r--r--platform/linuxbsd/export/export.cpp59
-rw-r--r--platform/linuxbsd/export/export.h58
-rw-r--r--platform/linuxbsd/export/export_plugin.cpp402
-rw-r--r--platform/linuxbsd/export/export_plugin.h103
-rw-r--r--platform/linuxbsd/fontconfig-so_wrap.c195
-rw-r--r--platform/linuxbsd/fontconfig-so_wrap.h74
-rw-r--r--platform/linuxbsd/freedesktop_portal_desktop.cpp58
-rw-r--r--platform/linuxbsd/freedesktop_portal_desktop.h58
-rw-r--r--platform/linuxbsd/freedesktop_screensaver.cpp60
-rw-r--r--platform/linuxbsd/freedesktop_screensaver.h58
-rw-r--r--platform/linuxbsd/godot_linuxbsd.cpp59
-rw-r--r--platform/linuxbsd/joypad_linux.cpp84
-rw-r--r--platform/linuxbsd/joypad_linux.h60
-rw-r--r--platform/linuxbsd/key_mapping_x11.cpp1997
-rw-r--r--platform/linuxbsd/libudev-so_wrap.c10
-rw-r--r--platform/linuxbsd/libudev-so_wrap.h10
-rw-r--r--platform/linuxbsd/logo.pngbin1679 -> 0 bytes
-rw-r--r--platform/linuxbsd/logo.svg1
-rw-r--r--platform/linuxbsd/os_linuxbsd.cpp496
-rw-r--r--platform/linuxbsd/os_linuxbsd.h82
-rw-r--r--platform/linuxbsd/platform_config.h60
-rw-r--r--platform/linuxbsd/run_icon.svg1
-rw-r--r--platform/linuxbsd/speechd-so_wrap.c39
-rw-r--r--platform/linuxbsd/speechd-so_wrap.h18
-rw-r--r--platform/linuxbsd/tts_linux.cpp69
-rw-r--r--platform/linuxbsd/tts_linux.h58
-rw-r--r--platform/linuxbsd/x11/SCsub30
-rw-r--r--platform/linuxbsd/x11/detect_prime_x11.cpp (renamed from platform/linuxbsd/detect_prime_x11.cpp)88
-rw-r--r--platform/linuxbsd/x11/detect_prime_x11.h (renamed from platform/linuxbsd/detect_prime_x11.h)66
-rw-r--r--platform/linuxbsd/x11/display_server_x11.cpp (renamed from platform/linuxbsd/display_server_x11.cpp)927
-rw-r--r--platform/linuxbsd/x11/display_server_x11.h (renamed from platform/linuxbsd/display_server_x11.h)127
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.c676
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.h258
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xext-so_wrap.c154
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xext-so_wrap.h72
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.c71
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.h38
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.c401
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.h158
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.c859
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.h322
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.c6664
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.h2439
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.c797
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.h302
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.c511
-rw-r--r--platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.h198
-rw-r--r--platform/linuxbsd/x11/gl_manager_x11.cpp (renamed from platform/linuxbsd/gl_manager_x11.cpp)129
-rw-r--r--platform/linuxbsd/x11/gl_manager_x11.h (renamed from platform/linuxbsd/gl_manager_x11.h)67
-rw-r--r--platform/linuxbsd/x11/key_mapping_x11.cpp1165
-rw-r--r--platform/linuxbsd/x11/key_mapping_x11.h (renamed from platform/linuxbsd/key_mapping_x11.h)64
-rw-r--r--platform/linuxbsd/x11/vulkan_context_x11.cpp (renamed from platform/linuxbsd/vulkan_context_x11.cpp)62
-rw-r--r--platform/linuxbsd/x11/vulkan_context_x11.h (renamed from platform/linuxbsd/vulkan_context_x11.h)62
60 files changed, 17895 insertions, 3312 deletions
diff --git a/platform/linuxbsd/README.md b/platform/linuxbsd/README.md
index efa8682062..c4f287cc6c 100644
--- a/platform/linuxbsd/README.md
+++ b/platform/linuxbsd/README.md
@@ -7,7 +7,7 @@ used by this platform.
## Documentation
-- [Compiling for Linux/*BSD](https://docs.godotengine.org/en/latest/development/compiling/compiling_for_linuxbsd.html)
+- [Compiling for Linux/*BSD](https://docs.godotengine.org/en/latest/contributing/development/compiling/compiling_for_linuxbsd.html)
- Instructions on building this platform port from source.
- [Exporting for Linux/*BSD](https://docs.godotengine.org/en/latest/tutorials/export/exporting_for_linux.html)
- Instructions on using the compiled export templates to export a project.
diff --git a/platform/linuxbsd/SCsub b/platform/linuxbsd/SCsub
index 91d45627b9..fcd739cdc9 100644
--- a/platform/linuxbsd/SCsub
+++ b/platform/linuxbsd/SCsub
@@ -14,15 +14,7 @@ common_linuxbsd = [
]
if env["x11"]:
- common_linuxbsd += [
- "gl_manager_x11.cpp",
- "detect_prime_x11.cpp",
- "display_server_x11.cpp",
- "key_mapping_x11.cpp",
- ]
-
- if env["vulkan"]:
- common_linuxbsd.append("vulkan_context_x11.cpp")
+ common_linuxbsd += SConscript("x11/SCsub")
if env["speechd"]:
common_linuxbsd.append(["speechd-so_wrap.c", "tts_linux.cpp"])
diff --git a/platform/linuxbsd/crash_handler_linuxbsd.cpp b/platform/linuxbsd/crash_handler_linuxbsd.cpp
index 33da094860..3a245460b4 100644
--- a/platform/linuxbsd/crash_handler_linuxbsd.cpp
+++ b/platform/linuxbsd/crash_handler_linuxbsd.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* crash_handler_linuxbsd.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* crash_handler_linuxbsd.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "crash_handler_linuxbsd.h"
@@ -44,6 +44,7 @@
#include <cxxabi.h>
#include <dlfcn.h>
#include <execinfo.h>
+#include <link.h>
#include <signal.h>
#include <stdlib.h>
@@ -79,7 +80,33 @@ static void handle_crash(int sig) {
}
print_error(vformat("Dumping the backtrace. %s", msg));
char **strings = backtrace_symbols(bt_buffer, size);
+ // PIE executable relocation, zero for non-PIE executables
+#ifdef __GLIBC__
+ // This is a glibc only thing apparently.
+ uintptr_t relocation = _r_debug.r_map->l_addr;
+#else
+ // Non glibc systems apparently don't give PIE relocation info.
+ uintptr_t relocation = 0;
+#endif //__GLIBC__
if (strings) {
+ List<String> args;
+ for (size_t i = 0; i < size; i++) {
+ char str[1024];
+ snprintf(str, 1024, "%p", (void *)((uintptr_t)bt_buffer[i] - relocation));
+ args.push_back(str);
+ }
+ args.push_back("-e");
+ args.push_back(_execpath);
+
+ // Try to get the file/line number using addr2line
+ int ret;
+ String output = "";
+ Error err = OS::get_singleton()->execute(String("addr2line"), args, &output, &ret);
+ Vector<String> addr2line_results;
+ if (err == OK) {
+ addr2line_results = output.substr(0, output.length() - 1).split("\n", false);
+ }
+
for (size_t i = 1; i < size; i++) {
char fname[1024];
Dl_info info;
@@ -89,7 +116,7 @@ static void handle_crash(int sig) {
// Try to demangle the function name to provide a more readable one
if (dladdr(bt_buffer[i], &info) && info.dli_sname) {
if (info.dli_sname[0] == '_') {
- int status;
+ int status = 0;
char *demangled = abi::__cxa_demangle(info.dli_sname, nullptr, nullptr, &status);
if (status == 0 && demangled) {
@@ -102,24 +129,7 @@ static void handle_crash(int sig) {
}
}
- List<String> args;
-
- char str[1024];
- snprintf(str, 1024, "%p", bt_buffer[i]);
- args.push_back(str);
- args.push_back("-e");
- args.push_back(_execpath);
-
- String output = "";
-
- // Try to get the file/line number using addr2line
- int ret;
- Error err = OS::get_singleton()->execute(String("addr2line"), args, &output, &ret);
- if (err == OK) {
- output = output.substr(0, output.length() - 1);
- }
-
- print_error(vformat("[%d] %s (%s)", (int64_t)i, fname, output));
+ print_error(vformat("[%d] %s (%s)", (int64_t)i, fname, err == OK ? addr2line_results[i] : ""));
}
free(strings);
diff --git a/platform/linuxbsd/crash_handler_linuxbsd.h b/platform/linuxbsd/crash_handler_linuxbsd.h
index 1b77352cca..684f62b249 100644
--- a/platform/linuxbsd/crash_handler_linuxbsd.h
+++ b/platform/linuxbsd/crash_handler_linuxbsd.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* crash_handler_linuxbsd.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* crash_handler_linuxbsd.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef CRASH_HANDLER_LINUXBSD_H
#define CRASH_HANDLER_LINUXBSD_H
diff --git a/platform/linuxbsd/dbus-so_wrap.c b/platform/linuxbsd/dbus-so_wrap.c
index 0876bc88b0..d03a9166a3 100644
--- a/platform/linuxbsd/dbus-so_wrap.c
+++ b/platform/linuxbsd/dbus-so_wrap.c
@@ -1,7 +1,7 @@
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by ./generate-wrapper.py 0.3 on 2022-07-29 07:23:21
-// flags: ./generate-wrapper.py --include /usr/include/dbus-1.0/dbus/dbus.h --sys-include <dbus/dbus.h> --soname libdbus-1.so --init-name dbus --output-header dbus-so_wrap.h --output-implementation dbus-so_wrap.c
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:26:35
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/dbus/dbus.h --sys-include "thirdparty/linuxbsd_headers/dbus/dbus.h" --soname libdbus-1.so.3 --init-name dbus --output-header ./platform/linuxbsd/dbus-so_wrap.h --output-implementation ./platform/linuxbsd/dbus-so_wrap.c
//
#include <stdint.h>
@@ -243,7 +243,7 @@
#define dbus_validate_utf8 dbus_validate_utf8_dylibloader_orig_dbus
#define dbus_threads_init dbus_threads_init_dylibloader_orig_dbus
#define dbus_threads_init_default dbus_threads_init_default_dylibloader_orig_dbus
-#include <dbus/dbus.h>
+#include "thirdparty/linuxbsd_headers/dbus/dbus.h"
#undef dbus_error_init
#undef dbus_error_free
#undef dbus_set_error
@@ -725,7 +725,7 @@ dbus_bool_t (*dbus_threads_init_default_dylibloader_wrapper_dbus)( void);
int initialize_dbus(int verbose) {
void *handle;
char *error;
- handle = dlopen("libdbus-1.so", RTLD_LAZY);
+ handle = dlopen("libdbus-1.so.3", RTLD_LAZY);
if (!handle) {
if (verbose) {
fprintf(stderr, "%s\n", dlerror());
diff --git a/platform/linuxbsd/dbus-so_wrap.h b/platform/linuxbsd/dbus-so_wrap.h
index 52e1dd300c..6981912a12 100644
--- a/platform/linuxbsd/dbus-so_wrap.h
+++ b/platform/linuxbsd/dbus-so_wrap.h
@@ -2,8 +2,8 @@
#define DYLIBLOAD_WRAPPER_DBUS
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by ./generate-wrapper.py 0.3 on 2022-07-29 07:23:21
-// flags: ./generate-wrapper.py --include /usr/include/dbus-1.0/dbus/dbus.h --sys-include <dbus/dbus.h> --soname libdbus-1.so --init-name dbus --output-header dbus-so_wrap.h --output-implementation dbus-so_wrap.c
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:26:35
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/dbus/dbus.h --sys-include "thirdparty/linuxbsd_headers/dbus/dbus.h" --soname libdbus-1.so.3 --init-name dbus --output-header ./platform/linuxbsd/dbus-so_wrap.h --output-implementation ./platform/linuxbsd/dbus-so_wrap.c
//
#include <stdint.h>
@@ -245,7 +245,7 @@
#define dbus_validate_utf8 dbus_validate_utf8_dylibloader_orig_dbus
#define dbus_threads_init dbus_threads_init_dylibloader_orig_dbus
#define dbus_threads_init_default dbus_threads_init_default_dylibloader_orig_dbus
-#include <dbus/dbus.h>
+#include "thirdparty/linuxbsd_headers/dbus/dbus.h"
#undef dbus_error_init
#undef dbus_error_free
#undef dbus_set_error
diff --git a/platform/linuxbsd/detect.py b/platform/linuxbsd/detect.py
index f5f7e65417..36e149f2b4 100644
--- a/platform/linuxbsd/detect.py
+++ b/platform/linuxbsd/detect.py
@@ -4,6 +4,11 @@ import sys
from methods import get_compiler_version, using_gcc
from platform_methods import detect_arch
+from typing import TYPE_CHECKING
+
+if TYPE_CHECKING:
+ from SCons import Environment
+
def is_active():
return True
@@ -31,7 +36,6 @@ def get_opts():
return [
EnumVariable("linker", "Linker program", "default", ("default", "bfd", "gold", "lld", "mold")),
BoolVariable("use_llvm", "Use the LLVM compiler", False),
- BoolVariable("use_thinlto", "Use ThinLTO (LLVM only, requires linker=lld, implies use_lto=yes)", False),
BoolVariable("use_static_cpp", "Link libgcc and libstdc++ statically for better portability", True),
BoolVariable("use_coverage", "Test Godot coverage", False),
BoolVariable("use_ubsan", "Use LLVM/GCC compiler undefined behavior sanitizer (UBSAN)", False),
@@ -39,14 +43,13 @@ def get_opts():
BoolVariable("use_lsan", "Use LLVM/GCC compiler leak sanitizer (LSAN)", False),
BoolVariable("use_tsan", "Use LLVM/GCC compiler thread sanitizer (TSAN)", False),
BoolVariable("use_msan", "Use LLVM compiler memory sanitizer (MSAN)", False),
- BoolVariable("pulseaudio", "Detect and use PulseAudio", True),
- BoolVariable("dbus", "Detect and use D-Bus to handle screensaver and portal desktop settings", True),
- BoolVariable("speechd", "Detect and use Speech Dispatcher for Text-to-Speech support", True),
- BoolVariable("fontconfig", "Detect and use fontconfig for system fonts support", True),
+ BoolVariable("alsa", "Use ALSA", True),
+ BoolVariable("pulseaudio", "Use PulseAudio", True),
+ BoolVariable("dbus", "Use D-Bus to handle screensaver and portal desktop settings", True),
+ BoolVariable("speechd", "Use Speech Dispatcher for Text-to-Speech support", True),
+ BoolVariable("fontconfig", "Use fontconfig for system fonts support", True),
BoolVariable("udev", "Use udev for gamepad connection callbacks", True),
BoolVariable("x11", "Enable X11 display", True),
- BoolVariable("debug_symbols", "Add debugging symbols to release/release_debug builds", True),
- BoolVariable("separate_debug_symbols", "Create a separate file containing debugging symbols", False),
BoolVariable("touch", "Enable touch events", True),
BoolVariable("execinfo", "Use libexecinfo on systems where glibc is not available", False),
]
@@ -58,7 +61,7 @@ def get_flags():
]
-def configure(env):
+def configure(env: "Environment"):
# Validate arch.
supported_arches = ["x86_32", "x86_64", "arm32", "arm64", "rv64", "ppc32", "ppc64"]
if env["arch"] not in supported_arches:
@@ -70,26 +73,9 @@ def configure(env):
## Build type
- if env["target"] == "release":
- if env["optimize"] == "speed": # optimize for speed (default)
- env.Prepend(CCFLAGS=["-O3"])
- elif env["optimize"] == "size": # optimize for size
- env.Prepend(CCFLAGS=["-Os"])
-
- if env["debug_symbols"]:
- env.Prepend(CCFLAGS=["-g2"])
-
- elif env["target"] == "release_debug":
- if env["optimize"] == "speed": # optimize for speed (default)
- env.Prepend(CCFLAGS=["-O2"])
- elif env["optimize"] == "size": # optimize for size
- env.Prepend(CCFLAGS=["-Os"])
-
- if env["debug_symbols"]:
- env.Prepend(CCFLAGS=["-g2"])
-
- elif env["target"] == "debug":
- env.Prepend(CCFLAGS=["-g3"])
+ if env.dev_build:
+ # This is needed for our crash handler to work properly.
+ # gdb works fine without it though, so maybe our crash handler could too.
env.Append(LINKFLAGS=["-rdynamic"])
# CPU architecture flags.
@@ -129,13 +115,6 @@ def configure(env):
else:
env.Append(LINKFLAGS=["-fuse-ld=%s" % env["linker"]])
- if env["use_thinlto"]:
- if not env["use_llvm"] or env["linker"] != "lld":
- print("ThinLTO is only compatible with LLVM and the LLD linker, use `use_llvm=yes linker=lld`.")
- sys.exit(255)
- else:
- env["use_lto"] = True # ThinLTO implies LTO
-
if env["use_coverage"]:
env.Append(CCFLAGS=["-ftest-coverage", "-fprofile-arcs"])
env.Append(LINKFLAGS=["-ftest-coverage", "-fprofile-arcs"])
@@ -178,8 +157,16 @@ def configure(env):
env.Append(CCFLAGS=["-fsanitize-recover=memory"])
env.Append(LINKFLAGS=["-fsanitize=memory"])
- if env["use_lto"]:
- if env["use_thinlto"]:
+ # LTO
+
+ if env["lto"] == "auto": # Full LTO for production.
+ env["lto"] = "full"
+
+ if env["lto"] != "none":
+ if env["lto"] == "thin":
+ if not env["use_llvm"]:
+ print("ThinLTO is only compatible with LLVM, use `use_llvm=yes` or `lto=full`.")
+ sys.exit(255)
env.Append(CCFLAGS=["-flto=thin"])
env.Append(LINKFLAGS=["-flto=thin"])
elif not env["use_llvm"] and env.GetOption("num_jobs") > 1:
@@ -197,15 +184,6 @@ def configure(env):
## Dependencies
- if env["x11"]:
- env.ParseConfig("pkg-config x11 --cflags --libs")
- env.ParseConfig("pkg-config xcursor --cflags --libs")
- env.ParseConfig("pkg-config xinerama --cflags --libs")
- env.ParseConfig("pkg-config xext --cflags --libs")
- env.ParseConfig("pkg-config xrandr --cflags --libs")
- env.ParseConfig("pkg-config xrender --cflags --libs")
- env.ParseConfig("pkg-config xi --cflags --libs")
-
if env["touch"]:
env.Append(CPPDEFINES=["TOUCH_ENABLED"])
@@ -284,7 +262,7 @@ def configure(env):
env.Append(LIBS=["miniupnpc"])
# On Linux wchar_t should be 32-bits
- # 16-bit library shouldn't be required due to compiler optimisations
+ # 16-bit library shouldn't be required due to compiler optimizations
if not env["builtin_pcre2"]:
env.ParseConfig("pkg-config libpcre2-32 --cflags --libs")
@@ -295,53 +273,24 @@ def configure(env):
## Flags
if env["fontconfig"]:
- if os.system("pkg-config --exists fontconfig") == 0: # 0 means found
- env.Append(CPPDEFINES=["FONTCONFIG_ENABLED"])
- env.ParseConfig("pkg-config fontconfig --cflags") # Only cflags, we dlopen the library.
- else:
- env["fontconfig"] = False
- print("Warning: fontconfig libraries not found. Disabling the system fonts support.")
+ env.Append(CPPDEFINES=["FONTCONFIG_ENABLED"])
- if os.system("pkg-config --exists alsa") == 0: # 0 means found
- env["alsa"] = True
+ if env["alsa"]:
env.Append(CPPDEFINES=["ALSA_ENABLED", "ALSAMIDI_ENABLED"])
- env.ParseConfig("pkg-config alsa --cflags") # Only cflags, we dlopen the library.
- else:
- print("Warning: ALSA libraries not found. Disabling the ALSA audio driver.")
if env["pulseaudio"]:
- if os.system("pkg-config --exists libpulse") == 0: # 0 means found
- env.Append(CPPDEFINES=["PULSEAUDIO_ENABLED"])
- env.ParseConfig("pkg-config libpulse --cflags") # Only cflags, we dlopen the library.
- else:
- env["pulseaudio"] = False
- print("Warning: PulseAudio development libraries not found. Disabling the PulseAudio audio driver.")
+ env.Append(CPPDEFINES=["PULSEAUDIO_ENABLED", "_REENTRANT"])
if env["dbus"]:
- if os.system("pkg-config --exists dbus-1") == 0: # 0 means found
- env.Append(CPPDEFINES=["DBUS_ENABLED"])
- env.ParseConfig("pkg-config dbus-1 --cflags") # Only cflags, we dlopen the library.
- else:
- env["dbus"] = False
- print("Warning: D-Bus development libraries not found. Disabling screensaver prevention.")
+ env.Append(CPPDEFINES=["DBUS_ENABLED"])
if env["speechd"]:
- if os.system("pkg-config --exists speech-dispatcher") == 0: # 0 means found
- env.Append(CPPDEFINES=["SPEECHD_ENABLED"])
- env.ParseConfig("pkg-config speech-dispatcher --cflags") # Only cflags, we dlopen the library.
- else:
- env["speechd"] = False
- print("Warning: Speech Dispatcher development libraries not found. Disabling Text-to-Speech support.")
+ env.Append(CPPDEFINES=["SPEECHD_ENABLED"])
if platform.system() == "Linux":
env.Append(CPPDEFINES=["JOYDEV_ENABLED"])
if env["udev"]:
- if os.system("pkg-config --exists libudev") == 0: # 0 means found
- env.Append(CPPDEFINES=["UDEV_ENABLED"])
- env.ParseConfig("pkg-config libudev --cflags") # Only cflags, we dlopen the library.
- else:
- env["udev"] = False
- print("Warning: libudev development libraries not found. Disabling controller hotplugging support.")
+ env.Append(CPPDEFINES=["UDEV_ENABLED"])
else:
env["udev"] = False # Linux specific
@@ -349,17 +298,19 @@ def configure(env):
if not env["builtin_zlib"]:
env.ParseConfig("pkg-config zlib --cflags --libs")
- env.Prepend(CPPPATH=["#platform/linuxbsd"])
+ env.Prepend(CPPPATH=["#platform/linuxbsd", "#thirdparty/linuxbsd_headers"])
+
+ env.Append(
+ CPPDEFINES=[
+ "LINUXBSD_ENABLED",
+ "UNIX_ENABLED",
+ ("_FILE_OFFSET_BITS", 64),
+ ]
+ )
if env["x11"]:
- if not env["vulkan"]:
- print("Error: X11 support requires vulkan=yes")
- env.Exit(255)
env.Append(CPPDEFINES=["X11_ENABLED"])
- env.Append(CPPDEFINES=["UNIX_ENABLED"])
- env.Append(CPPDEFINES=[("_FILE_OFFSET_BITS", 64)])
-
if env["vulkan"]:
env.Append(CPPDEFINES=["VULKAN_ENABLED"])
if not env["use_volk"]:
@@ -370,20 +321,22 @@ def configure(env):
if env["opengl3"]:
env.Append(CPPDEFINES=["GLES3_ENABLED"])
- env.ParseConfig("pkg-config gl --cflags --libs")
env.Append(LIBS=["pthread"])
if platform.system() == "Linux":
env.Append(LIBS=["dl"])
- if platform.system().find("BSD") >= 0:
+ if not env["execinfo"] and platform.libc_ver()[0] != "glibc":
+ # The default crash handler depends on glibc, so if the host uses
+ # a different libc (BSD libc, musl), fall back to libexecinfo.
+ print("Note: Using `execinfo=yes` for the crash handler as required on platforms where glibc is missing.")
env["execinfo"] = True
if env["execinfo"]:
env.Append(LIBS=["execinfo"])
- if not env["tools"]:
+ if not env.editor_build:
import subprocess
import re
@@ -414,9 +367,9 @@ def configure(env):
# Link those statically for portability
if env["use_static_cpp"]:
env.Append(LINKFLAGS=["-static-libgcc", "-static-libstdc++"])
- if env["use_llvm"]:
+ if env["use_llvm"] and platform.system() != "FreeBSD":
env["LINKCOM"] = env["LINKCOM"] + " -l:libatomic.a"
else:
- if env["use_llvm"]:
+ if env["use_llvm"] and platform.system() != "FreeBSD":
env.Append(LIBS=["atomic"])
diff --git a/platform/linuxbsd/export/export.cpp b/platform/linuxbsd/export/export.cpp
index 990351d13f..2c5a945b6c 100644
--- a/platform/linuxbsd/export/export.cpp
+++ b/platform/linuxbsd/export/export.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* export.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* export.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "export.h"
@@ -36,7 +36,6 @@
void register_linuxbsd_exporter() {
Ref<EditorExportPlatformLinuxBSD> platform;
platform.instantiate();
- platform->set_logo(ImageTexture::create_from_image(memnew(Image(_linuxbsd_logo))));
platform->set_name("Linux/X11");
platform->set_os_name("Linux");
platform->set_chmod_flags(0755);
diff --git a/platform/linuxbsd/export/export.h b/platform/linuxbsd/export/export.h
index f06d781da6..a2d70a73e3 100644
--- a/platform/linuxbsd/export/export.h
+++ b/platform/linuxbsd/export/export.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* export.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* export.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef LINUXBSD_EXPORT_H
#define LINUXBSD_EXPORT_H
diff --git a/platform/linuxbsd/export/export_plugin.cpp b/platform/linuxbsd/export/export_plugin.cpp
index 4d45d3ba12..c900cad007 100644
--- a/platform/linuxbsd/export/export_plugin.cpp
+++ b/platform/linuxbsd/export/export_plugin.cpp
@@ -1,37 +1,46 @@
-/*************************************************************************/
-/* export_plugin.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* export_plugin.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "export_plugin.h"
#include "core/config/project_settings.h"
#include "editor/editor_node.h"
+#include "editor/editor_paths.h"
+#include "editor/editor_scale.h"
+#include "platform/linuxbsd/logo_svg.gen.h"
+#include "platform/linuxbsd/run_icon_svg.gen.h"
+
+#include "modules/modules_enabled.gen.h" // For svg.
+#ifdef MODULE_SVG_ENABLED
+#include "modules/svg/image_loader_svg.h"
+#endif
Error EditorExportPlatformLinuxBSD::_export_debug_script(const Ref<EditorExportPreset> &p_preset, const String &p_app_name, const String &p_pkg_name, const String &p_path) {
Ref<FileAccess> f = FileAccess::open(p_path, FileAccess::WRITE);
@@ -49,26 +58,47 @@ Error EditorExportPlatformLinuxBSD::_export_debug_script(const Ref<EditorExportP
}
Error EditorExportPlatformLinuxBSD::export_project(const Ref<EditorExportPreset> &p_preset, bool p_debug, const String &p_path, int p_flags) {
- Error err = EditorExportPlatformPC::export_project(p_preset, p_debug, p_path, p_flags);
+ bool export_as_zip = p_path.ends_with("zip");
- if (err != OK) {
- return err;
+ String pkg_name;
+ if (String(GLOBAL_GET("application/config/name")) != "") {
+ pkg_name = String(GLOBAL_GET("application/config/name"));
+ } else {
+ pkg_name = "Unnamed";
}
- String app_name;
- if (String(ProjectSettings::get_singleton()->get("application/config/name")) != "") {
- app_name = String(ProjectSettings::get_singleton()->get("application/config/name"));
- } else {
- app_name = "Unnamed";
+ pkg_name = OS::get_singleton()->get_safe_dir_name(pkg_name);
+
+ // Setup temp folder.
+ String path = p_path;
+ String tmp_dir_path = EditorPaths::get_singleton()->get_cache_dir().path_join(pkg_name);
+
+ Ref<DirAccess> tmp_app_dir = DirAccess::create_for_path(tmp_dir_path);
+ if (export_as_zip) {
+ if (tmp_app_dir.is_null()) {
+ return ERR_CANT_CREATE;
+ }
+ if (DirAccess::exists(tmp_dir_path)) {
+ if (tmp_app_dir->change_dir(tmp_dir_path) == OK) {
+ tmp_app_dir->erase_contents_recursive();
+ }
+ }
+ tmp_app_dir->make_dir_recursive(tmp_dir_path);
+ path = tmp_dir_path.path_join(p_path.get_file().get_basename());
+ }
+
+ // Export project.
+ Error err = EditorExportPlatformPC::export_project(p_preset, p_debug, path, p_flags);
+ if (err != OK) {
+ return err;
}
- app_name = OS::get_singleton()->get_safe_dir_name(app_name);
// Save console script.
if (err == OK) {
int con_scr = p_preset->get("debug/export_console_script");
if ((con_scr == 1 && p_debug) || (con_scr == 2)) {
- String scr_path = p_path.get_basename() + ".sh";
- err = _export_debug_script(p_preset, app_name, p_path.get_file(), scr_path);
+ String scr_path = path.get_basename() + ".sh";
+ err = _export_debug_script(p_preset, pkg_name, path.get_file(), scr_path);
FileAccess::set_unix_permissions(scr_path, 0755);
if (err != OK) {
add_message(EXPORT_MESSAGE_ERROR, TTR("Debug Script Export"), TTR("Could not create console script."));
@@ -76,6 +106,27 @@ Error EditorExportPlatformLinuxBSD::export_project(const Ref<EditorExportPreset>
}
}
+ // ZIP project.
+ if (export_as_zip) {
+ if (FileAccess::exists(p_path)) {
+ OS::get_singleton()->move_to_trash(p_path);
+ }
+
+ Ref<FileAccess> io_fa_dst;
+ zlib_filefunc_def io_dst = zipio_create_io(&io_fa_dst);
+ zipFile zip = zipOpen2(p_path.utf8().get_data(), APPEND_STATUS_CREATE, nullptr, &io_dst);
+
+ zip_folder_recursive(zip, tmp_dir_path, "", pkg_name);
+
+ zipClose(zip, nullptr);
+
+ if (tmp_app_dir->change_dir(tmp_dir_path) == OK) {
+ tmp_app_dir->erase_contents_recursive();
+ tmp_app_dir->change_dir("..");
+ tmp_app_dir->remove(pkg_name);
+ }
+ }
+
return err;
}
@@ -86,12 +137,51 @@ String EditorExportPlatformLinuxBSD::get_template_file_name(const String &p_targ
List<String> EditorExportPlatformLinuxBSD::get_binary_extensions(const Ref<EditorExportPreset> &p_preset) const {
List<String> list;
list.push_back(p_preset->get("binary_format/architecture"));
+ list.push_back("zip");
+
return list;
}
void EditorExportPlatformLinuxBSD::get_export_options(List<ExportOption> *r_options) {
EditorExportPlatformPC::get_export_options(r_options);
+
r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "binary_format/architecture", PROPERTY_HINT_ENUM, "x86_64,x86_32,arm64,arm32,rv64,ppc64,ppc32"), "x86_64"));
+
+ String run_script = "#!/usr/bin/env bash\n"
+ "export DISPLAY=:0\n"
+ "unzip -o -q \"{temp_dir}/{archive_name}\" -d \"{temp_dir}\"\n"
+ "\"{temp_dir}/{exe_name}\" {cmd_args}";
+
+ String cleanup_script = "#!/usr/bin/env bash\n"
+ "kill $(pgrep -x -f \"{temp_dir}/{exe_name} {cmd_args}\")\n"
+ "rm -rf \"{temp_dir}\"";
+
+ r_options->push_back(ExportOption(PropertyInfo(Variant::BOOL, "ssh_remote_deploy/enabled"), false));
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/host"), "user@host_ip"));
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/port"), "22"));
+
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_ssh", PROPERTY_HINT_MULTILINE_TEXT), ""));
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/extra_args_scp", PROPERTY_HINT_MULTILINE_TEXT), ""));
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/run_script", PROPERTY_HINT_MULTILINE_TEXT), run_script));
+ r_options->push_back(ExportOption(PropertyInfo(Variant::STRING, "ssh_remote_deploy/cleanup_script", PROPERTY_HINT_MULTILINE_TEXT), cleanup_script));
+}
+
+bool EditorExportPlatformLinuxBSD::is_elf(const String &p_path) const {
+ Ref<FileAccess> fb = FileAccess::open(p_path, FileAccess::READ);
+ ERR_FAIL_COND_V_MSG(fb.is_null(), false, vformat("Can't open file: \"%s\".", p_path));
+ uint32_t magic = fb->get_32();
+ return (magic == 0x464c457f);
+}
+
+bool EditorExportPlatformLinuxBSD::is_shebang(const String &p_path) const {
+ Ref<FileAccess> fb = FileAccess::open(p_path, FileAccess::READ);
+ ERR_FAIL_COND_V_MSG(fb.is_null(), false, vformat("Can't open file: \"%s\".", p_path));
+ uint16_t magic = fb->get_16();
+ return (magic == 0x2123);
+}
+
+bool EditorExportPlatformLinuxBSD::is_executable(const String &p_path) const {
+ return is_elf(p_path) || is_shebang(p_path);
}
Error EditorExportPlatformLinuxBSD::fixup_embedded_pck(const String &p_path, int64_t p_embedded_start, int64_t p_embedded_size) {
@@ -200,3 +290,235 @@ Error EditorExportPlatformLinuxBSD::fixup_embedded_pck(const String &p_path, int
}
return OK;
}
+
+Ref<Texture2D> EditorExportPlatformLinuxBSD::get_run_icon() const {
+ return run_icon;
+}
+
+bool EditorExportPlatformLinuxBSD::poll_export() {
+ Ref<EditorExportPreset> preset;
+
+ for (int i = 0; i < EditorExport::get_singleton()->get_export_preset_count(); i++) {
+ Ref<EditorExportPreset> ep = EditorExport::get_singleton()->get_export_preset(i);
+ if (ep->is_runnable() && ep->get_platform() == this) {
+ preset = ep;
+ break;
+ }
+ }
+
+ int prev = menu_options;
+ menu_options = (preset.is_valid() && preset->get("ssh_remote_deploy/enabled").operator bool());
+ if (ssh_pid != 0 || !cleanup_commands.is_empty()) {
+ if (menu_options == 0) {
+ cleanup();
+ } else {
+ menu_options += 1;
+ }
+ }
+ return menu_options != prev;
+}
+
+Ref<ImageTexture> EditorExportPlatformLinuxBSD::get_option_icon(int p_index) const {
+ return p_index == 1 ? stop_icon : EditorExportPlatform::get_option_icon(p_index);
+}
+
+int EditorExportPlatformLinuxBSD::get_options_count() const {
+ return menu_options;
+}
+
+String EditorExportPlatformLinuxBSD::get_option_label(int p_index) const {
+ return (p_index) ? TTR("Stop and uninstall") : TTR("Run on remote Linux/BSD system");
+}
+
+String EditorExportPlatformLinuxBSD::get_option_tooltip(int p_index) const {
+ return (p_index) ? TTR("Stop and uninstall running project from the remote system") : TTR("Run exported project on remote Linux/BSD system");
+}
+
+void EditorExportPlatformLinuxBSD::cleanup() {
+ if (ssh_pid != 0 && OS::get_singleton()->is_process_running(ssh_pid)) {
+ print_line("Terminating connection...");
+ OS::get_singleton()->kill(ssh_pid);
+ OS::get_singleton()->delay_usec(1000);
+ }
+
+ if (!cleanup_commands.is_empty()) {
+ print_line("Stopping and deleting previous version...");
+ for (const SSHCleanupCommand &cmd : cleanup_commands) {
+ if (cmd.wait) {
+ ssh_run_on_remote(cmd.host, cmd.port, cmd.ssh_args, cmd.cmd_args);
+ } else {
+ ssh_run_on_remote_no_wait(cmd.host, cmd.port, cmd.ssh_args, cmd.cmd_args);
+ }
+ }
+ }
+ ssh_pid = 0;
+ cleanup_commands.clear();
+}
+
+Error EditorExportPlatformLinuxBSD::run(const Ref<EditorExportPreset> &p_preset, int p_device, int p_debug_flags) {
+ cleanup();
+ if (p_device) { // Stop command, cleanup only.
+ return OK;
+ }
+
+ EditorProgress ep("run", TTR("Running..."), 5);
+
+ const String dest = EditorPaths::get_singleton()->get_cache_dir().path_join("linuxbsd");
+ Ref<DirAccess> da = DirAccess::create(DirAccess::ACCESS_FILESYSTEM);
+ if (!da->dir_exists(dest)) {
+ Error err = da->make_dir_recursive(dest);
+ if (err != OK) {
+ EditorNode::get_singleton()->show_warning(TTR("Could not create temp directory:") + "\n" + dest);
+ return err;
+ }
+ }
+
+ String host = p_preset->get("ssh_remote_deploy/host").operator String();
+ String port = p_preset->get("ssh_remote_deploy/port").operator String();
+ if (port.is_empty()) {
+ port = "22";
+ }
+ Vector<String> extra_args_ssh = p_preset->get("ssh_remote_deploy/extra_args_ssh").operator String().split(" ");
+ Vector<String> extra_args_scp = p_preset->get("ssh_remote_deploy/extra_args_scp").operator String().split(" ");
+
+ const String basepath = dest.path_join("tmp_linuxbsd_export");
+
+#define CLEANUP_AND_RETURN(m_err) \
+ { \
+ if (da->file_exists(basepath + ".zip")) { \
+ da->remove(basepath + ".zip"); \
+ } \
+ if (da->file_exists(basepath + "_start.sh")) { \
+ da->remove(basepath + "_start.sh"); \
+ } \
+ if (da->file_exists(basepath + "_clean.sh")) { \
+ da->remove(basepath + "_clean.sh"); \
+ } \
+ return m_err; \
+ } \
+ ((void)0)
+
+ if (ep.step(TTR("Exporting project..."), 1)) {
+ return ERR_SKIP;
+ }
+ Error err = export_project(p_preset, true, basepath + ".zip", p_debug_flags);
+ if (err != OK) {
+ DirAccess::remove_file_or_error(basepath + ".zip");
+ return err;
+ }
+
+ String cmd_args;
+ {
+ Vector<String> cmd_args_list;
+ gen_debug_flags(cmd_args_list, p_debug_flags);
+ for (int i = 0; i < cmd_args_list.size(); i++) {
+ if (i != 0) {
+ cmd_args += " ";
+ }
+ cmd_args += cmd_args_list[i];
+ }
+ }
+
+ const bool use_remote = (p_debug_flags & DEBUG_FLAG_REMOTE_DEBUG) || (p_debug_flags & DEBUG_FLAG_DUMB_CLIENT);
+ int dbg_port = EditorSettings::get_singleton()->get("network/debug/remote_port");
+
+ print_line("Creating temporary directory...");
+ ep.step(TTR("Creating temporary directory..."), 2);
+ String temp_dir;
+ err = ssh_run_on_remote(host, port, extra_args_ssh, "mktemp -d", &temp_dir);
+ if (err != OK || temp_dir.is_empty()) {
+ CLEANUP_AND_RETURN(err);
+ }
+
+ print_line("Uploading archive...");
+ ep.step(TTR("Uploading archive..."), 3);
+ err = ssh_push_to_remote(host, port, extra_args_scp, basepath + ".zip", temp_dir);
+ if (err != OK) {
+ CLEANUP_AND_RETURN(err);
+ }
+
+ {
+ String run_script = p_preset->get("ssh_remote_deploy/run_script");
+ run_script = run_script.replace("{temp_dir}", temp_dir);
+ run_script = run_script.replace("{archive_name}", basepath.get_file() + ".zip");
+ run_script = run_script.replace("{exe_name}", basepath.get_file());
+ run_script = run_script.replace("{cmd_args}", cmd_args);
+
+ Ref<FileAccess> f = FileAccess::open(basepath + "_start.sh", FileAccess::WRITE);
+ if (f.is_null()) {
+ CLEANUP_AND_RETURN(err);
+ }
+
+ f->store_string(run_script);
+ }
+
+ {
+ String clean_script = p_preset->get("ssh_remote_deploy/cleanup_script");
+ clean_script = clean_script.replace("{temp_dir}", temp_dir);
+ clean_script = clean_script.replace("{archive_name}", basepath.get_file() + ".zip");
+ clean_script = clean_script.replace("{exe_name}", basepath.get_file());
+ clean_script = clean_script.replace("{cmd_args}", cmd_args);
+
+ Ref<FileAccess> f = FileAccess::open(basepath + "_clean.sh", FileAccess::WRITE);
+ if (f.is_null()) {
+ CLEANUP_AND_RETURN(err);
+ }
+
+ f->store_string(clean_script);
+ }
+
+ print_line("Uploading scripts...");
+ ep.step(TTR("Uploading scripts..."), 4);
+ err = ssh_push_to_remote(host, port, extra_args_scp, basepath + "_start.sh", temp_dir);
+ if (err != OK) {
+ CLEANUP_AND_RETURN(err);
+ }
+ err = ssh_run_on_remote(host, port, extra_args_ssh, vformat("chmod +x \"%s/%s\"", temp_dir, basepath.get_file() + "_start.sh"));
+ if (err != OK || temp_dir.is_empty()) {
+ CLEANUP_AND_RETURN(err);
+ }
+ err = ssh_push_to_remote(host, port, extra_args_scp, basepath + "_clean.sh", temp_dir);
+ if (err != OK) {
+ CLEANUP_AND_RETURN(err);
+ }
+ err = ssh_run_on_remote(host, port, extra_args_ssh, vformat("chmod +x \"%s/%s\"", temp_dir, basepath.get_file() + "_clean.sh"));
+ if (err != OK || temp_dir.is_empty()) {
+ CLEANUP_AND_RETURN(err);
+ }
+
+ print_line("Starting project...");
+ ep.step(TTR("Starting project..."), 5);
+ err = ssh_run_on_remote_no_wait(host, port, extra_args_ssh, vformat("\"%s/%s\"", temp_dir, basepath.get_file() + "_start.sh"), &ssh_pid, (use_remote) ? dbg_port : -1);
+ if (err != OK) {
+ CLEANUP_AND_RETURN(err);
+ }
+
+ cleanup_commands.clear();
+ cleanup_commands.push_back(SSHCleanupCommand(host, port, extra_args_ssh, vformat("\"%s/%s\"", temp_dir, basepath.get_file() + "_clean.sh")));
+
+ print_line("Project started.");
+
+ CLEANUP_AND_RETURN(OK);
+#undef CLEANUP_AND_RETURN
+}
+
+EditorExportPlatformLinuxBSD::EditorExportPlatformLinuxBSD() {
+#ifdef MODULE_SVG_ENABLED
+ Ref<Image> img = memnew(Image);
+ const bool upsample = !Math::is_equal_approx(Math::round(EDSCALE), EDSCALE);
+
+ ImageLoaderSVG img_loader;
+ img_loader.create_image_from_string(img, _linuxbsd_logo_svg, EDSCALE, upsample, false);
+ set_logo(ImageTexture::create_from_image(img));
+
+ img_loader.create_image_from_string(img, _linuxbsd_run_icon_svg, EDSCALE, upsample, false);
+ run_icon = ImageTexture::create_from_image(img);
+#endif
+
+ Ref<Theme> theme = EditorNode::get_singleton()->get_editor_theme();
+ if (theme.is_valid()) {
+ stop_icon = theme->get_icon(SNAME("Stop"), SNAME("EditorIcons"));
+ } else {
+ stop_icon.instantiate();
+ }
+}
diff --git a/platform/linuxbsd/export/export_plugin.h b/platform/linuxbsd/export/export_plugin.h
index 4d6737498b..4f860c3fd0 100644
--- a/platform/linuxbsd/export/export_plugin.h
+++ b/platform/linuxbsd/export/export_plugin.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* export_plugin.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* export_plugin.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef LINUXBSD_EXPORT_PLUGIN_H
#define LINUXBSD_EXPORT_PLUGIN_H
@@ -34,19 +34,58 @@
#include "core/io/file_access.h"
#include "editor/editor_settings.h"
#include "editor/export/editor_export_platform_pc.h"
-#include "platform/linuxbsd/logo.gen.h"
#include "scene/resources/texture.h"
class EditorExportPlatformLinuxBSD : public EditorExportPlatformPC {
+ HashMap<String, String> extensions;
+
+ struct SSHCleanupCommand {
+ String host;
+ String port;
+ Vector<String> ssh_args;
+ String cmd_args;
+ bool wait = false;
+
+ SSHCleanupCommand(){};
+ SSHCleanupCommand(const String &p_host, const String &p_port, const Vector<String> &p_ssh_arg, const String &p_cmd_args, bool p_wait = false) {
+ host = p_host;
+ port = p_port;
+ ssh_args = p_ssh_arg;
+ cmd_args = p_cmd_args;
+ wait = p_wait;
+ };
+ };
+
+ Ref<ImageTexture> run_icon;
+ Ref<ImageTexture> stop_icon;
+
+ Vector<SSHCleanupCommand> cleanup_commands;
+ OS::ProcessID ssh_pid = 0;
+ int menu_options = 0;
+
+ bool is_elf(const String &p_path) const;
+ bool is_shebang(const String &p_path) const;
+
Error _export_debug_script(const Ref<EditorExportPreset> &p_preset, const String &p_app_name, const String &p_pkg_name, const String &p_path);
public:
- void set_extension(const String &p_extension, const String &p_feature_key = "default");
- virtual List<String> get_binary_extensions(const Ref<EditorExportPreset> &p_preset) const override;
virtual void get_export_options(List<ExportOption> *r_options) override;
+ virtual List<String> get_binary_extensions(const Ref<EditorExportPreset> &p_preset) const override;
virtual Error export_project(const Ref<EditorExportPreset> &p_preset, bool p_debug, const String &p_path, int p_flags = 0) override;
virtual String get_template_file_name(const String &p_target, const String &p_arch) const override;
virtual Error fixup_embedded_pck(const String &p_path, int64_t p_embedded_start, int64_t p_embedded_size) override;
+ virtual bool is_executable(const String &p_path) const override;
+
+ virtual Ref<Texture2D> get_run_icon() const override;
+ virtual bool poll_export() override;
+ virtual Ref<ImageTexture> get_option_icon(int p_index) const override;
+ virtual int get_options_count() const override;
+ virtual String get_option_label(int p_index) const override;
+ virtual String get_option_tooltip(int p_index) const override;
+ virtual Error run(const Ref<EditorExportPreset> &p_preset, int p_device, int p_debug_flags) override;
+ virtual void cleanup() override;
+
+ EditorExportPlatformLinuxBSD();
};
#endif // LINUXBSD_EXPORT_PLUGIN_H
diff --git a/platform/linuxbsd/fontconfig-so_wrap.c b/platform/linuxbsd/fontconfig-so_wrap.c
index 1a915faf98..6278522b69 100644
--- a/platform/linuxbsd/fontconfig-so_wrap.c
+++ b/platform/linuxbsd/fontconfig-so_wrap.c
@@ -1,7 +1,7 @@
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by ./generate-wrapper.py 0.3 on 2022-07-29 05:40:07
-// flags: ./generate-wrapper.py --include /usr/include/fontconfig/fontconfig.h --sys-include <fontconfig/fontconfig.h> --soname libfontconfig.so --init-name fontconfig --output-header fontconfig-so_wrap.h --output-implementation fontconfig-so_wrap.c --omit-prefix FcCharSet
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:15:54
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/fontconfig/fontconfig.h --sys-include "thirdparty/linuxbsd_headers/fontconfig/fontconfig.h" --soname libfontconfig.so.1 --init-name fontconfig --omit-prefix FcCharSetFirst --omit-prefix FcCharSetNext --output-header ./platform/linuxbsd/fontconfig-so_wrap.h --output-implementation ./platform/linuxbsd/fontconfig-so_wrap.c
//
#include <stdint.h>
@@ -44,6 +44,23 @@
#define FcConfigSubstitute FcConfigSubstitute_dylibloader_orig_fontconfig
#define FcConfigGetSysRoot FcConfigGetSysRoot_dylibloader_orig_fontconfig
#define FcConfigSetSysRoot FcConfigSetSysRoot_dylibloader_orig_fontconfig
+#define FcCharSetCreate FcCharSetCreate_dylibloader_orig_fontconfig
+#define FcCharSetNew FcCharSetNew_dylibloader_orig_fontconfig
+#define FcCharSetDestroy FcCharSetDestroy_dylibloader_orig_fontconfig
+#define FcCharSetAddChar FcCharSetAddChar_dylibloader_orig_fontconfig
+#define FcCharSetDelChar FcCharSetDelChar_dylibloader_orig_fontconfig
+#define FcCharSetCopy FcCharSetCopy_dylibloader_orig_fontconfig
+#define FcCharSetEqual FcCharSetEqual_dylibloader_orig_fontconfig
+#define FcCharSetIntersect FcCharSetIntersect_dylibloader_orig_fontconfig
+#define FcCharSetUnion FcCharSetUnion_dylibloader_orig_fontconfig
+#define FcCharSetSubtract FcCharSetSubtract_dylibloader_orig_fontconfig
+#define FcCharSetMerge FcCharSetMerge_dylibloader_orig_fontconfig
+#define FcCharSetHasChar FcCharSetHasChar_dylibloader_orig_fontconfig
+#define FcCharSetCount FcCharSetCount_dylibloader_orig_fontconfig
+#define FcCharSetIntersectCount FcCharSetIntersectCount_dylibloader_orig_fontconfig
+#define FcCharSetSubtractCount FcCharSetSubtractCount_dylibloader_orig_fontconfig
+#define FcCharSetIsSubset FcCharSetIsSubset_dylibloader_orig_fontconfig
+#define FcCharSetCoverage FcCharSetCoverage_dylibloader_orig_fontconfig
#define FcValuePrint FcValuePrint_dylibloader_orig_fontconfig
#define FcPatternPrint FcPatternPrint_dylibloader_orig_fontconfig
#define FcFontSetPrint FcFontSetPrint_dylibloader_orig_fontconfig
@@ -193,7 +210,7 @@
#define FcStrListDone FcStrListDone_dylibloader_orig_fontconfig
#define FcConfigParseAndLoad FcConfigParseAndLoad_dylibloader_orig_fontconfig
#define FcConfigParseAndLoadFromMemory FcConfigParseAndLoadFromMemory_dylibloader_orig_fontconfig
-#include <fontconfig/fontconfig.h>
+#include "thirdparty/linuxbsd_headers/fontconfig/fontconfig.h"
#undef FcBlanksCreate
#undef FcBlanksDestroy
#undef FcBlanksAdd
@@ -233,6 +250,23 @@
#undef FcConfigSubstitute
#undef FcConfigGetSysRoot
#undef FcConfigSetSysRoot
+#undef FcCharSetCreate
+#undef FcCharSetNew
+#undef FcCharSetDestroy
+#undef FcCharSetAddChar
+#undef FcCharSetDelChar
+#undef FcCharSetCopy
+#undef FcCharSetEqual
+#undef FcCharSetIntersect
+#undef FcCharSetUnion
+#undef FcCharSetSubtract
+#undef FcCharSetMerge
+#undef FcCharSetHasChar
+#undef FcCharSetCount
+#undef FcCharSetIntersectCount
+#undef FcCharSetSubtractCount
+#undef FcCharSetIsSubset
+#undef FcCharSetCoverage
#undef FcValuePrint
#undef FcPatternPrint
#undef FcFontSetPrint
@@ -423,6 +457,23 @@ FcBool (*FcConfigSubstituteWithPat_dylibloader_wrapper_fontconfig)( FcConfig*, F
FcBool (*FcConfigSubstitute_dylibloader_wrapper_fontconfig)( FcConfig*, FcPattern*, FcMatchKind);
const FcChar8* (*FcConfigGetSysRoot_dylibloader_wrapper_fontconfig)(const FcConfig*);
void (*FcConfigSetSysRoot_dylibloader_wrapper_fontconfig)( FcConfig*,const FcChar8*);
+FcCharSet* (*FcCharSetCreate_dylibloader_wrapper_fontconfig)( void);
+FcCharSet* (*FcCharSetNew_dylibloader_wrapper_fontconfig)( void);
+void (*FcCharSetDestroy_dylibloader_wrapper_fontconfig)( FcCharSet*);
+FcBool (*FcCharSetAddChar_dylibloader_wrapper_fontconfig)( FcCharSet*, FcChar32);
+FcBool (*FcCharSetDelChar_dylibloader_wrapper_fontconfig)( FcCharSet*, FcChar32);
+FcCharSet* (*FcCharSetCopy_dylibloader_wrapper_fontconfig)( FcCharSet*);
+FcBool (*FcCharSetEqual_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+FcCharSet* (*FcCharSetIntersect_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+FcCharSet* (*FcCharSetUnion_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+FcCharSet* (*FcCharSetSubtract_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+FcBool (*FcCharSetMerge_dylibloader_wrapper_fontconfig)( FcCharSet*,const FcCharSet*, FcBool*);
+FcBool (*FcCharSetHasChar_dylibloader_wrapper_fontconfig)(const FcCharSet*, FcChar32);
+FcChar32 (*FcCharSetCount_dylibloader_wrapper_fontconfig)(const FcCharSet*);
+FcChar32 (*FcCharSetIntersectCount_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+FcChar32 (*FcCharSetSubtractCount_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+FcBool (*FcCharSetIsSubset_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+FcChar32 (*FcCharSetCoverage_dylibloader_wrapper_fontconfig)(const FcCharSet*, FcChar32, FcChar32*);
void (*FcValuePrint_dylibloader_wrapper_fontconfig)(const FcValue);
void (*FcPatternPrint_dylibloader_wrapper_fontconfig)(const FcPattern*);
void (*FcFontSetPrint_dylibloader_wrapper_fontconfig)(const FcFontSet*);
@@ -575,7 +626,7 @@ FcBool (*FcConfigParseAndLoadFromMemory_dylibloader_wrapper_fontconfig)( FcConfi
int initialize_fontconfig(int verbose) {
void *handle;
char *error;
- handle = dlopen("libfontconfig.so", RTLD_LAZY);
+ handle = dlopen("libfontconfig.so.1", RTLD_LAZY);
if (!handle) {
if (verbose) {
fprintf(stderr, "%s\n", dlerror());
@@ -895,6 +946,142 @@ int initialize_fontconfig(int verbose) {
fprintf(stderr, "%s\n", error);
}
}
+// FcCharSetCreate
+ *(void **) (&FcCharSetCreate_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetCreate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetNew
+ *(void **) (&FcCharSetNew_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetNew");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetDestroy
+ *(void **) (&FcCharSetDestroy_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetDestroy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetAddChar
+ *(void **) (&FcCharSetAddChar_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetAddChar");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetDelChar
+ *(void **) (&FcCharSetDelChar_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetDelChar");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetCopy
+ *(void **) (&FcCharSetCopy_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetCopy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetEqual
+ *(void **) (&FcCharSetEqual_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetEqual");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetIntersect
+ *(void **) (&FcCharSetIntersect_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetIntersect");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetUnion
+ *(void **) (&FcCharSetUnion_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetUnion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetSubtract
+ *(void **) (&FcCharSetSubtract_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetSubtract");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetMerge
+ *(void **) (&FcCharSetMerge_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetMerge");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetHasChar
+ *(void **) (&FcCharSetHasChar_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetHasChar");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetCount
+ *(void **) (&FcCharSetCount_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetCount");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetIntersectCount
+ *(void **) (&FcCharSetIntersectCount_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetIntersectCount");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetSubtractCount
+ *(void **) (&FcCharSetSubtractCount_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetSubtractCount");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetIsSubset
+ *(void **) (&FcCharSetIsSubset_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetIsSubset");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// FcCharSetCoverage
+ *(void **) (&FcCharSetCoverage_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcCharSetCoverage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
// FcValuePrint
*(void **) (&FcValuePrint_dylibloader_wrapper_fontconfig) = dlsym(handle, "FcValuePrint");
if (verbose) {
diff --git a/platform/linuxbsd/fontconfig-so_wrap.h b/platform/linuxbsd/fontconfig-so_wrap.h
index f0794cce8b..021b2148ae 100644
--- a/platform/linuxbsd/fontconfig-so_wrap.h
+++ b/platform/linuxbsd/fontconfig-so_wrap.h
@@ -2,8 +2,8 @@
#define DYLIBLOAD_WRAPPER_FONTCONFIG
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by ./generate-wrapper.py 0.3 on 2022-07-29 05:40:07
-// flags: ./generate-wrapper.py --include /usr/include/fontconfig/fontconfig.h --sys-include <fontconfig/fontconfig.h> --soname libfontconfig.so --init-name fontconfig --output-header fontconfig-so_wrap.h --output-implementation fontconfig-so_wrap.c --omit-prefix FcCharSet
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:15:54
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/fontconfig/fontconfig.h --sys-include "thirdparty/linuxbsd_headers/fontconfig/fontconfig.h" --soname libfontconfig.so.1 --init-name fontconfig --omit-prefix FcCharSetFirst --omit-prefix FcCharSetNext --output-header ./platform/linuxbsd/fontconfig-so_wrap.h --output-implementation ./platform/linuxbsd/fontconfig-so_wrap.c
//
#include <stdint.h>
@@ -46,6 +46,23 @@
#define FcConfigSubstitute FcConfigSubstitute_dylibloader_orig_fontconfig
#define FcConfigGetSysRoot FcConfigGetSysRoot_dylibloader_orig_fontconfig
#define FcConfigSetSysRoot FcConfigSetSysRoot_dylibloader_orig_fontconfig
+#define FcCharSetCreate FcCharSetCreate_dylibloader_orig_fontconfig
+#define FcCharSetNew FcCharSetNew_dylibloader_orig_fontconfig
+#define FcCharSetDestroy FcCharSetDestroy_dylibloader_orig_fontconfig
+#define FcCharSetAddChar FcCharSetAddChar_dylibloader_orig_fontconfig
+#define FcCharSetDelChar FcCharSetDelChar_dylibloader_orig_fontconfig
+#define FcCharSetCopy FcCharSetCopy_dylibloader_orig_fontconfig
+#define FcCharSetEqual FcCharSetEqual_dylibloader_orig_fontconfig
+#define FcCharSetIntersect FcCharSetIntersect_dylibloader_orig_fontconfig
+#define FcCharSetUnion FcCharSetUnion_dylibloader_orig_fontconfig
+#define FcCharSetSubtract FcCharSetSubtract_dylibloader_orig_fontconfig
+#define FcCharSetMerge FcCharSetMerge_dylibloader_orig_fontconfig
+#define FcCharSetHasChar FcCharSetHasChar_dylibloader_orig_fontconfig
+#define FcCharSetCount FcCharSetCount_dylibloader_orig_fontconfig
+#define FcCharSetIntersectCount FcCharSetIntersectCount_dylibloader_orig_fontconfig
+#define FcCharSetSubtractCount FcCharSetSubtractCount_dylibloader_orig_fontconfig
+#define FcCharSetIsSubset FcCharSetIsSubset_dylibloader_orig_fontconfig
+#define FcCharSetCoverage FcCharSetCoverage_dylibloader_orig_fontconfig
#define FcValuePrint FcValuePrint_dylibloader_orig_fontconfig
#define FcPatternPrint FcPatternPrint_dylibloader_orig_fontconfig
#define FcFontSetPrint FcFontSetPrint_dylibloader_orig_fontconfig
@@ -195,7 +212,7 @@
#define FcStrListDone FcStrListDone_dylibloader_orig_fontconfig
#define FcConfigParseAndLoad FcConfigParseAndLoad_dylibloader_orig_fontconfig
#define FcConfigParseAndLoadFromMemory FcConfigParseAndLoadFromMemory_dylibloader_orig_fontconfig
-#include <fontconfig/fontconfig.h>
+#include "thirdparty/linuxbsd_headers/fontconfig/fontconfig.h"
#undef FcBlanksCreate
#undef FcBlanksDestroy
#undef FcBlanksAdd
@@ -235,6 +252,23 @@
#undef FcConfigSubstitute
#undef FcConfigGetSysRoot
#undef FcConfigSetSysRoot
+#undef FcCharSetCreate
+#undef FcCharSetNew
+#undef FcCharSetDestroy
+#undef FcCharSetAddChar
+#undef FcCharSetDelChar
+#undef FcCharSetCopy
+#undef FcCharSetEqual
+#undef FcCharSetIntersect
+#undef FcCharSetUnion
+#undef FcCharSetSubtract
+#undef FcCharSetMerge
+#undef FcCharSetHasChar
+#undef FcCharSetCount
+#undef FcCharSetIntersectCount
+#undef FcCharSetSubtractCount
+#undef FcCharSetIsSubset
+#undef FcCharSetCoverage
#undef FcValuePrint
#undef FcPatternPrint
#undef FcFontSetPrint
@@ -426,6 +460,23 @@ extern "C" {
#define FcConfigSubstitute FcConfigSubstitute_dylibloader_wrapper_fontconfig
#define FcConfigGetSysRoot FcConfigGetSysRoot_dylibloader_wrapper_fontconfig
#define FcConfigSetSysRoot FcConfigSetSysRoot_dylibloader_wrapper_fontconfig
+#define FcCharSetCreate FcCharSetCreate_dylibloader_wrapper_fontconfig
+#define FcCharSetNew FcCharSetNew_dylibloader_wrapper_fontconfig
+#define FcCharSetDestroy FcCharSetDestroy_dylibloader_wrapper_fontconfig
+#define FcCharSetAddChar FcCharSetAddChar_dylibloader_wrapper_fontconfig
+#define FcCharSetDelChar FcCharSetDelChar_dylibloader_wrapper_fontconfig
+#define FcCharSetCopy FcCharSetCopy_dylibloader_wrapper_fontconfig
+#define FcCharSetEqual FcCharSetEqual_dylibloader_wrapper_fontconfig
+#define FcCharSetIntersect FcCharSetIntersect_dylibloader_wrapper_fontconfig
+#define FcCharSetUnion FcCharSetUnion_dylibloader_wrapper_fontconfig
+#define FcCharSetSubtract FcCharSetSubtract_dylibloader_wrapper_fontconfig
+#define FcCharSetMerge FcCharSetMerge_dylibloader_wrapper_fontconfig
+#define FcCharSetHasChar FcCharSetHasChar_dylibloader_wrapper_fontconfig
+#define FcCharSetCount FcCharSetCount_dylibloader_wrapper_fontconfig
+#define FcCharSetIntersectCount FcCharSetIntersectCount_dylibloader_wrapper_fontconfig
+#define FcCharSetSubtractCount FcCharSetSubtractCount_dylibloader_wrapper_fontconfig
+#define FcCharSetIsSubset FcCharSetIsSubset_dylibloader_wrapper_fontconfig
+#define FcCharSetCoverage FcCharSetCoverage_dylibloader_wrapper_fontconfig
#define FcValuePrint FcValuePrint_dylibloader_wrapper_fontconfig
#define FcPatternPrint FcPatternPrint_dylibloader_wrapper_fontconfig
#define FcFontSetPrint FcFontSetPrint_dylibloader_wrapper_fontconfig
@@ -614,6 +665,23 @@ extern FcBool (*FcConfigSubstituteWithPat_dylibloader_wrapper_fontconfig)( FcCon
extern FcBool (*FcConfigSubstitute_dylibloader_wrapper_fontconfig)( FcConfig*, FcPattern*, FcMatchKind);
extern const FcChar8* (*FcConfigGetSysRoot_dylibloader_wrapper_fontconfig)(const FcConfig*);
extern void (*FcConfigSetSysRoot_dylibloader_wrapper_fontconfig)( FcConfig*,const FcChar8*);
+extern FcCharSet* (*FcCharSetCreate_dylibloader_wrapper_fontconfig)( void);
+extern FcCharSet* (*FcCharSetNew_dylibloader_wrapper_fontconfig)( void);
+extern void (*FcCharSetDestroy_dylibloader_wrapper_fontconfig)( FcCharSet*);
+extern FcBool (*FcCharSetAddChar_dylibloader_wrapper_fontconfig)( FcCharSet*, FcChar32);
+extern FcBool (*FcCharSetDelChar_dylibloader_wrapper_fontconfig)( FcCharSet*, FcChar32);
+extern FcCharSet* (*FcCharSetCopy_dylibloader_wrapper_fontconfig)( FcCharSet*);
+extern FcBool (*FcCharSetEqual_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+extern FcCharSet* (*FcCharSetIntersect_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+extern FcCharSet* (*FcCharSetUnion_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+extern FcCharSet* (*FcCharSetSubtract_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+extern FcBool (*FcCharSetMerge_dylibloader_wrapper_fontconfig)( FcCharSet*,const FcCharSet*, FcBool*);
+extern FcBool (*FcCharSetHasChar_dylibloader_wrapper_fontconfig)(const FcCharSet*, FcChar32);
+extern FcChar32 (*FcCharSetCount_dylibloader_wrapper_fontconfig)(const FcCharSet*);
+extern FcChar32 (*FcCharSetIntersectCount_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+extern FcChar32 (*FcCharSetSubtractCount_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+extern FcBool (*FcCharSetIsSubset_dylibloader_wrapper_fontconfig)(const FcCharSet*,const FcCharSet*);
+extern FcChar32 (*FcCharSetCoverage_dylibloader_wrapper_fontconfig)(const FcCharSet*, FcChar32, FcChar32*);
extern void (*FcValuePrint_dylibloader_wrapper_fontconfig)(const FcValue);
extern void (*FcPatternPrint_dylibloader_wrapper_fontconfig)(const FcPattern*);
extern void (*FcFontSetPrint_dylibloader_wrapper_fontconfig)(const FcFontSet*);
diff --git a/platform/linuxbsd/freedesktop_portal_desktop.cpp b/platform/linuxbsd/freedesktop_portal_desktop.cpp
index ed54084694..72d4e3772f 100644
--- a/platform/linuxbsd/freedesktop_portal_desktop.cpp
+++ b/platform/linuxbsd/freedesktop_portal_desktop.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* freedesktop_portal_desktop.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* freedesktop_portal_desktop.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "freedesktop_portal_desktop.h"
diff --git a/platform/linuxbsd/freedesktop_portal_desktop.h b/platform/linuxbsd/freedesktop_portal_desktop.h
index 3d976b1ede..1520ab3a1f 100644
--- a/platform/linuxbsd/freedesktop_portal_desktop.h
+++ b/platform/linuxbsd/freedesktop_portal_desktop.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* freedesktop_portal_desktop.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* freedesktop_portal_desktop.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef FREEDESKTOP_PORTAL_DESKTOP_H
#define FREEDESKTOP_PORTAL_DESKTOP_H
diff --git a/platform/linuxbsd/freedesktop_screensaver.cpp b/platform/linuxbsd/freedesktop_screensaver.cpp
index fa3f7fbfea..159fd0df61 100644
--- a/platform/linuxbsd/freedesktop_screensaver.cpp
+++ b/platform/linuxbsd/freedesktop_screensaver.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* freedesktop_screensaver.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* freedesktop_screensaver.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "freedesktop_screensaver.h"
@@ -55,7 +55,7 @@ void FreeDesktopScreenSaver::inhibit() {
return;
}
- String app_name_string = ProjectSettings::get_singleton()->get("application/config/name");
+ String app_name_string = GLOBAL_GET("application/config/name");
CharString app_name_utf8 = app_name_string.utf8();
const char *app_name = app_name_string.is_empty() ? "Godot Engine" : app_name_utf8.get_data();
diff --git a/platform/linuxbsd/freedesktop_screensaver.h b/platform/linuxbsd/freedesktop_screensaver.h
index 1a8b010cd5..e9f0c566a5 100644
--- a/platform/linuxbsd/freedesktop_screensaver.h
+++ b/platform/linuxbsd/freedesktop_screensaver.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* freedesktop_screensaver.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* freedesktop_screensaver.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef FREEDESKTOP_SCREENSAVER_H
#define FREEDESKTOP_SCREENSAVER_H
diff --git a/platform/linuxbsd/godot_linuxbsd.cpp b/platform/linuxbsd/godot_linuxbsd.cpp
index 91a260182e..76d579dd53 100644
--- a/platform/linuxbsd/godot_linuxbsd.cpp
+++ b/platform/linuxbsd/godot_linuxbsd.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* godot_linuxbsd.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* godot_linuxbsd.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include <limits.h>
#include <locale.h>
@@ -69,6 +69,7 @@ int main(int argc, char *argv[]) {
}
if (Main::start()) {
+ os.set_exit_code(EXIT_SUCCESS);
os.run(); // it is actually the OS that decides how to run
}
Main::cleanup();
diff --git a/platform/linuxbsd/joypad_linux.cpp b/platform/linuxbsd/joypad_linux.cpp
index bc018e366b..b77f989677 100644
--- a/platform/linuxbsd/joypad_linux.cpp
+++ b/platform/linuxbsd/joypad_linux.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* joypad_linux.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* joypad_linux.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifdef JOYDEV_ENABLED
@@ -59,7 +59,7 @@ JoypadLinux::Joypad::~Joypad() {
}
void JoypadLinux::Joypad::reset() {
- dpad = HatMask::CENTER;
+ dpad = 0;
fd = -1;
for (int i = 0; i < MAX_ABS; i++) {
abs_map[i] = -1;
@@ -218,8 +218,8 @@ void JoypadLinux::monitor_joypads() {
}
}
closedir(input_directory);
+ usleep(1000000); // 1s
}
- usleep(1000000); // 1s
}
void JoypadLinux::close_joypads() {
@@ -485,27 +485,33 @@ void JoypadLinux::process_joypads() {
case ABS_HAT0X:
if (joypad_event.value != 0) {
if (joypad_event.value < 0) {
- joypad.dpad = (HatMask)((joypad.dpad | HatMask::LEFT) & ~HatMask::RIGHT);
+ joypad.dpad.set_flag(HatMask::LEFT);
+ joypad.dpad.clear_flag(HatMask::RIGHT);
} else {
- joypad.dpad = (HatMask)((joypad.dpad | HatMask::RIGHT) & ~HatMask::LEFT);
+ joypad.dpad.set_flag(HatMask::RIGHT);
+ joypad.dpad.clear_flag(HatMask::LEFT);
}
} else {
- joypad.dpad &= ~(HatMask::LEFT | HatMask::RIGHT);
+ joypad.dpad.clear_flag(HatMask::LEFT);
+ joypad.dpad.clear_flag(HatMask::RIGHT);
}
- input->joy_hat(i, (HatMask)joypad.dpad);
+ input->joy_hat(i, joypad.dpad);
break;
case ABS_HAT0Y:
if (joypad_event.value != 0) {
if (joypad_event.value < 0) {
- joypad.dpad = (HatMask)((joypad.dpad | HatMask::UP) & ~HatMask::DOWN);
+ joypad.dpad.set_flag(HatMask::UP);
+ joypad.dpad.clear_flag(HatMask::DOWN);
} else {
- joypad.dpad = (HatMask)((joypad.dpad | HatMask::DOWN) & ~HatMask::UP);
+ joypad.dpad.set_flag(HatMask::DOWN);
+ joypad.dpad.clear_flag(HatMask::UP);
}
} else {
- joypad.dpad &= ~(HatMask::UP | HatMask::DOWN);
+ joypad.dpad.clear_flag(HatMask::UP);
+ joypad.dpad.clear_flag(HatMask::DOWN);
}
- input->joy_hat(i, (HatMask)joypad.dpad);
+ input->joy_hat(i, joypad.dpad);
break;
default:
diff --git a/platform/linuxbsd/joypad_linux.h b/platform/linuxbsd/joypad_linux.h
index 4afc261ce7..6661abdb37 100644
--- a/platform/linuxbsd/joypad_linux.h
+++ b/platform/linuxbsd/joypad_linux.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* joypad_linux.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* joypad_linux.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef JOYPAD_LINUX_H
#define JOYPAD_LINUX_H
@@ -62,7 +62,7 @@ private:
float curr_axis[MAX_ABS];
int key_map[MAX_KEY];
int abs_map[MAX_ABS];
- HatMask dpad = HatMask::CENTER;
+ BitField<HatMask> dpad;
int fd = -1;
String devpath;
diff --git a/platform/linuxbsd/key_mapping_x11.cpp b/platform/linuxbsd/key_mapping_x11.cpp
deleted file mode 100644
index 047ee74671..0000000000
--- a/platform/linuxbsd/key_mapping_x11.cpp
+++ /dev/null
@@ -1,1997 +0,0 @@
-/*************************************************************************/
-/* key_mapping_x11.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
-
-#include "key_mapping_x11.h"
-
-/***** SCAN CODE CONVERSION ******/
-
-struct _XTranslatePair {
- KeySym keysym;
- Key keycode;
-};
-
-static _XTranslatePair _xkeysym_to_keycode[] = {
- // misc keys
-
- { XK_Escape, Key::ESCAPE },
- { XK_Tab, Key::TAB },
- { XK_ISO_Left_Tab, Key::BACKTAB },
- { XK_BackSpace, Key::BACKSPACE },
- { XK_Return, Key::ENTER },
- { XK_Insert, Key::INSERT },
- { XK_Delete, Key::KEY_DELETE },
- { XK_Clear, Key::KEY_DELETE },
- { XK_Pause, Key::PAUSE },
- { XK_Print, Key::PRINT },
- { XK_Home, Key::HOME },
- { XK_End, Key::END },
- { XK_Left, Key::LEFT },
- { XK_Up, Key::UP },
- { XK_Right, Key::RIGHT },
- { XK_Down, Key::DOWN },
- { XK_Prior, Key::PAGEUP },
- { XK_Next, Key::PAGEDOWN },
- { XK_Shift_L, Key::SHIFT },
- { XK_Shift_R, Key::SHIFT },
- { XK_Shift_Lock, Key::SHIFT },
- { XK_Control_L, Key::CTRL },
- { XK_Control_R, Key::CTRL },
- { XK_Meta_L, Key::META },
- { XK_Meta_R, Key::META },
- { XK_Alt_L, Key::ALT },
- { XK_Alt_R, Key::ALT },
- { XK_Caps_Lock, Key::CAPSLOCK },
- { XK_Num_Lock, Key::NUMLOCK },
- { XK_Scroll_Lock, Key::SCROLLLOCK },
- { XK_Super_L, Key::SUPER_L },
- { XK_Super_R, Key::SUPER_R },
- { XK_Menu, Key::MENU },
- { XK_Hyper_L, Key::HYPER_L },
- { XK_Hyper_R, Key::HYPER_R },
- { XK_Help, Key::HELP },
- { XK_KP_Space, Key::SPACE },
- { XK_KP_Tab, Key::TAB },
- { XK_KP_Enter, Key::KP_ENTER },
- { XK_Home, Key::HOME },
- { XK_Left, Key::LEFT },
- { XK_Up, Key::UP },
- { XK_Right, Key::RIGHT },
- { XK_Down, Key::DOWN },
- { XK_Prior, Key::PAGEUP },
- { XK_Next, Key::PAGEDOWN },
- { XK_End, Key::END },
- { XK_Begin, Key::CLEAR },
- { XK_Insert, Key::INSERT },
- { XK_Delete, Key::KEY_DELETE },
- //{ XK_KP_Equal, Key::EQUAL },
- //{ XK_KP_Separator, Key::COMMA },
- { XK_KP_Decimal, Key::KP_PERIOD },
- { XK_KP_Delete, Key::KP_PERIOD },
- { XK_KP_Multiply, Key::KP_MULTIPLY },
- { XK_KP_Divide, Key::KP_DIVIDE },
- { XK_KP_Subtract, Key::KP_SUBTRACT },
- { XK_KP_Add, Key::KP_ADD },
- { XK_KP_0, Key::KP_0 },
- { XK_KP_1, Key::KP_1 },
- { XK_KP_2, Key::KP_2 },
- { XK_KP_3, Key::KP_3 },
- { XK_KP_4, Key::KP_4 },
- { XK_KP_5, Key::KP_5 },
- { XK_KP_6, Key::KP_6 },
- { XK_KP_7, Key::KP_7 },
- { XK_KP_8, Key::KP_8 },
- { XK_KP_9, Key::KP_9 },
- // same but with numlock
- { XK_KP_Insert, Key::KP_0 },
- { XK_KP_End, Key::KP_1 },
- { XK_KP_Down, Key::KP_2 },
- { XK_KP_Page_Down, Key::KP_3 },
- { XK_KP_Left, Key::KP_4 },
- { XK_KP_Begin, Key::KP_5 },
- { XK_KP_Right, Key::KP_6 },
- { XK_KP_Home, Key::KP_7 },
- { XK_KP_Up, Key::KP_8 },
- { XK_KP_Page_Up, Key::KP_9 },
- { XK_F1, Key::F1 },
- { XK_F2, Key::F2 },
- { XK_F3, Key::F3 },
- { XK_F4, Key::F4 },
- { XK_F5, Key::F5 },
- { XK_F6, Key::F6 },
- { XK_F7, Key::F7 },
- { XK_F8, Key::F8 },
- { XK_F9, Key::F9 },
- { XK_F10, Key::F10 },
- { XK_F11, Key::F11 },
- { XK_F12, Key::F12 },
- { XK_F13, Key::F13 },
- { XK_F14, Key::F14 },
- { XK_F15, Key::F15 },
- { XK_F16, Key::F16 },
- { XK_F17, Key::F17 },
- { XK_F18, Key::F18 },
- { XK_F19, Key::F19 },
- { XK_F20, Key::F20 },
- { XK_F21, Key::F21 },
- { XK_F22, Key::F22 },
- { XK_F23, Key::F23 },
- { XK_F24, Key::F24 },
- { XK_F25, Key::F25 },
- { XK_F26, Key::F26 },
- { XK_F27, Key::F27 },
- { XK_F28, Key::F28 },
- { XK_F29, Key::F29 },
- { XK_F30, Key::F30 },
- { XK_F31, Key::F31 },
- { XK_F32, Key::F32 },
- { XK_F33, Key::F33 },
- { XK_F34, Key::F34 },
- { XK_F35, Key::F35 },
-
- // media keys
- { XF86XK_Back, Key::BACK },
- { XF86XK_Forward, Key::FORWARD },
- { XF86XK_Stop, Key::STOP },
- { XF86XK_Refresh, Key::REFRESH },
- { XF86XK_Favorites, Key::FAVORITES },
- { XF86XK_AudioMedia, Key::LAUNCHMEDIA },
- { XF86XK_OpenURL, Key::OPENURL },
- { XF86XK_HomePage, Key::HOMEPAGE },
- { XF86XK_Search, Key::SEARCH },
- { XF86XK_AudioLowerVolume, Key::VOLUMEDOWN },
- { XF86XK_AudioMute, Key::VOLUMEMUTE },
- { XF86XK_AudioRaiseVolume, Key::VOLUMEUP },
- { XF86XK_AudioPlay, Key::MEDIAPLAY },
- { XF86XK_AudioStop, Key::MEDIASTOP },
- { XF86XK_AudioPrev, Key::MEDIAPREVIOUS },
- { XF86XK_AudioNext, Key::MEDIANEXT },
- { XF86XK_AudioRecord, Key::MEDIARECORD },
-
- // launch keys
- { XF86XK_Mail, Key::LAUNCHMAIL },
- { XF86XK_MyComputer, Key::LAUNCH0 },
- { XF86XK_Calculator, Key::LAUNCH1 },
- { XF86XK_Standby, Key::STANDBY },
-
- { XF86XK_Launch0, Key::LAUNCH2 },
- { XF86XK_Launch1, Key::LAUNCH3 },
- { XF86XK_Launch2, Key::LAUNCH4 },
- { XF86XK_Launch3, Key::LAUNCH5 },
- { XF86XK_Launch4, Key::LAUNCH6 },
- { XF86XK_Launch5, Key::LAUNCH7 },
- { XF86XK_Launch6, Key::LAUNCH8 },
- { XF86XK_Launch7, Key::LAUNCH9 },
- { XF86XK_Launch8, Key::LAUNCHA },
- { XF86XK_Launch9, Key::LAUNCHB },
- { XF86XK_LaunchA, Key::LAUNCHC },
- { XF86XK_LaunchB, Key::LAUNCHD },
- { XF86XK_LaunchC, Key::LAUNCHE },
- { XF86XK_LaunchD, Key::LAUNCHF },
-
- { 0, Key::NONE }
-};
-
-struct _TranslatePair {
- Key keysym;
- unsigned int keycode;
-};
-
-static _TranslatePair _scancode_to_keycode[] = {
- { Key::ESCAPE, 0x09 },
- { Key::KEY_1, 0x0A },
- { Key::KEY_2, 0x0B },
- { Key::KEY_3, 0x0C },
- { Key::KEY_4, 0x0D },
- { Key::KEY_5, 0x0E },
- { Key::KEY_6, 0x0F },
- { Key::KEY_7, 0x10 },
- { Key::KEY_8, 0x11 },
- { Key::KEY_9, 0x12 },
- { Key::KEY_0, 0x13 },
- { Key::MINUS, 0x14 },
- { Key::EQUAL, 0x15 },
- { Key::BACKSPACE, 0x16 },
- { Key::TAB, 0x17 },
- { Key::Q, 0x18 },
- { Key::W, 0x19 },
- { Key::E, 0x1A },
- { Key::R, 0x1B },
- { Key::T, 0x1C },
- { Key::Y, 0x1D },
- { Key::U, 0x1E },
- { Key::I, 0x1F },
- { Key::O, 0x20 },
- { Key::P, 0x21 },
- { Key::BRACELEFT, 0x22 },
- { Key::BRACERIGHT, 0x23 },
- { Key::ENTER, 0x24 },
- { Key::CTRL, 0x25 },
- { Key::A, 0x26 },
- { Key::S, 0x27 },
- { Key::D, 0x28 },
- { Key::F, 0x29 },
- { Key::G, 0x2A },
- { Key::H, 0x2B },
- { Key::J, 0x2C },
- { Key::K, 0x2D },
- { Key::L, 0x2E },
- { Key::SEMICOLON, 0x2F },
- { Key::APOSTROPHE, 0x30 },
- { Key::QUOTELEFT, 0x31 },
- { Key::SHIFT, 0x32 },
- { Key::BACKSLASH, 0x33 },
- { Key::Z, 0x34 },
- { Key::X, 0x35 },
- { Key::C, 0x36 },
- { Key::V, 0x37 },
- { Key::B, 0x38 },
- { Key::N, 0x39 },
- { Key::M, 0x3A },
- { Key::COMMA, 0x3B },
- { Key::PERIOD, 0x3C },
- { Key::SLASH, 0x3D },
- { Key::SHIFT, 0x3E },
- { Key::KP_MULTIPLY, 0x3F },
- { Key::ALT, 0x40 },
- { Key::SPACE, 0x41 },
- { Key::CAPSLOCK, 0x42 },
- { Key::F1, 0x43 },
- { Key::F2, 0x44 },
- { Key::F3, 0x45 },
- { Key::F4, 0x46 },
- { Key::F5, 0x47 },
- { Key::F6, 0x48 },
- { Key::F7, 0x49 },
- { Key::F8, 0x4A },
- { Key::F9, 0x4B },
- { Key::F10, 0x4C },
- { Key::NUMLOCK, 0x4D },
- { Key::SCROLLLOCK, 0x4E },
- { Key::KP_7, 0x4F },
- { Key::KP_8, 0x50 },
- { Key::KP_9, 0x51 },
- { Key::KP_SUBTRACT, 0x52 },
- { Key::KP_4, 0x53 },
- { Key::KP_5, 0x54 },
- { Key::KP_6, 0x55 },
- { Key::KP_ADD, 0x56 },
- { Key::KP_1, 0x57 },
- { Key::KP_2, 0x58 },
- { Key::KP_3, 0x59 },
- { Key::KP_0, 0x5A },
- { Key::KP_PERIOD, 0x5B },
- //{ Key::???, 0x5E }, //NON US BACKSLASH
- { Key::F11, 0x5F },
- { Key::F12, 0x60 },
- { Key::KP_ENTER, 0x68 },
- { Key::CTRL, 0x69 },
- { Key::KP_DIVIDE, 0x6A },
- { Key::PRINT, 0x6B },
- { Key::ALT, 0x6C },
- { Key::ENTER, 0x6D },
- { Key::HOME, 0x6E },
- { Key::UP, 0x6F },
- { Key::PAGEUP, 0x70 },
- { Key::LEFT, 0x71 },
- { Key::RIGHT, 0x72 },
- { Key::END, 0x73 },
- { Key::DOWN, 0x74 },
- { Key::PAGEDOWN, 0x75 },
- { Key::INSERT, 0x76 },
- { Key::KEY_DELETE, 0x77 },
- { Key::VOLUMEMUTE, 0x79 },
- { Key::VOLUMEDOWN, 0x7A },
- { Key::VOLUMEUP, 0x7B },
- { Key::PAUSE, 0x7F },
- { Key::SUPER_L, 0x85 },
- { Key::SUPER_R, 0x86 },
- { Key::MENU, 0x87 },
- { Key::F13, 0xBF },
- { Key::F14, 0xC0 },
- { Key::F15, 0xC1 },
- { Key::F16, 0xC2 },
- { Key::F17, 0xC3 },
- { Key::F18, 0xC4 },
- { Key::F19, 0xC5 },
- { Key::F20, 0xC6 },
- { Key::F21, 0xC7 },
- { Key::F22, 0xC8 },
- { Key::F23, 0xC9 },
- { Key::F24, 0xCA },
- { Key::F25, 0xCB },
- { Key::F26, 0xCC },
- { Key::F27, 0xCD },
- { Key::F28, 0xCE },
- { Key::F29, 0xCF },
- { Key::F30, 0xD0 },
- { Key::F31, 0xD1 },
- { Key::F32, 0xD2 },
- { Key::F33, 0xD3 },
- { Key::F34, 0xD4 },
- { Key::F35, 0xD5 },
- { Key::UNKNOWN, 0 }
-};
-
-Key KeyMappingX11::get_scancode(unsigned int p_code) {
- Key keycode = Key::UNKNOWN;
- for (int i = 0; _scancode_to_keycode[i].keysym != Key::UNKNOWN; i++) {
- if (_scancode_to_keycode[i].keycode == p_code) {
- keycode = _scancode_to_keycode[i].keysym;
- break;
- }
- }
-
- return keycode;
-}
-
-unsigned int KeyMappingX11::get_xlibcode(Key p_keysym) {
- unsigned int code = 0;
- for (int i = 0; _scancode_to_keycode[i].keysym != Key::UNKNOWN; i++) {
- if (_scancode_to_keycode[i].keysym == p_keysym) {
- code = _scancode_to_keycode[i].keycode;
- break;
- }
- }
-
- return code;
-}
-
-Key KeyMappingX11::get_keycode(KeySym p_keysym) {
- // kinda bruteforce.. could optimize.
-
- if (p_keysym < 0x100) { // Latin 1, maps 1-1
- return (Key)p_keysym;
- }
-
- // look for special key
- for (int idx = 0; _xkeysym_to_keycode[idx].keysym != 0; idx++) {
- if (_xkeysym_to_keycode[idx].keysym == p_keysym) {
- return _xkeysym_to_keycode[idx].keycode;
- }
- }
-
- return Key::NONE;
-}
-
-KeySym KeyMappingX11::get_keysym(Key p_code) {
- // kinda bruteforce.. could optimize.
-
- if (p_code < Key::END_LATIN1) { // Latin 1, maps 1-1
- return (KeySym)p_code;
- }
-
- // look for special key
- for (int idx = 0; _xkeysym_to_keycode[idx].keysym != 0; idx++) {
- if (_xkeysym_to_keycode[idx].keycode == p_code) {
- return _xkeysym_to_keycode[idx].keysym;
- }
- }
-
- return (KeySym)Key::NONE;
-}
-
-/***** UNICODE CONVERSION ******/
-
-// Tables taken from FOX toolkit
-
-struct _XTranslateUnicodePair {
- KeySym keysym;
- unsigned int unicode;
-};
-
-enum {
- _KEYSYM_MAX = 759
-};
-
-static _XTranslateUnicodePair _xkeysym_to_unicode[_KEYSYM_MAX] = {
- { 0x01A1, 0x0104 },
- { 0x01A2, 0x02D8 },
- { 0x01A3, 0x0141 },
- { 0x01A5, 0x013D },
- { 0x01A6, 0x015A },
- { 0x01A9, 0x0160 },
- { 0x01AA, 0x015E },
- { 0x01AB, 0x0164 },
- { 0x01AC, 0x0179 },
- { 0x01AE, 0x017D },
- { 0x01AF, 0x017B },
- { 0x01B1, 0x0105 },
- { 0x01B2, 0x02DB },
- { 0x01B3, 0x0142 },
- { 0x01B5, 0x013E },
- { 0x01B6, 0x015B },
- { 0x01B7, 0x02C7 },
- { 0x01B9, 0x0161 },
- { 0x01BA, 0x015F },
- { 0x01BB, 0x0165 },
- { 0x01BC, 0x017A },
- { 0x01BD, 0x02DD },
- { 0x01BE, 0x017E },
- { 0x01BF, 0x017C },
- { 0x01C0, 0x0154 },
- { 0x01C3, 0x0102 },
- { 0x01C5, 0x0139 },
- { 0x01C6, 0x0106 },
- { 0x01C8, 0x010C },
- { 0x01CA, 0x0118 },
- { 0x01CC, 0x011A },
- { 0x01CF, 0x010E },
- { 0x01D0, 0x0110 },
- { 0x01D1, 0x0143 },
- { 0x01D2, 0x0147 },
- { 0x01D5, 0x0150 },
- { 0x01D8, 0x0158 },
- { 0x01D9, 0x016E },
- { 0x01DB, 0x0170 },
- { 0x01DE, 0x0162 },
- { 0x01E0, 0x0155 },
- { 0x01E3, 0x0103 },
- { 0x01E5, 0x013A },
- { 0x01E6, 0x0107 },
- { 0x01E8, 0x010D },
- { 0x01EA, 0x0119 },
- { 0x01EC, 0x011B },
- { 0x01EF, 0x010F },
- { 0x01F0, 0x0111 },
- { 0x01F1, 0x0144 },
- { 0x01F2, 0x0148 },
- { 0x01F5, 0x0151 },
- { 0x01F8, 0x0159 },
- { 0x01F9, 0x016F },
- { 0x01FB, 0x0171 },
- { 0x01FE, 0x0163 },
- { 0x01FF, 0x02D9 },
- { 0x02A1, 0x0126 },
- { 0x02A6, 0x0124 },
- { 0x02A9, 0x0130 },
- { 0x02AB, 0x011E },
- { 0x02AC, 0x0134 },
- { 0x02B1, 0x0127 },
- { 0x02B6, 0x0125 },
- { 0x02B9, 0x0131 },
- { 0x02BB, 0x011F },
- { 0x02BC, 0x0135 },
- { 0x02C5, 0x010A },
- { 0x02C6, 0x0108 },
- { 0x02D5, 0x0120 },
- { 0x02D8, 0x011C },
- { 0x02DD, 0x016C },
- { 0x02DE, 0x015C },
- { 0x02E5, 0x010B },
- { 0x02E6, 0x0109 },
- { 0x02F5, 0x0121 },
- { 0x02F8, 0x011D },
- { 0x02FD, 0x016D },
- { 0x02FE, 0x015D },
- { 0x03A2, 0x0138 },
- { 0x03A3, 0x0156 },
- { 0x03A5, 0x0128 },
- { 0x03A6, 0x013B },
- { 0x03AA, 0x0112 },
- { 0x03AB, 0x0122 },
- { 0x03AC, 0x0166 },
- { 0x03B3, 0x0157 },
- { 0x03B5, 0x0129 },
- { 0x03B6, 0x013C },
- { 0x03BA, 0x0113 },
- { 0x03BB, 0x0123 },
- { 0x03BC, 0x0167 },
- { 0x03BD, 0x014A },
- { 0x03BF, 0x014B },
- { 0x03C0, 0x0100 },
- { 0x03C7, 0x012E },
- { 0x03CC, 0x0116 },
- { 0x03CF, 0x012A },
- { 0x03D1, 0x0145 },
- { 0x03D2, 0x014C },
- { 0x03D3, 0x0136 },
- { 0x03D9, 0x0172 },
- { 0x03DD, 0x0168 },
- { 0x03DE, 0x016A },
- { 0x03E0, 0x0101 },
- { 0x03E7, 0x012F },
- { 0x03EC, 0x0117 },
- { 0x03EF, 0x012B },
- { 0x03F1, 0x0146 },
- { 0x03F2, 0x014D },
- { 0x03F3, 0x0137 },
- { 0x03F9, 0x0173 },
- { 0x03FD, 0x0169 },
- { 0x03FE, 0x016B },
- { 0x047E, 0x203E },
- { 0x04A1, 0x3002 },
- { 0x04A2, 0x300C },
- { 0x04A3, 0x300D },
- { 0x04A4, 0x3001 },
- { 0x04A5, 0x30FB },
- { 0x04A6, 0x30F2 },
- { 0x04A7, 0x30A1 },
- { 0x04A8, 0x30A3 },
- { 0x04A9, 0x30A5 },
- { 0x04AA, 0x30A7 },
- { 0x04AB, 0x30A9 },
- { 0x04AC, 0x30E3 },
- { 0x04AD, 0x30E5 },
- { 0x04AE, 0x30E7 },
- { 0x04AF, 0x30C3 },
- { 0x04B0, 0x30FC },
- { 0x04B1, 0x30A2 },
- { 0x04B2, 0x30A4 },
- { 0x04B3, 0x30A6 },
- { 0x04B4, 0x30A8 },
- { 0x04B5, 0x30AA },
- { 0x04B6, 0x30AB },
- { 0x04B7, 0x30AD },
- { 0x04B8, 0x30AF },
- { 0x04B9, 0x30B1 },
- { 0x04BA, 0x30B3 },
- { 0x04BB, 0x30B5 },
- { 0x04BC, 0x30B7 },
- { 0x04BD, 0x30B9 },
- { 0x04BE, 0x30BB },
- { 0x04BF, 0x30BD },
- { 0x04C0, 0x30BF },
- { 0x04C1, 0x30C1 },
- { 0x04C2, 0x30C4 },
- { 0x04C3, 0x30C6 },
- { 0x04C4, 0x30C8 },
- { 0x04C5, 0x30CA },
- { 0x04C6, 0x30CB },
- { 0x04C7, 0x30CC },
- { 0x04C8, 0x30CD },
- { 0x04C9, 0x30CE },
- { 0x04CA, 0x30CF },
- { 0x04CB, 0x30D2 },
- { 0x04CC, 0x30D5 },
- { 0x04CD, 0x30D8 },
- { 0x04CE, 0x30DB },
- { 0x04CF, 0x30DE },
- { 0x04D0, 0x30DF },
- { 0x04D1, 0x30E0 },
- { 0x04D2, 0x30E1 },
- { 0x04D3, 0x30E2 },
- { 0x04D4, 0x30E4 },
- { 0x04D5, 0x30E6 },
- { 0x04D6, 0x30E8 },
- { 0x04D7, 0x30E9 },
- { 0x04D8, 0x30EA },
- { 0x04D9, 0x30EB },
- { 0x04DA, 0x30EC },
- { 0x04DB, 0x30ED },
- { 0x04DC, 0x30EF },
- { 0x04DD, 0x30F3 },
- { 0x04DE, 0x309B },
- { 0x04DF, 0x309C },
- { 0x05AC, 0x060C },
- { 0x05BB, 0x061B },
- { 0x05BF, 0x061F },
- { 0x05C1, 0x0621 },
- { 0x05C2, 0x0622 },
- { 0x05C3, 0x0623 },
- { 0x05C4, 0x0624 },
- { 0x05C5, 0x0625 },
- { 0x05C6, 0x0626 },
- { 0x05C7, 0x0627 },
- { 0x05C8, 0x0628 },
- { 0x05C9, 0x0629 },
- { 0x05CA, 0x062A },
- { 0x05CB, 0x062B },
- { 0x05CC, 0x062C },
- { 0x05CD, 0x062D },
- { 0x05CE, 0x062E },
- { 0x05CF, 0x062F },
- { 0x05D0, 0x0630 },
- { 0x05D1, 0x0631 },
- { 0x05D2, 0x0632 },
- { 0x05D3, 0x0633 },
- { 0x05D4, 0x0634 },
- { 0x05D5, 0x0635 },
- { 0x05D6, 0x0636 },
- { 0x05D7, 0x0637 },
- { 0x05D8, 0x0638 },
- { 0x05D9, 0x0639 },
- { 0x05DA, 0x063A },
- { 0x05E0, 0x0640 },
- { 0x05E1, 0x0641 },
- { 0x05E2, 0x0642 },
- { 0x05E3, 0x0643 },
- { 0x05E4, 0x0644 },
- { 0x05E5, 0x0645 },
- { 0x05E6, 0x0646 },
- { 0x05E7, 0x0647 },
- { 0x05E8, 0x0648 },
- { 0x05E9, 0x0649 },
- { 0x05EA, 0x064A },
- { 0x05EB, 0x064B },
- { 0x05EC, 0x064C },
- { 0x05ED, 0x064D },
- { 0x05EE, 0x064E },
- { 0x05EF, 0x064F },
- { 0x05F0, 0x0650 },
- { 0x05F1, 0x0651 },
- { 0x05F2, 0x0652 },
- { 0x06A1, 0x0452 },
- { 0x06A2, 0x0453 },
- { 0x06A3, 0x0451 },
- { 0x06A4, 0x0454 },
- { 0x06A5, 0x0455 },
- { 0x06A6, 0x0456 },
- { 0x06A7, 0x0457 },
- { 0x06A8, 0x0458 },
- { 0x06A9, 0x0459 },
- { 0x06AA, 0x045A },
- { 0x06AB, 0x045B },
- { 0x06AC, 0x045C },
- { 0x06AE, 0x045E },
- { 0x06AF, 0x045F },
- { 0x06B0, 0x2116 },
- { 0x06B1, 0x0402 },
- { 0x06B2, 0x0403 },
- { 0x06B3, 0x0401 },
- { 0x06B4, 0x0404 },
- { 0x06B5, 0x0405 },
- { 0x06B6, 0x0406 },
- { 0x06B7, 0x0407 },
- { 0x06B8, 0x0408 },
- { 0x06B9, 0x0409 },
- { 0x06BA, 0x040A },
- { 0x06BB, 0x040B },
- { 0x06BC, 0x040C },
- { 0x06BE, 0x040E },
- { 0x06BF, 0x040F },
- { 0x06C0, 0x044E },
- { 0x06C1, 0x0430 },
- { 0x06C2, 0x0431 },
- { 0x06C3, 0x0446 },
- { 0x06C4, 0x0434 },
- { 0x06C5, 0x0435 },
- { 0x06C6, 0x0444 },
- { 0x06C7, 0x0433 },
- { 0x06C8, 0x0445 },
- { 0x06C9, 0x0438 },
- { 0x06CA, 0x0439 },
- { 0x06CB, 0x043A },
- { 0x06CC, 0x043B },
- { 0x06CD, 0x043C },
- { 0x06CE, 0x043D },
- { 0x06CF, 0x043E },
- { 0x06D0, 0x043F },
- { 0x06D1, 0x044F },
- { 0x06D2, 0x0440 },
- { 0x06D3, 0x0441 },
- { 0x06D4, 0x0442 },
- { 0x06D5, 0x0443 },
- { 0x06D6, 0x0436 },
- { 0x06D7, 0x0432 },
- { 0x06D8, 0x044C },
- { 0x06D9, 0x044B },
- { 0x06DA, 0x0437 },
- { 0x06DB, 0x0448 },
- { 0x06DC, 0x044D },
- { 0x06DD, 0x0449 },
- { 0x06DE, 0x0447 },
- { 0x06DF, 0x044A },
- { 0x06E0, 0x042E },
- { 0x06E1, 0x0410 },
- { 0x06E2, 0x0411 },
- { 0x06E3, 0x0426 },
- { 0x06E4, 0x0414 },
- { 0x06E5, 0x0415 },
- { 0x06E6, 0x0424 },
- { 0x06E7, 0x0413 },
- { 0x06E8, 0x0425 },
- { 0x06E9, 0x0418 },
- { 0x06EA, 0x0419 },
- { 0x06EB, 0x041A },
- { 0x06EC, 0x041B },
- { 0x06ED, 0x041C },
- { 0x06EE, 0x041D },
- { 0x06EF, 0x041E },
- { 0x06F0, 0x041F },
- { 0x06F1, 0x042F },
- { 0x06F2, 0x0420 },
- { 0x06F3, 0x0421 },
- { 0x06F4, 0x0422 },
- { 0x06F5, 0x0423 },
- { 0x06F6, 0x0416 },
- { 0x06F7, 0x0412 },
- { 0x06F8, 0x042C },
- { 0x06F9, 0x042B },
- { 0x06FA, 0x0417 },
- { 0x06FB, 0x0428 },
- { 0x06FC, 0x042D },
- { 0x06FD, 0x0429 },
- { 0x06FE, 0x0427 },
- { 0x06FF, 0x042A },
- { 0x07A1, 0x0386 },
- { 0x07A2, 0x0388 },
- { 0x07A3, 0x0389 },
- { 0x07A4, 0x038A },
- { 0x07A5, 0x03AA },
- { 0x07A7, 0x038C },
- { 0x07A8, 0x038E },
- { 0x07A9, 0x03AB },
- { 0x07AB, 0x038F },
- { 0x07AE, 0x0385 },
- { 0x07AF, 0x2015 },
- { 0x07B1, 0x03AC },
- { 0x07B2, 0x03AD },
- { 0x07B3, 0x03AE },
- { 0x07B4, 0x03AF },
- { 0x07B5, 0x03CA },
- { 0x07B6, 0x0390 },
- { 0x07B7, 0x03CC },
- { 0x07B8, 0x03CD },
- { 0x07B9, 0x03CB },
- { 0x07BA, 0x03B0 },
- { 0x07BB, 0x03CE },
- { 0x07C1, 0x0391 },
- { 0x07C2, 0x0392 },
- { 0x07C3, 0x0393 },
- { 0x07C4, 0x0394 },
- { 0x07C5, 0x0395 },
- { 0x07C6, 0x0396 },
- { 0x07C7, 0x0397 },
- { 0x07C8, 0x0398 },
- { 0x07C9, 0x0399 },
- { 0x07CA, 0x039A },
- { 0x07CB, 0x039B },
- { 0x07CC, 0x039C },
- { 0x07CD, 0x039D },
- { 0x07CE, 0x039E },
- { 0x07CF, 0x039F },
- { 0x07D0, 0x03A0 },
- { 0x07D1, 0x03A1 },
- { 0x07D2, 0x03A3 },
- { 0x07D4, 0x03A4 },
- { 0x07D5, 0x03A5 },
- { 0x07D6, 0x03A6 },
- { 0x07D7, 0x03A7 },
- { 0x07D8, 0x03A8 },
- { 0x07D9, 0x03A9 },
- { 0x07E1, 0x03B1 },
- { 0x07E2, 0x03B2 },
- { 0x07E3, 0x03B3 },
- { 0x07E4, 0x03B4 },
- { 0x07E5, 0x03B5 },
- { 0x07E6, 0x03B6 },
- { 0x07E7, 0x03B7 },
- { 0x07E8, 0x03B8 },
- { 0x07E9, 0x03B9 },
- { 0x07EA, 0x03BA },
- { 0x07EB, 0x03BB },
- { 0x07EC, 0x03BC },
- { 0x07ED, 0x03BD },
- { 0x07EE, 0x03BE },
- { 0x07EF, 0x03BF },
- { 0x07F0, 0x03C0 },
- { 0x07F1, 0x03C1 },
- { 0x07F2, 0x03C3 },
- { 0x07F3, 0x03C2 },
- { 0x07F4, 0x03C4 },
- { 0x07F5, 0x03C5 },
- { 0x07F6, 0x03C6 },
- { 0x07F7, 0x03C7 },
- { 0x07F8, 0x03C8 },
- { 0x07F9, 0x03C9 },
- { 0x08A1, 0x23B7 },
- { 0x08A2, 0x250C },
- { 0x08A3, 0x2500 },
- { 0x08A4, 0x2320 },
- { 0x08A5, 0x2321 },
- { 0x08A6, 0x2502 },
- { 0x08A7, 0x23A1 },
- { 0x08A8, 0x23A3 },
- { 0x08A9, 0x23A4 },
- { 0x08AA, 0x23A6 },
- { 0x08AB, 0x239B },
- { 0x08AC, 0x239D },
- { 0x08AD, 0x239E },
- { 0x08AE, 0x23A0 },
- { 0x08AF, 0x23A8 },
- { 0x08B0, 0x23AC },
- { 0x08BC, 0x2264 },
- { 0x08BD, 0x2260 },
- { 0x08BE, 0x2265 },
- { 0x08BF, 0x222B },
- { 0x08C0, 0x2234 },
- { 0x08C1, 0x221D },
- { 0x08C2, 0x221E },
- { 0x08C5, 0x2207 },
- { 0x08C8, 0x223C },
- { 0x08C9, 0x2243 },
- { 0x08CD, 0x21D4 },
- { 0x08CE, 0x21D2 },
- { 0x08CF, 0x2261 },
- { 0x08D6, 0x221A },
- { 0x08DA, 0x2282 },
- { 0x08DB, 0x2283 },
- { 0x08DC, 0x2229 },
- { 0x08DD, 0x222A },
- { 0x08DE, 0x2227 },
- { 0x08DF, 0x2228 },
- { 0x08EF, 0x2202 },
- { 0x08F6, 0x0192 },
- { 0x08FB, 0x2190 },
- { 0x08FC, 0x2191 },
- { 0x08FD, 0x2192 },
- { 0x08FE, 0x2193 },
- { 0x09E0, 0x25C6 },
- { 0x09E1, 0x2592 },
- { 0x09E2, 0x2409 },
- { 0x09E3, 0x240C },
- { 0x09E4, 0x240D },
- { 0x09E5, 0x240A },
- { 0x09E8, 0x2424 },
- { 0x09E9, 0x240B },
- { 0x09EA, 0x2518 },
- { 0x09EB, 0x2510 },
- { 0x09EC, 0x250C },
- { 0x09ED, 0x2514 },
- { 0x09EE, 0x253C },
- { 0x09EF, 0x23BA },
- { 0x09F0, 0x23BB },
- { 0x09F1, 0x2500 },
- { 0x09F2, 0x23BC },
- { 0x09F3, 0x23BD },
- { 0x09F4, 0x251C },
- { 0x09F5, 0x2524 },
- { 0x09F6, 0x2534 },
- { 0x09F7, 0x252C },
- { 0x09F8, 0x2502 },
- { 0x0AA1, 0x2003 },
- { 0x0AA2, 0x2002 },
- { 0x0AA3, 0x2004 },
- { 0x0AA4, 0x2005 },
- { 0x0AA5, 0x2007 },
- { 0x0AA6, 0x2008 },
- { 0x0AA7, 0x2009 },
- { 0x0AA8, 0x200A },
- { 0x0AA9, 0x2014 },
- { 0x0AAA, 0x2013 },
- { 0x0AAE, 0x2026 },
- { 0x0AAF, 0x2025 },
- { 0x0AB0, 0x2153 },
- { 0x0AB1, 0x2154 },
- { 0x0AB2, 0x2155 },
- { 0x0AB3, 0x2156 },
- { 0x0AB4, 0x2157 },
- { 0x0AB5, 0x2158 },
- { 0x0AB6, 0x2159 },
- { 0x0AB7, 0x215A },
- { 0x0AB8, 0x2105 },
- { 0x0ABB, 0x2012 },
- { 0x0ABC, 0x2329 },
- { 0x0ABE, 0x232A },
- { 0x0AC3, 0x215B },
- { 0x0AC4, 0x215C },
- { 0x0AC5, 0x215D },
- { 0x0AC6, 0x215E },
- { 0x0AC9, 0x2122 },
- { 0x0ACA, 0x2613 },
- { 0x0ACC, 0x25C1 },
- { 0x0ACD, 0x25B7 },
- { 0x0ACE, 0x25CB },
- { 0x0ACF, 0x25AF },
- { 0x0AD0, 0x2018 },
- { 0x0AD1, 0x2019 },
- { 0x0AD2, 0x201C },
- { 0x0AD3, 0x201D },
- { 0x0AD4, 0x211E },
- { 0x0AD6, 0x2032 },
- { 0x0AD7, 0x2033 },
- { 0x0AD9, 0x271D },
- { 0x0ADB, 0x25AC },
- { 0x0ADC, 0x25C0 },
- { 0x0ADD, 0x25B6 },
- { 0x0ADE, 0x25CF },
- { 0x0ADF, 0x25AE },
- { 0x0AE0, 0x25E6 },
- { 0x0AE1, 0x25AB },
- { 0x0AE2, 0x25AD },
- { 0x0AE3, 0x25B3 },
- { 0x0AE4, 0x25BD },
- { 0x0AE5, 0x2606 },
- { 0x0AE6, 0x2022 },
- { 0x0AE7, 0x25AA },
- { 0x0AE8, 0x25B2 },
- { 0x0AE9, 0x25BC },
- { 0x0AEA, 0x261C },
- { 0x0AEB, 0x261E },
- { 0x0AEC, 0x2663 },
- { 0x0AED, 0x2666 },
- { 0x0AEE, 0x2665 },
- { 0x0AF0, 0x2720 },
- { 0x0AF1, 0x2020 },
- { 0x0AF2, 0x2021 },
- { 0x0AF3, 0x2713 },
- { 0x0AF4, 0x2717 },
- { 0x0AF5, 0x266F },
- { 0x0AF6, 0x266D },
- { 0x0AF7, 0x2642 },
- { 0x0AF8, 0x2640 },
- { 0x0AF9, 0x260E },
- { 0x0AFA, 0x2315 },
- { 0x0AFB, 0x2117 },
- { 0x0AFC, 0x2038 },
- { 0x0AFD, 0x201A },
- { 0x0AFE, 0x201E },
- { 0x0BA3, 0x003C },
- { 0x0BA6, 0x003E },
- { 0x0BA8, 0x2228 },
- { 0x0BA9, 0x2227 },
- { 0x0BC0, 0x00AF },
- { 0x0BC2, 0x22A5 },
- { 0x0BC3, 0x2229 },
- { 0x0BC4, 0x230A },
- { 0x0BC6, 0x005F },
- { 0x0BCA, 0x2218 },
- { 0x0BCC, 0x2395 },
- { 0x0BCE, 0x22A4 },
- { 0x0BCF, 0x25CB },
- { 0x0BD3, 0x2308 },
- { 0x0BD6, 0x222A },
- { 0x0BD8, 0x2283 },
- { 0x0BDA, 0x2282 },
- { 0x0BDC, 0x22A2 },
- { 0x0BFC, 0x22A3 },
- { 0x0CDF, 0x2017 },
- { 0x0CE0, 0x05D0 },
- { 0x0CE1, 0x05D1 },
- { 0x0CE2, 0x05D2 },
- { 0x0CE3, 0x05D3 },
- { 0x0CE4, 0x05D4 },
- { 0x0CE5, 0x05D5 },
- { 0x0CE6, 0x05D6 },
- { 0x0CE7, 0x05D7 },
- { 0x0CE8, 0x05D8 },
- { 0x0CE9, 0x05D9 },
- { 0x0CEA, 0x05DA },
- { 0x0CEB, 0x05DB },
- { 0x0CEC, 0x05DC },
- { 0x0CED, 0x05DD },
- { 0x0CEE, 0x05DE },
- { 0x0CEF, 0x05DF },
- { 0x0CF0, 0x05E0 },
- { 0x0CF1, 0x05E1 },
- { 0x0CF2, 0x05E2 },
- { 0x0CF3, 0x05E3 },
- { 0x0CF4, 0x05E4 },
- { 0x0CF5, 0x05E5 },
- { 0x0CF6, 0x05E6 },
- { 0x0CF7, 0x05E7 },
- { 0x0CF8, 0x05E8 },
- { 0x0CF9, 0x05E9 },
- { 0x0CFA, 0x05EA },
- { 0x0DA1, 0x0E01 },
- { 0x0DA2, 0x0E02 },
- { 0x0DA3, 0x0E03 },
- { 0x0DA4, 0x0E04 },
- { 0x0DA5, 0x0E05 },
- { 0x0DA6, 0x0E06 },
- { 0x0DA7, 0x0E07 },
- { 0x0DA8, 0x0E08 },
- { 0x0DA9, 0x0E09 },
- { 0x0DAA, 0x0E0A },
- { 0x0DAB, 0x0E0B },
- { 0x0DAC, 0x0E0C },
- { 0x0DAD, 0x0E0D },
- { 0x0DAE, 0x0E0E },
- { 0x0DAF, 0x0E0F },
- { 0x0DB0, 0x0E10 },
- { 0x0DB1, 0x0E11 },
- { 0x0DB2, 0x0E12 },
- { 0x0DB3, 0x0E13 },
- { 0x0DB4, 0x0E14 },
- { 0x0DB5, 0x0E15 },
- { 0x0DB6, 0x0E16 },
- { 0x0DB7, 0x0E17 },
- { 0x0DB8, 0x0E18 },
- { 0x0DB9, 0x0E19 },
- { 0x0DBA, 0x0E1A },
- { 0x0DBB, 0x0E1B },
- { 0x0DBC, 0x0E1C },
- { 0x0DBD, 0x0E1D },
- { 0x0DBE, 0x0E1E },
- { 0x0DBF, 0x0E1F },
- { 0x0DC0, 0x0E20 },
- { 0x0DC1, 0x0E21 },
- { 0x0DC2, 0x0E22 },
- { 0x0DC3, 0x0E23 },
- { 0x0DC4, 0x0E24 },
- { 0x0DC5, 0x0E25 },
- { 0x0DC6, 0x0E26 },
- { 0x0DC7, 0x0E27 },
- { 0x0DC8, 0x0E28 },
- { 0x0DC9, 0x0E29 },
- { 0x0DCA, 0x0E2A },
- { 0x0DCB, 0x0E2B },
- { 0x0DCC, 0x0E2C },
- { 0x0DCD, 0x0E2D },
- { 0x0DCE, 0x0E2E },
- { 0x0DCF, 0x0E2F },
- { 0x0DD0, 0x0E30 },
- { 0x0DD1, 0x0E31 },
- { 0x0DD2, 0x0E32 },
- { 0x0DD3, 0x0E33 },
- { 0x0DD4, 0x0E34 },
- { 0x0DD5, 0x0E35 },
- { 0x0DD6, 0x0E36 },
- { 0x0DD7, 0x0E37 },
- { 0x0DD8, 0x0E38 },
- { 0x0DD9, 0x0E39 },
- { 0x0DDA, 0x0E3A },
- { 0x0DDF, 0x0E3F },
- { 0x0DE0, 0x0E40 },
- { 0x0DE1, 0x0E41 },
- { 0x0DE2, 0x0E42 },
- { 0x0DE3, 0x0E43 },
- { 0x0DE4, 0x0E44 },
- { 0x0DE5, 0x0E45 },
- { 0x0DE6, 0x0E46 },
- { 0x0DE7, 0x0E47 },
- { 0x0DE8, 0x0E48 },
- { 0x0DE9, 0x0E49 },
- { 0x0DEA, 0x0E4A },
- { 0x0DEB, 0x0E4B },
- { 0x0DEC, 0x0E4C },
- { 0x0DED, 0x0E4D },
- { 0x0DF0, 0x0E50 },
- { 0x0DF1, 0x0E51 },
- { 0x0DF2, 0x0E52 },
- { 0x0DF3, 0x0E53 },
- { 0x0DF4, 0x0E54 },
- { 0x0DF5, 0x0E55 },
- { 0x0DF6, 0x0E56 },
- { 0x0DF7, 0x0E57 },
- { 0x0DF8, 0x0E58 },
- { 0x0DF9, 0x0E59 },
- { 0x0EA1, 0x3131 },
- { 0x0EA2, 0x3132 },
- { 0x0EA3, 0x3133 },
- { 0x0EA4, 0x3134 },
- { 0x0EA5, 0x3135 },
- { 0x0EA6, 0x3136 },
- { 0x0EA7, 0x3137 },
- { 0x0EA8, 0x3138 },
- { 0x0EA9, 0x3139 },
- { 0x0EAA, 0x313A },
- { 0x0EAB, 0x313B },
- { 0x0EAC, 0x313C },
- { 0x0EAD, 0x313D },
- { 0x0EAE, 0x313E },
- { 0x0EAF, 0x313F },
- { 0x0EB0, 0x3140 },
- { 0x0EB1, 0x3141 },
- { 0x0EB2, 0x3142 },
- { 0x0EB3, 0x3143 },
- { 0x0EB4, 0x3144 },
- { 0x0EB5, 0x3145 },
- { 0x0EB6, 0x3146 },
- { 0x0EB7, 0x3147 },
- { 0x0EB8, 0x3148 },
- { 0x0EB9, 0x3149 },
- { 0x0EBA, 0x314A },
- { 0x0EBB, 0x314B },
- { 0x0EBC, 0x314C },
- { 0x0EBD, 0x314D },
- { 0x0EBE, 0x314E },
- { 0x0EBF, 0x314F },
- { 0x0EC0, 0x3150 },
- { 0x0EC1, 0x3151 },
- { 0x0EC2, 0x3152 },
- { 0x0EC3, 0x3153 },
- { 0x0EC4, 0x3154 },
- { 0x0EC5, 0x3155 },
- { 0x0EC6, 0x3156 },
- { 0x0EC7, 0x3157 },
- { 0x0EC8, 0x3158 },
- { 0x0EC9, 0x3159 },
- { 0x0ECA, 0x315A },
- { 0x0ECB, 0x315B },
- { 0x0ECC, 0x315C },
- { 0x0ECD, 0x315D },
- { 0x0ECE, 0x315E },
- { 0x0ECF, 0x315F },
- { 0x0ED0, 0x3160 },
- { 0x0ED1, 0x3161 },
- { 0x0ED2, 0x3162 },
- { 0x0ED3, 0x3163 },
- { 0x0ED4, 0x11A8 },
- { 0x0ED5, 0x11A9 },
- { 0x0ED6, 0x11AA },
- { 0x0ED7, 0x11AB },
- { 0x0ED8, 0x11AC },
- { 0x0ED9, 0x11AD },
- { 0x0EDA, 0x11AE },
- { 0x0EDB, 0x11AF },
- { 0x0EDC, 0x11B0 },
- { 0x0EDD, 0x11B1 },
- { 0x0EDE, 0x11B2 },
- { 0x0EDF, 0x11B3 },
- { 0x0EE0, 0x11B4 },
- { 0x0EE1, 0x11B5 },
- { 0x0EE2, 0x11B6 },
- { 0x0EE3, 0x11B7 },
- { 0x0EE4, 0x11B8 },
- { 0x0EE5, 0x11B9 },
- { 0x0EE6, 0x11BA },
- { 0x0EE7, 0x11BB },
- { 0x0EE8, 0x11BC },
- { 0x0EE9, 0x11BD },
- { 0x0EEA, 0x11BE },
- { 0x0EEB, 0x11BF },
- { 0x0EEC, 0x11C0 },
- { 0x0EED, 0x11C1 },
- { 0x0EEE, 0x11C2 },
- { 0x0EEF, 0x316D },
- { 0x0EF0, 0x3171 },
- { 0x0EF1, 0x3178 },
- { 0x0EF2, 0x317F },
- { 0x0EF3, 0x3181 },
- { 0x0EF4, 0x3184 },
- { 0x0EF5, 0x3186 },
- { 0x0EF6, 0x318D },
- { 0x0EF7, 0x318E },
- { 0x0EF8, 0x11EB },
- { 0x0EF9, 0x11F0 },
- { 0x0EFA, 0x11F9 },
- { 0x0EFF, 0x20A9 },
- { 0x13A4, 0x20AC },
- { 0x13BC, 0x0152 },
- { 0x13BD, 0x0153 },
- { 0x13BE, 0x0178 },
- { 0x20AC, 0x20AC },
-};
-
-unsigned int KeyMappingX11::get_unicode_from_keysym(KeySym p_keysym) {
- /* Latin-1 */
- if (p_keysym >= 0x20 && p_keysym <= 0x7e) {
- return p_keysym;
- }
- if (p_keysym >= 0xa0 && p_keysym <= 0xff) {
- return p_keysym;
- }
- // keypad to latin1 is easy
- if (p_keysym >= 0xffaa && p_keysym <= 0xffb9) {
- return p_keysym - 0xff80;
- }
-
- /* Unicode (may be present)*/
-
- if ((p_keysym & 0xff000000) == 0x01000000) {
- return p_keysym & 0x00ffffff;
- }
-
- int middle, low = 0, high = _KEYSYM_MAX - 1;
- do {
- middle = (high + low) / 2;
- if (_xkeysym_to_unicode[middle].keysym == p_keysym) {
- return _xkeysym_to_unicode[middle].unicode;
- }
- if (_xkeysym_to_unicode[middle].keysym <= p_keysym) {
- low = middle + 1;
- } else {
- high = middle - 1;
- }
- } while (high >= low);
-
- return 0;
-}
-
-struct _XTranslateUnicodePairReverse {
- unsigned int unicode;
- KeySym keysym;
-};
-
-enum {
- _UNICODE_MAX = 750
-};
-
-static _XTranslateUnicodePairReverse _unicode_to_xkeysym[_UNICODE_MAX] = {
- { 0x0ABD, 0x002E },
- { 0x0BA3, 0x003C },
- { 0x0BA6, 0x003E },
- { 0x0BC6, 0x005F },
- { 0x0BC0, 0x00AF },
- { 0x03C0, 0x0100 },
- { 0x03E0, 0x0101 },
- { 0x01C3, 0x0102 },
- { 0x01E3, 0x0103 },
- { 0x01A1, 0x0104 },
- { 0x01B1, 0x0105 },
- { 0x01C6, 0x0106 },
- { 0x01E6, 0x0107 },
- { 0x02C6, 0x0108 },
- { 0x02E6, 0x0109 },
- { 0x02C5, 0x010A },
- { 0x02E5, 0x010B },
- { 0x01C8, 0x010C },
- { 0x01E8, 0x010D },
- { 0x01CF, 0x010E },
- { 0x01EF, 0x010F },
- { 0x01D0, 0x0110 },
- { 0x01F0, 0x0111 },
- { 0x03AA, 0x0112 },
- { 0x03BA, 0x0113 },
- { 0x03CC, 0x0116 },
- { 0x03EC, 0x0117 },
- { 0x01CA, 0x0118 },
- { 0x01EA, 0x0119 },
- { 0x01CC, 0x011A },
- { 0x01EC, 0x011B },
- { 0x02D8, 0x011C },
- { 0x02F8, 0x011D },
- { 0x02AB, 0x011E },
- { 0x02BB, 0x011F },
- { 0x02D5, 0x0120 },
- { 0x02F5, 0x0121 },
- { 0x03AB, 0x0122 },
- { 0x03BB, 0x0123 },
- { 0x02A6, 0x0124 },
- { 0x02B6, 0x0125 },
- { 0x02A1, 0x0126 },
- { 0x02B1, 0x0127 },
- { 0x03A5, 0x0128 },
- { 0x03B5, 0x0129 },
- { 0x03CF, 0x012A },
- { 0x03EF, 0x012B },
- { 0x03C7, 0x012E },
- { 0x03E7, 0x012F },
- { 0x02A9, 0x0130 },
- { 0x02B9, 0x0131 },
- { 0x02AC, 0x0134 },
- { 0x02BC, 0x0135 },
- { 0x03D3, 0x0136 },
- { 0x03F3, 0x0137 },
- { 0x03A2, 0x0138 },
- { 0x01C5, 0x0139 },
- { 0x01E5, 0x013A },
- { 0x03A6, 0x013B },
- { 0x03B6, 0x013C },
- { 0x01A5, 0x013D },
- { 0x01B5, 0x013E },
- { 0x01A3, 0x0141 },
- { 0x01B3, 0x0142 },
- { 0x01D1, 0x0143 },
- { 0x01F1, 0x0144 },
- { 0x03D1, 0x0145 },
- { 0x03F1, 0x0146 },
- { 0x01D2, 0x0147 },
- { 0x01F2, 0x0148 },
- { 0x03BD, 0x014A },
- { 0x03BF, 0x014B },
- { 0x03D2, 0x014C },
- { 0x03F2, 0x014D },
- { 0x01D5, 0x0150 },
- { 0x01F5, 0x0151 },
- { 0x13BC, 0x0152 },
- { 0x13BD, 0x0153 },
- { 0x01C0, 0x0154 },
- { 0x01E0, 0x0155 },
- { 0x03A3, 0x0156 },
- { 0x03B3, 0x0157 },
- { 0x01D8, 0x0158 },
- { 0x01F8, 0x0159 },
- { 0x01A6, 0x015A },
- { 0x01B6, 0x015B },
- { 0x02DE, 0x015C },
- { 0x02FE, 0x015D },
- { 0x01AA, 0x015E },
- { 0x01BA, 0x015F },
- { 0x01A9, 0x0160 },
- { 0x01B9, 0x0161 },
- { 0x01DE, 0x0162 },
- { 0x01FE, 0x0163 },
- { 0x01AB, 0x0164 },
- { 0x01BB, 0x0165 },
- { 0x03AC, 0x0166 },
- { 0x03BC, 0x0167 },
- { 0x03DD, 0x0168 },
- { 0x03FD, 0x0169 },
- { 0x03DE, 0x016A },
- { 0x03FE, 0x016B },
- { 0x02DD, 0x016C },
- { 0x02FD, 0x016D },
- { 0x01D9, 0x016E },
- { 0x01F9, 0x016F },
- { 0x01DB, 0x0170 },
- { 0x01FB, 0x0171 },
- { 0x03D9, 0x0172 },
- { 0x03F9, 0x0173 },
- { 0x13BE, 0x0178 },
- { 0x01AC, 0x0179 },
- { 0x01BC, 0x017A },
- { 0x01AF, 0x017B },
- { 0x01BF, 0x017C },
- { 0x01AE, 0x017D },
- { 0x01BE, 0x017E },
- { 0x08F6, 0x0192 },
- { 0x01B7, 0x02C7 },
- { 0x01A2, 0x02D8 },
- { 0x01FF, 0x02D9 },
- { 0x01B2, 0x02DB },
- { 0x01BD, 0x02DD },
- { 0x07AE, 0x0385 },
- { 0x07A1, 0x0386 },
- { 0x07A2, 0x0388 },
- { 0x07A3, 0x0389 },
- { 0x07A4, 0x038A },
- { 0x07A7, 0x038C },
- { 0x07A8, 0x038E },
- { 0x07AB, 0x038F },
- { 0x07B6, 0x0390 },
- { 0x07C1, 0x0391 },
- { 0x07C2, 0x0392 },
- { 0x07C3, 0x0393 },
- { 0x07C4, 0x0394 },
- { 0x07C5, 0x0395 },
- { 0x07C6, 0x0396 },
- { 0x07C7, 0x0397 },
- { 0x07C8, 0x0398 },
- { 0x07C9, 0x0399 },
- { 0x07CA, 0x039A },
- { 0x07CB, 0x039B },
- { 0x07CC, 0x039C },
- { 0x07CD, 0x039D },
- { 0x07CE, 0x039E },
- { 0x07CF, 0x039F },
- { 0x07D0, 0x03A0 },
- { 0x07D1, 0x03A1 },
- { 0x07D2, 0x03A3 },
- { 0x07D4, 0x03A4 },
- { 0x07D5, 0x03A5 },
- { 0x07D6, 0x03A6 },
- { 0x07D7, 0x03A7 },
- { 0x07D8, 0x03A8 },
- { 0x07D9, 0x03A9 },
- { 0x07A5, 0x03AA },
- { 0x07A9, 0x03AB },
- { 0x07B1, 0x03AC },
- { 0x07B2, 0x03AD },
- { 0x07B3, 0x03AE },
- { 0x07B4, 0x03AF },
- { 0x07BA, 0x03B0 },
- { 0x07E1, 0x03B1 },
- { 0x07E2, 0x03B2 },
- { 0x07E3, 0x03B3 },
- { 0x07E4, 0x03B4 },
- { 0x07E5, 0x03B5 },
- { 0x07E6, 0x03B6 },
- { 0x07E7, 0x03B7 },
- { 0x07E8, 0x03B8 },
- { 0x07E9, 0x03B9 },
- { 0x07EA, 0x03BA },
- { 0x07EB, 0x03BB },
- { 0x07EC, 0x03BC },
- { 0x07ED, 0x03BD },
- { 0x07EE, 0x03BE },
- { 0x07EF, 0x03BF },
- { 0x07F0, 0x03C0 },
- { 0x07F1, 0x03C1 },
- { 0x07F3, 0x03C2 },
- { 0x07F2, 0x03C3 },
- { 0x07F4, 0x03C4 },
- { 0x07F5, 0x03C5 },
- { 0x07F6, 0x03C6 },
- { 0x07F7, 0x03C7 },
- { 0x07F8, 0x03C8 },
- { 0x07F9, 0x03C9 },
- { 0x07B5, 0x03CA },
- { 0x07B9, 0x03CB },
- { 0x07B7, 0x03CC },
- { 0x07B8, 0x03CD },
- { 0x07BB, 0x03CE },
- { 0x06B3, 0x0401 },
- { 0x06B1, 0x0402 },
- { 0x06B2, 0x0403 },
- { 0x06B4, 0x0404 },
- { 0x06B5, 0x0405 },
- { 0x06B6, 0x0406 },
- { 0x06B7, 0x0407 },
- { 0x06B8, 0x0408 },
- { 0x06B9, 0x0409 },
- { 0x06BA, 0x040A },
- { 0x06BB, 0x040B },
- { 0x06BC, 0x040C },
- { 0x06BE, 0x040E },
- { 0x06BF, 0x040F },
- { 0x06E1, 0x0410 },
- { 0x06E2, 0x0411 },
- { 0x06F7, 0x0412 },
- { 0x06E7, 0x0413 },
- { 0x06E4, 0x0414 },
- { 0x06E5, 0x0415 },
- { 0x06F6, 0x0416 },
- { 0x06FA, 0x0417 },
- { 0x06E9, 0x0418 },
- { 0x06EA, 0x0419 },
- { 0x06EB, 0x041A },
- { 0x06EC, 0x041B },
- { 0x06ED, 0x041C },
- { 0x06EE, 0x041D },
- { 0x06EF, 0x041E },
- { 0x06F0, 0x041F },
- { 0x06F2, 0x0420 },
- { 0x06F3, 0x0421 },
- { 0x06F4, 0x0422 },
- { 0x06F5, 0x0423 },
- { 0x06E6, 0x0424 },
- { 0x06E8, 0x0425 },
- { 0x06E3, 0x0426 },
- { 0x06FE, 0x0427 },
- { 0x06FB, 0x0428 },
- { 0x06FD, 0x0429 },
- { 0x06FF, 0x042A },
- { 0x06F9, 0x042B },
- { 0x06F8, 0x042C },
- { 0x06FC, 0x042D },
- { 0x06E0, 0x042E },
- { 0x06F1, 0x042F },
- { 0x06C1, 0x0430 },
- { 0x06C2, 0x0431 },
- { 0x06D7, 0x0432 },
- { 0x06C7, 0x0433 },
- { 0x06C4, 0x0434 },
- { 0x06C5, 0x0435 },
- { 0x06D6, 0x0436 },
- { 0x06DA, 0x0437 },
- { 0x06C9, 0x0438 },
- { 0x06CA, 0x0439 },
- { 0x06CB, 0x043A },
- { 0x06CC, 0x043B },
- { 0x06CD, 0x043C },
- { 0x06CE, 0x043D },
- { 0x06CF, 0x043E },
- { 0x06D0, 0x043F },
- { 0x06D2, 0x0440 },
- { 0x06D3, 0x0441 },
- { 0x06D4, 0x0442 },
- { 0x06D5, 0x0443 },
- { 0x06C6, 0x0444 },
- { 0x06C8, 0x0445 },
- { 0x06C3, 0x0446 },
- { 0x06DE, 0x0447 },
- { 0x06DB, 0x0448 },
- { 0x06DD, 0x0449 },
- { 0x06DF, 0x044A },
- { 0x06D9, 0x044B },
- { 0x06D8, 0x044C },
- { 0x06DC, 0x044D },
- { 0x06C0, 0x044E },
- { 0x06D1, 0x044F },
- { 0x06A3, 0x0451 },
- { 0x06A1, 0x0452 },
- { 0x06A2, 0x0453 },
- { 0x06A4, 0x0454 },
- { 0x06A5, 0x0455 },
- { 0x06A6, 0x0456 },
- { 0x06A7, 0x0457 },
- { 0x06A8, 0x0458 },
- { 0x06A9, 0x0459 },
- { 0x06AA, 0x045A },
- { 0x06AB, 0x045B },
- { 0x06AC, 0x045C },
- { 0x06AE, 0x045E },
- { 0x06AF, 0x045F },
- { 0x0CE0, 0x05D0 },
- { 0x0CE1, 0x05D1 },
- { 0x0CE2, 0x05D2 },
- { 0x0CE3, 0x05D3 },
- { 0x0CE4, 0x05D4 },
- { 0x0CE5, 0x05D5 },
- { 0x0CE6, 0x05D6 },
- { 0x0CE7, 0x05D7 },
- { 0x0CE8, 0x05D8 },
- { 0x0CE9, 0x05D9 },
- { 0x0CEA, 0x05DA },
- { 0x0CEB, 0x05DB },
- { 0x0CEC, 0x05DC },
- { 0x0CED, 0x05DD },
- { 0x0CEE, 0x05DE },
- { 0x0CEF, 0x05DF },
- { 0x0CF0, 0x05E0 },
- { 0x0CF1, 0x05E1 },
- { 0x0CF2, 0x05E2 },
- { 0x0CF3, 0x05E3 },
- { 0x0CF4, 0x05E4 },
- { 0x0CF5, 0x05E5 },
- { 0x0CF6, 0x05E6 },
- { 0x0CF7, 0x05E7 },
- { 0x0CF8, 0x05E8 },
- { 0x0CF9, 0x05E9 },
- { 0x0CFA, 0x05EA },
- { 0x05AC, 0x060C },
- { 0x05BB, 0x061B },
- { 0x05BF, 0x061F },
- { 0x05C1, 0x0621 },
- { 0x05C2, 0x0622 },
- { 0x05C3, 0x0623 },
- { 0x05C4, 0x0624 },
- { 0x05C5, 0x0625 },
- { 0x05C6, 0x0626 },
- { 0x05C7, 0x0627 },
- { 0x05C8, 0x0628 },
- { 0x05C9, 0x0629 },
- { 0x05CA, 0x062A },
- { 0x05CB, 0x062B },
- { 0x05CC, 0x062C },
- { 0x05CD, 0x062D },
- { 0x05CE, 0x062E },
- { 0x05CF, 0x062F },
- { 0x05D0, 0x0630 },
- { 0x05D1, 0x0631 },
- { 0x05D2, 0x0632 },
- { 0x05D3, 0x0633 },
- { 0x05D4, 0x0634 },
- { 0x05D5, 0x0635 },
- { 0x05D6, 0x0636 },
- { 0x05D7, 0x0637 },
- { 0x05D8, 0x0638 },
- { 0x05D9, 0x0639 },
- { 0x05DA, 0x063A },
- { 0x05E0, 0x0640 },
- { 0x05E1, 0x0641 },
- { 0x05E2, 0x0642 },
- { 0x05E3, 0x0643 },
- { 0x05E4, 0x0644 },
- { 0x05E5, 0x0645 },
- { 0x05E6, 0x0646 },
- { 0x05E7, 0x0647 },
- { 0x05E8, 0x0648 },
- { 0x05E9, 0x0649 },
- { 0x05EA, 0x064A },
- { 0x05EB, 0x064B },
- { 0x05EC, 0x064C },
- { 0x05ED, 0x064D },
- { 0x05EE, 0x064E },
- { 0x05EF, 0x064F },
- { 0x05F0, 0x0650 },
- { 0x05F1, 0x0651 },
- { 0x05F2, 0x0652 },
- { 0x0DA1, 0x0E01 },
- { 0x0DA2, 0x0E02 },
- { 0x0DA3, 0x0E03 },
- { 0x0DA4, 0x0E04 },
- { 0x0DA5, 0x0E05 },
- { 0x0DA6, 0x0E06 },
- { 0x0DA7, 0x0E07 },
- { 0x0DA8, 0x0E08 },
- { 0x0DA9, 0x0E09 },
- { 0x0DAA, 0x0E0A },
- { 0x0DAB, 0x0E0B },
- { 0x0DAC, 0x0E0C },
- { 0x0DAD, 0x0E0D },
- { 0x0DAE, 0x0E0E },
- { 0x0DAF, 0x0E0F },
- { 0x0DB0, 0x0E10 },
- { 0x0DB1, 0x0E11 },
- { 0x0DB2, 0x0E12 },
- { 0x0DB3, 0x0E13 },
- { 0x0DB4, 0x0E14 },
- { 0x0DB5, 0x0E15 },
- { 0x0DB6, 0x0E16 },
- { 0x0DB7, 0x0E17 },
- { 0x0DB8, 0x0E18 },
- { 0x0DB9, 0x0E19 },
- { 0x0DBA, 0x0E1A },
- { 0x0DBB, 0x0E1B },
- { 0x0DBC, 0x0E1C },
- { 0x0DBD, 0x0E1D },
- { 0x0DBE, 0x0E1E },
- { 0x0DBF, 0x0E1F },
- { 0x0DC0, 0x0E20 },
- { 0x0DC1, 0x0E21 },
- { 0x0DC2, 0x0E22 },
- { 0x0DC3, 0x0E23 },
- { 0x0DC4, 0x0E24 },
- { 0x0DC5, 0x0E25 },
- { 0x0DC6, 0x0E26 },
- { 0x0DC7, 0x0E27 },
- { 0x0DC8, 0x0E28 },
- { 0x0DC9, 0x0E29 },
- { 0x0DCA, 0x0E2A },
- { 0x0DCB, 0x0E2B },
- { 0x0DCC, 0x0E2C },
- { 0x0DCD, 0x0E2D },
- { 0x0DCE, 0x0E2E },
- { 0x0DCF, 0x0E2F },
- { 0x0DD0, 0x0E30 },
- { 0x0DD1, 0x0E31 },
- { 0x0DD2, 0x0E32 },
- { 0x0DD3, 0x0E33 },
- { 0x0DD4, 0x0E34 },
- { 0x0DD5, 0x0E35 },
- { 0x0DD6, 0x0E36 },
- { 0x0DD7, 0x0E37 },
- { 0x0DD8, 0x0E38 },
- { 0x0DD9, 0x0E39 },
- { 0x0DDA, 0x0E3A },
- { 0x0DDF, 0x0E3F },
- { 0x0DE0, 0x0E40 },
- { 0x0DE1, 0x0E41 },
- { 0x0DE2, 0x0E42 },
- { 0x0DE3, 0x0E43 },
- { 0x0DE4, 0x0E44 },
- { 0x0DE5, 0x0E45 },
- { 0x0DE6, 0x0E46 },
- { 0x0DE7, 0x0E47 },
- { 0x0DE8, 0x0E48 },
- { 0x0DE9, 0x0E49 },
- { 0x0DEA, 0x0E4A },
- { 0x0DEB, 0x0E4B },
- { 0x0DEC, 0x0E4C },
- { 0x0DED, 0x0E4D },
- { 0x0DF0, 0x0E50 },
- { 0x0DF1, 0x0E51 },
- { 0x0DF2, 0x0E52 },
- { 0x0DF3, 0x0E53 },
- { 0x0DF4, 0x0E54 },
- { 0x0DF5, 0x0E55 },
- { 0x0DF6, 0x0E56 },
- { 0x0DF7, 0x0E57 },
- { 0x0DF8, 0x0E58 },
- { 0x0DF9, 0x0E59 },
- { 0x0ED4, 0x11A8 },
- { 0x0ED5, 0x11A9 },
- { 0x0ED6, 0x11AA },
- { 0x0ED7, 0x11AB },
- { 0x0ED8, 0x11AC },
- { 0x0ED9, 0x11AD },
- { 0x0EDA, 0x11AE },
- { 0x0EDB, 0x11AF },
- { 0x0EDC, 0x11B0 },
- { 0x0EDD, 0x11B1 },
- { 0x0EDE, 0x11B2 },
- { 0x0EDF, 0x11B3 },
- { 0x0EE0, 0x11B4 },
- { 0x0EE1, 0x11B5 },
- { 0x0EE2, 0x11B6 },
- { 0x0EE3, 0x11B7 },
- { 0x0EE4, 0x11B8 },
- { 0x0EE5, 0x11B9 },
- { 0x0EE6, 0x11BA },
- { 0x0EE7, 0x11BB },
- { 0x0EE8, 0x11BC },
- { 0x0EE9, 0x11BD },
- { 0x0EEA, 0x11BE },
- { 0x0EEB, 0x11BF },
- { 0x0EEC, 0x11C0 },
- { 0x0EED, 0x11C1 },
- { 0x0EEE, 0x11C2 },
- { 0x0EF8, 0x11EB },
- { 0x0EFA, 0x11F9 },
- { 0x0AA2, 0x2002 },
- { 0x0AA1, 0x2003 },
- { 0x0AA3, 0x2004 },
- { 0x0AA4, 0x2005 },
- { 0x0AA5, 0x2007 },
- { 0x0AA6, 0x2008 },
- { 0x0AA7, 0x2009 },
- { 0x0AA8, 0x200A },
- { 0x0ABB, 0x2012 },
- { 0x0AAA, 0x2013 },
- { 0x0AA9, 0x2014 },
- { 0x07AF, 0x2015 },
- { 0x0CDF, 0x2017 },
- { 0x0AD0, 0x2018 },
- { 0x0AD1, 0x2019 },
- { 0x0AFD, 0x201A },
- { 0x0AD2, 0x201C },
- { 0x0AD3, 0x201D },
- { 0x0AFE, 0x201E },
- { 0x0AF1, 0x2020 },
- { 0x0AF2, 0x2021 },
- { 0x0AE6, 0x2022 },
- { 0x0AAE, 0x2026 },
- { 0x0AD6, 0x2032 },
- { 0x0AD7, 0x2033 },
- { 0x0AFC, 0x2038 },
- { 0x047E, 0x203E },
- { 0x20A0, 0x20A0 },
- { 0x20A1, 0x20A1 },
- { 0x20A2, 0x20A2 },
- { 0x20A3, 0x20A3 },
- { 0x20A4, 0x20A4 },
- { 0x20A5, 0x20A5 },
- { 0x20A6, 0x20A6 },
- { 0x20A7, 0x20A7 },
- { 0x20A8, 0x20A8 },
- { 0x0EFF, 0x20A9 },
- { 0x20A9, 0x20A9 },
- { 0x20AA, 0x20AA },
- { 0x20AB, 0x20AB },
- { 0x20AC, 0x20AC },
- { 0x0AB8, 0x2105 },
- { 0x06B0, 0x2116 },
- { 0x0AFB, 0x2117 },
- { 0x0AD4, 0x211E },
- { 0x0AC9, 0x2122 },
- { 0x0AB0, 0x2153 },
- { 0x0AB1, 0x2154 },
- { 0x0AB2, 0x2155 },
- { 0x0AB3, 0x2156 },
- { 0x0AB4, 0x2157 },
- { 0x0AB5, 0x2158 },
- { 0x0AB6, 0x2159 },
- { 0x0AB7, 0x215A },
- { 0x0AC3, 0x215B },
- { 0x0AC4, 0x215C },
- { 0x0AC5, 0x215D },
- { 0x0AC6, 0x215E },
- { 0x08FB, 0x2190 },
- { 0x08FC, 0x2191 },
- { 0x08FD, 0x2192 },
- { 0x08FE, 0x2193 },
- { 0x08CE, 0x21D2 },
- { 0x08CD, 0x21D4 },
- { 0x08EF, 0x2202 },
- { 0x08C5, 0x2207 },
- { 0x0BCA, 0x2218 },
- { 0x08D6, 0x221A },
- { 0x08C1, 0x221D },
- { 0x08C2, 0x221E },
- { 0x08DE, 0x2227 },
- { 0x0BA9, 0x2227 },
- { 0x08DF, 0x2228 },
- { 0x0BA8, 0x2228 },
- { 0x08DC, 0x2229 },
- { 0x0BC3, 0x2229 },
- { 0x08DD, 0x222A },
- { 0x0BD6, 0x222A },
- { 0x08BF, 0x222B },
- { 0x08C0, 0x2234 },
- { 0x08C8, 0x2245 },
- { 0x08BD, 0x2260 },
- { 0x08CF, 0x2261 },
- { 0x08BC, 0x2264 },
- { 0x08BE, 0x2265 },
- { 0x08DA, 0x2282 },
- { 0x0BDA, 0x2282 },
- { 0x08DB, 0x2283 },
- { 0x0BD8, 0x2283 },
- { 0x0BFC, 0x22A2 },
- { 0x0BDC, 0x22A3 },
- { 0x0BC2, 0x22A4 },
- { 0x0BCE, 0x22A5 },
- { 0x0BD3, 0x2308 },
- { 0x0BC4, 0x230A },
- { 0x0AFA, 0x2315 },
- { 0x08A4, 0x2320 },
- { 0x08A5, 0x2321 },
- { 0x0ABC, 0x2329 },
- { 0x0ABE, 0x232A },
- { 0x0BCC, 0x2395 },
- { 0x09E2, 0x2409 },
- { 0x09E5, 0x240A },
- { 0x09E9, 0x240B },
- { 0x09E3, 0x240C },
- { 0x09E4, 0x240D },
- { 0x09DF, 0x2422 },
- { 0x09E8, 0x2424 },
- { 0x09F1, 0x2500 },
- { 0x08A6, 0x2502 },
- { 0x09F8, 0x2502 },
- { 0x09EC, 0x250C },
- { 0x09EB, 0x2510 },
- { 0x09ED, 0x2514 },
- { 0x09EA, 0x2518 },
- { 0x09F4, 0x251C },
- { 0x09F5, 0x2524 },
- { 0x09F7, 0x252C },
- { 0x09F6, 0x2534 },
- { 0x09EE, 0x253C },
- { 0x09E1, 0x2592 },
- { 0x0ADF, 0x25A0 },
- { 0x0ACF, 0x25A1 },
- { 0x0AE7, 0x25AA },
- { 0x0AE1, 0x25AB },
- { 0x0ADB, 0x25AC },
- { 0x0AE2, 0x25AD },
- { 0x0AE8, 0x25B2 },
- { 0x0AE3, 0x25B3 },
- { 0x0ADD, 0x25B6 },
- { 0x0ACD, 0x25B7 },
- { 0x0AE9, 0x25BC },
- { 0x0AE4, 0x25BD },
- { 0x0ADC, 0x25C0 },
- { 0x0ACC, 0x25C1 },
- { 0x09E0, 0x25C6 },
- { 0x0ACE, 0x25CB },
- { 0x0BCF, 0x25CB },
- { 0x0ADE, 0x25CF },
- { 0x0AE0, 0x25E6 },
- { 0x0AE5, 0x2606 },
- { 0x0AF9, 0x260E },
- { 0x0ACA, 0x2613 },
- { 0x0AEA, 0x261C },
- { 0x0AEB, 0x261E },
- { 0x0AF8, 0x2640 },
- { 0x0AF7, 0x2642 },
- { 0x0AEC, 0x2663 },
- { 0x0AEE, 0x2665 },
- { 0x0AED, 0x2666 },
- { 0x0AF6, 0x266D },
- { 0x0AF5, 0x266F },
- { 0x0AF3, 0x2713 },
- { 0x0AF4, 0x2717 },
- { 0x0AD9, 0x271D },
- { 0x0AF0, 0x2720 },
- { 0x04A4, 0x3001 },
- { 0x04A1, 0x3002 },
- { 0x04A2, 0x300C },
- { 0x04A3, 0x300D },
- { 0x04DE, 0x309B },
- { 0x04DF, 0x309C },
- { 0x04A7, 0x30A1 },
- { 0x04B1, 0x30A2 },
- { 0x04A8, 0x30A3 },
- { 0x04B2, 0x30A4 },
- { 0x04A9, 0x30A5 },
- { 0x04B3, 0x30A6 },
- { 0x04AA, 0x30A7 },
- { 0x04B4, 0x30A8 },
- { 0x04AB, 0x30A9 },
- { 0x04B5, 0x30AA },
- { 0x04B6, 0x30AB },
- { 0x04B7, 0x30AD },
- { 0x04B8, 0x30AF },
- { 0x04B9, 0x30B1 },
- { 0x04BA, 0x30B3 },
- { 0x04BB, 0x30B5 },
- { 0x04BC, 0x30B7 },
- { 0x04BD, 0x30B9 },
- { 0x04BE, 0x30BB },
- { 0x04BF, 0x30BD },
- { 0x04C0, 0x30BF },
- { 0x04C1, 0x30C1 },
- { 0x04AF, 0x30C3 },
- { 0x04C2, 0x30C4 },
- { 0x04C3, 0x30C6 },
- { 0x04C4, 0x30C8 },
- { 0x04C5, 0x30CA },
- { 0x04C6, 0x30CB },
- { 0x04C7, 0x30CC },
- { 0x04C8, 0x30CD },
- { 0x04C9, 0x30CE },
- { 0x04CA, 0x30CF },
- { 0x04CB, 0x30D2 },
- { 0x04CC, 0x30D5 },
- { 0x04CD, 0x30D8 },
- { 0x04CE, 0x30DB },
- { 0x04CF, 0x30DE },
- { 0x04D0, 0x30DF },
- { 0x04D1, 0x30E0 },
- { 0x04D2, 0x30E1 },
- { 0x04D3, 0x30E2 },
- { 0x04AC, 0x30E3 },
- { 0x04D4, 0x30E4 },
- { 0x04AD, 0x30E5 },
- { 0x04D5, 0x30E6 },
- { 0x04AE, 0x30E7 },
- { 0x04D6, 0x30E8 },
- { 0x04D7, 0x30E9 },
- { 0x04D8, 0x30EA },
- { 0x04D9, 0x30EB },
- { 0x04DA, 0x30EC },
- { 0x04DB, 0x30ED },
- { 0x04DC, 0x30EF },
- { 0x04A6, 0x30F2 },
- { 0x04DD, 0x30F3 },
- { 0x04A5, 0x30FB },
- { 0x04B0, 0x30FC },
- { 0x0EA1, 0x3131 },
- { 0x0EA2, 0x3132 },
- { 0x0EA3, 0x3133 },
- { 0x0EA4, 0x3134 },
- { 0x0EA5, 0x3135 },
- { 0x0EA6, 0x3136 },
- { 0x0EA7, 0x3137 },
- { 0x0EA8, 0x3138 },
- { 0x0EA9, 0x3139 },
- { 0x0EAA, 0x313A },
- { 0x0EAB, 0x313B },
- { 0x0EAC, 0x313C },
- { 0x0EAD, 0x313D },
- { 0x0EAE, 0x313E },
- { 0x0EAF, 0x313F },
- { 0x0EB0, 0x3140 },
- { 0x0EB1, 0x3141 },
- { 0x0EB2, 0x3142 },
- { 0x0EB3, 0x3143 },
- { 0x0EB4, 0x3144 },
- { 0x0EB5, 0x3145 },
- { 0x0EB6, 0x3146 },
- { 0x0EB7, 0x3147 },
- { 0x0EB8, 0x3148 },
- { 0x0EB9, 0x3149 },
- { 0x0EBA, 0x314A },
- { 0x0EBB, 0x314B },
- { 0x0EBC, 0x314C },
- { 0x0EBD, 0x314D },
- { 0x0EBE, 0x314E },
- { 0x0EBF, 0x314F },
- { 0x0EC0, 0x3150 },
- { 0x0EC1, 0x3151 },
- { 0x0EC2, 0x3152 },
- { 0x0EC3, 0x3153 },
- { 0x0EC4, 0x3154 },
- { 0x0EC5, 0x3155 },
- { 0x0EC6, 0x3156 },
- { 0x0EC7, 0x3157 },
- { 0x0EC8, 0x3158 },
- { 0x0EC9, 0x3159 },
- { 0x0ECA, 0x315A },
- { 0x0ECB, 0x315B },
- { 0x0ECC, 0x315C },
- { 0x0ECD, 0x315D },
- { 0x0ECE, 0x315E },
- { 0x0ECF, 0x315F },
- { 0x0ED0, 0x3160 },
- { 0x0ED1, 0x3161 },
- { 0x0ED2, 0x3162 },
- { 0x0ED3, 0x3163 },
- { 0x0EEF, 0x316D },
- { 0x0EF0, 0x3171 },
- { 0x0EF1, 0x3178 },
- { 0x0EF2, 0x317F },
- { 0x0EF4, 0x3184 },
- { 0x0EF5, 0x3186 },
- { 0x0EF6, 0x318D },
- { 0x0EF7, 0x318E }
-};
-
-KeySym KeyMappingX11::get_keysym_from_unicode(unsigned int p_unicode) {
- /* Latin 1 */
-
- if (p_unicode >= 0x20 && p_unicode <= 0x7e) {
- return p_unicode;
- }
-
- if (p_unicode >= 0xa0 && p_unicode <= 0xff) {
- return p_unicode;
- }
-
- int middle, low = 0, high = _UNICODE_MAX - 1;
- do {
- middle = (high + low) / 2;
- if (_unicode_to_xkeysym[middle].keysym == p_unicode) {
- return _unicode_to_xkeysym[middle].keysym;
- }
- if (_unicode_to_xkeysym[middle].keysym <= p_unicode) {
- low = middle + 1;
- } else {
- high = middle - 1;
- }
- } while (high >= low);
-
- // if not found, let's hope X understands it as unicode
- return p_unicode | 0x01000000;
-}
diff --git a/platform/linuxbsd/libudev-so_wrap.c b/platform/linuxbsd/libudev-so_wrap.c
index a9fa4a494a..9593b5fb0f 100644
--- a/platform/linuxbsd/libudev-so_wrap.c
+++ b/platform/linuxbsd/libudev-so_wrap.c
@@ -1,7 +1,7 @@
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by /home/hp/Projects/godot/pulse/generate-wrapper.py 0.3 on 2021-02-20 00:08:59
-// flags: /home/hp/Projects/godot/pulse/generate-wrapper.py --include /usr/include/libudev.h --sys-include <libudev.h> --soname libudev.so.1 --init-name libudev --omit-prefix gnu_ --output-header libudev-so_wrap.h --output-implementation libudev-so_wrap.c
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:23:01
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/udev/libudev.h --sys-include "thirdparty/linuxbsd_headers/udev/libudev.h" --soname libudev.so.1 --init-name libudev --omit-prefix gnu_ --output-header ./platform/linuxbsd/libudev-so_wrap.h --output-implementation ./platform/linuxbsd/libudev-so_wrap.c
//
#include <stdint.h>
@@ -95,7 +95,7 @@
#define udev_hwdb_unref udev_hwdb_unref_dylibloader_orig_libudev
#define udev_hwdb_get_properties_list_entry udev_hwdb_get_properties_list_entry_dylibloader_orig_libudev
#define udev_util_encode_string udev_util_encode_string_dylibloader_orig_libudev
-#include <libudev.h>
+#include "thirdparty/linuxbsd_headers/udev/libudev.h"
#undef udev_ref
#undef udev_unref
#undef udev_new
@@ -229,7 +229,7 @@ const char* (*udev_device_get_action_dylibloader_wrapper_libudev)(struct udev_de
unsigned long long int (*udev_device_get_seqnum_dylibloader_wrapper_libudev)(struct udev_device*);
unsigned long long int (*udev_device_get_usec_since_initialized_dylibloader_wrapper_libudev)(struct udev_device*);
const char* (*udev_device_get_sysattr_value_dylibloader_wrapper_libudev)(struct udev_device*,const char*);
-int (*udev_device_set_sysattr_value_dylibloader_wrapper_libudev)(struct udev_device*,const char*,const char*);
+int (*udev_device_set_sysattr_value_dylibloader_wrapper_libudev)(struct udev_device*,const char*, char*);
int (*udev_device_has_tag_dylibloader_wrapper_libudev)(struct udev_device*,const char*);
struct udev_monitor* (*udev_monitor_ref_dylibloader_wrapper_libudev)(struct udev_monitor*);
struct udev_monitor* (*udev_monitor_unref_dylibloader_wrapper_libudev)(struct udev_monitor*);
@@ -276,7 +276,7 @@ struct udev_list_entry* (*udev_queue_get_queued_list_entry_dylibloader_wrapper_l
struct udev_hwdb* (*udev_hwdb_new_dylibloader_wrapper_libudev)(struct udev*);
struct udev_hwdb* (*udev_hwdb_ref_dylibloader_wrapper_libudev)(struct udev_hwdb*);
struct udev_hwdb* (*udev_hwdb_unref_dylibloader_wrapper_libudev)(struct udev_hwdb*);
-struct udev_list_entry* (*udev_hwdb_get_properties_list_entry_dylibloader_wrapper_libudev)(struct udev_hwdb*,const char*, unsigned);
+struct udev_list_entry* (*udev_hwdb_get_properties_list_entry_dylibloader_wrapper_libudev)(struct udev_hwdb*,const char*, unsigned int);
int (*udev_util_encode_string_dylibloader_wrapper_libudev)(const char*, char*, size_t);
int initialize_libudev(int verbose) {
void *handle;
diff --git a/platform/linuxbsd/libudev-so_wrap.h b/platform/linuxbsd/libudev-so_wrap.h
index dd43fd1191..9b9627877a 100644
--- a/platform/linuxbsd/libudev-so_wrap.h
+++ b/platform/linuxbsd/libudev-so_wrap.h
@@ -2,8 +2,8 @@
#define DYLIBLOAD_WRAPPER_LIBUDEV
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by /home/hp/Projects/godot/pulse/generate-wrapper.py 0.3 on 2021-02-20 00:08:59
-// flags: /home/hp/Projects/godot/pulse/generate-wrapper.py --include /usr/include/libudev.h --sys-include <libudev.h> --soname libudev.so.1 --init-name libudev --omit-prefix gnu_ --output-header libudev-so_wrap.h --output-implementation libudev-so_wrap.c
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:23:01
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/udev/libudev.h --sys-include "thirdparty/linuxbsd_headers/udev/libudev.h" --soname libudev.so.1 --init-name libudev --omit-prefix gnu_ --output-header ./platform/linuxbsd/libudev-so_wrap.h --output-implementation ./platform/linuxbsd/libudev-so_wrap.c
//
#include <stdint.h>
@@ -97,7 +97,7 @@
#define udev_hwdb_unref udev_hwdb_unref_dylibloader_orig_libudev
#define udev_hwdb_get_properties_list_entry udev_hwdb_get_properties_list_entry_dylibloader_orig_libudev
#define udev_util_encode_string udev_util_encode_string_dylibloader_orig_libudev
-#include <libudev.h>
+#include "thirdparty/linuxbsd_headers/udev/libudev.h"
#undef udev_ref
#undef udev_unref
#undef udev_new
@@ -322,7 +322,7 @@ extern const char* (*udev_device_get_action_dylibloader_wrapper_libudev)(struct
extern unsigned long long int (*udev_device_get_seqnum_dylibloader_wrapper_libudev)(struct udev_device*);
extern unsigned long long int (*udev_device_get_usec_since_initialized_dylibloader_wrapper_libudev)(struct udev_device*);
extern const char* (*udev_device_get_sysattr_value_dylibloader_wrapper_libudev)(struct udev_device*,const char*);
-extern int (*udev_device_set_sysattr_value_dylibloader_wrapper_libudev)(struct udev_device*,const char*,const char*);
+extern int (*udev_device_set_sysattr_value_dylibloader_wrapper_libudev)(struct udev_device*,const char*, char*);
extern int (*udev_device_has_tag_dylibloader_wrapper_libudev)(struct udev_device*,const char*);
extern struct udev_monitor* (*udev_monitor_ref_dylibloader_wrapper_libudev)(struct udev_monitor*);
extern struct udev_monitor* (*udev_monitor_unref_dylibloader_wrapper_libudev)(struct udev_monitor*);
@@ -369,7 +369,7 @@ extern struct udev_list_entry* (*udev_queue_get_queued_list_entry_dylibloader_wr
extern struct udev_hwdb* (*udev_hwdb_new_dylibloader_wrapper_libudev)(struct udev*);
extern struct udev_hwdb* (*udev_hwdb_ref_dylibloader_wrapper_libudev)(struct udev_hwdb*);
extern struct udev_hwdb* (*udev_hwdb_unref_dylibloader_wrapper_libudev)(struct udev_hwdb*);
-extern struct udev_list_entry* (*udev_hwdb_get_properties_list_entry_dylibloader_wrapper_libudev)(struct udev_hwdb*,const char*, unsigned);
+extern struct udev_list_entry* (*udev_hwdb_get_properties_list_entry_dylibloader_wrapper_libudev)(struct udev_hwdb*,const char*, unsigned int);
extern int (*udev_util_encode_string_dylibloader_wrapper_libudev)(const char*, char*, size_t);
int initialize_libudev(int verbose);
#ifdef __cplusplus
diff --git a/platform/linuxbsd/logo.png b/platform/linuxbsd/logo.png
deleted file mode 100644
index 078654b757..0000000000
--- a/platform/linuxbsd/logo.png
+++ /dev/null
Binary files differ
diff --git a/platform/linuxbsd/logo.svg b/platform/linuxbsd/logo.svg
new file mode 100644
index 0000000000..e5f9f03e0c
--- /dev/null
+++ b/platform/linuxbsd/logo.svg
@@ -0,0 +1 @@
+<svg height="32" width="32"><path d="M13 31h6s3 0 6-6c2.864-5.727-6-17-6-17h-6S3.775 18.55 7 25c3 6 6 6 6 6z" fill="#fff"/><path d="M15.876 28.636c-.05.322-.116.637-.204.941-.142.496-.35.993-.659 1.416.32.02.649.023.985.007a9.1 9.1 0 0 0 .985-.007c-.309-.423-.516-.92-.659-1.416a7.666 7.666 0 0 1-.203-.94l-.123.003c-.04 0-.081-.003-.122-.004z" fill="#333"/><path d="M21.693 21.916c-.629.01-.934.633-1.497.7-.694.08-1.128-.722-2.11-.123-.98.6-1.826 7.473.45 8.409 2.274.935 6.506-4.545 6.23-5.662-.275-1.116-1.146-.853-1.582-1.399-.436-.545.003-1.41-.995-1.82a1.246 1.246 0 0 0-.496-.105zm-11.461 0a1.315 1.315 0 0 0-.421.105c-.998.41-.56 1.275-.995 1.82-.436.546-1.31.283-1.586 1.4-.275 1.116 3.956 6.596 6.232 5.66 2.275-.935 1.429-7.808.448-8.408-.981-.6-1.415.204-2.11.122-.584-.068-.888-.739-1.568-.7z" fill="#f4bb37"/><path d="M15.998.99c-2.934 0-4.657 1.79-4.982 4.204-.324 2.414.198 2.856-.614 5.328-.813 2.472-4.456 6.71-4.37 10.62.026 1.217.166 2.27.41 3.192.3-.496.743-.846 1.066-.995.253-.117.375-.173.432-.194.008-.062.04-.205.098-.485.08-.386.387-.99.91-1.386-.005-.12-.01-.239-.013-.363-.06-3.033 3.073-6.318 3.65-8.236.577-1.917.326-2.114.421-2.59.096-.477.463-1.032.992-1.475a.23.23 0 0 1 .15-.06c.482-.005.965 1.75 1.898 1.752.933 0 1.419-2.141 1.956-1.692.529.443.896.998.992 1.474.095.477-.156.674.42 2.591.578 1.918 3.708 5.203 3.648 8.236-.003.123-.008.24-.014.36.526.396.834 1.002.914 1.389.058.28.09.423.098.485.057.021.18.08.432.197.323.15.764.499 1.063.995.244-.922.387-1.976.414-3.195.085-3.91-3.562-8.148-4.374-10.62-.813-2.472-.287-2.914-.611-5.328C20.659 2.78 18.933.99 15.998.99z" fill="#333"/></svg>
diff --git a/platform/linuxbsd/os_linuxbsd.cpp b/platform/linuxbsd/os_linuxbsd.cpp
index 61faf3061c..75c23655f2 100644
--- a/platform/linuxbsd/os_linuxbsd.cpp
+++ b/platform/linuxbsd/os_linuxbsd.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* os_linuxbsd.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* os_linuxbsd.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "os_linuxbsd.h"
@@ -34,28 +34,28 @@
#include "main/main.h"
#include "servers/display_server.h"
+#include "modules/modules_enabled.gen.h" // For regex.
+#ifdef MODULE_REGEX_ENABLED
+#include "modules/regex/regex.h"
+#endif
+
#ifdef X11_ENABLED
-#include "display_server_x11.h"
+#include "x11/display_server_x11.h"
#endif
#ifdef HAVE_MNTENT
#include <mntent.h>
#endif
+#include <dlfcn.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-
-#include <dlfcn.h>
-#include <fcntl.h>
#include <sys/stat.h>
#include <sys/types.h>
+#include <sys/utsname.h>
#include <unistd.h>
-#ifdef FONTCONFIG_ENABLED
-#include "fontconfig-so_wrap.h"
-#endif
-
void OS_LinuxBSD::alert(const String &p_alert, const String &p_title) {
const char *message_programs[] = { "zenity", "kdialog", "Xdialog", "xmessage" };
@@ -124,6 +124,8 @@ void OS_LinuxBSD::initialize() {
crash_handler.initialize();
OS_Unix::initialize_core();
+
+ system_dir_desktop_cache = get_system_dir(SYSTEM_DIR_DESKTOP);
}
void OS_LinuxBSD::initialize_joypads() {
@@ -205,6 +207,240 @@ String OS_LinuxBSD::get_name() const {
#endif
}
+String OS_LinuxBSD::get_systemd_os_release_info_value(const String &key) const {
+ static String info;
+ if (info.is_empty()) {
+ Ref<FileAccess> f = FileAccess::open("/etc/os-release", FileAccess::READ);
+ if (f.is_valid()) {
+ while (!f->eof_reached()) {
+ const String line = f->get_line();
+ if (line.find(key) != -1) {
+ return line.split("=")[1].strip_edges();
+ }
+ }
+ }
+ }
+ return info;
+}
+
+String OS_LinuxBSD::get_distribution_name() const {
+ static String systemd_name = get_systemd_os_release_info_value("NAME"); // returns a value for systemd users, otherwise an empty string.
+ if (!systemd_name.is_empty()) {
+ return systemd_name;
+ }
+ struct utsname uts; // returns a decent value for BSD family.
+ uname(&uts);
+ return uts.sysname;
+}
+
+String OS_LinuxBSD::get_version() const {
+ static String systemd_version = get_systemd_os_release_info_value("VERSION"); // returns a value for systemd users, otherwise an empty string.
+ if (!systemd_version.is_empty()) {
+ return systemd_version;
+ }
+ struct utsname uts; // returns a decent value for BSD family.
+ uname(&uts);
+ return uts.version;
+}
+
+Vector<String> OS_LinuxBSD::get_video_adapter_driver_info() const {
+ if (RenderingServer::get_singleton()->get_rendering_device() == nullptr) {
+ return Vector<String>();
+ }
+
+ const String rendering_device_name = RenderingServer::get_singleton()->get_rendering_device()->get_device_name(); // e.g. `NVIDIA GeForce GTX 970`
+ const String rendering_device_vendor = RenderingServer::get_singleton()->get_rendering_device()->get_device_vendor_name(); // e.g. `NVIDIA`
+ const String card_name = rendering_device_name.trim_prefix(rendering_device_vendor).strip_edges(); // -> `GeForce GTX 970`
+
+ String vendor_device_id_mappings;
+ List<String> lspci_args;
+ lspci_args.push_back("-n");
+ Error err = const_cast<OS_LinuxBSD *>(this)->execute("lspci", lspci_args, &vendor_device_id_mappings);
+ if (err != OK || vendor_device_id_mappings.is_empty()) {
+ return Vector<String>();
+ }
+
+ // Usually found under "VGA", but for example NVIDIA mobile/laptop adapters are often listed under "3D" and some AMD adapters are under "Display".
+ const String dc_vga = "0300"; // VGA compatible controller
+ const String dc_display = "0302"; // Display controller
+ const String dc_3d = "0380"; // 3D controller
+
+ // splitting results by device class allows prioritizing, if multiple devices are found.
+ Vector<String> class_vga_device_candidates;
+ Vector<String> class_display_device_candidates;
+ Vector<String> class_3d_device_candidates;
+
+#ifdef MODULE_REGEX_ENABLED
+ RegEx regex_id_format = RegEx();
+ regex_id_format.compile("^[a-f0-9]{4}:[a-f0-9]{4}$"); // e.g. `10de:13c2`; IDs are always in hexadecimal
+#endif
+
+ Vector<String> value_lines = vendor_device_id_mappings.split("\n", false); // example: `02:00.0 0300: 10de:13c2 (rev a1)`
+ for (const String &line : value_lines) {
+ Vector<String> columns = line.split(" ", false);
+ if (columns.size() < 3) {
+ continue;
+ }
+ String device_class = columns[1].trim_suffix(":");
+ String vendor_device_id_mapping = columns[2];
+
+#ifdef MODULE_REGEX_ENABLED
+ if (regex_id_format.search(vendor_device_id_mapping).is_null()) {
+ continue;
+ }
+#endif
+
+ if (device_class == dc_vga) {
+ class_vga_device_candidates.push_back(vendor_device_id_mapping);
+ } else if (device_class == dc_display) {
+ class_display_device_candidates.push_back(vendor_device_id_mapping);
+ } else if (device_class == dc_3d) {
+ class_3d_device_candidates.push_back(vendor_device_id_mapping);
+ }
+ }
+
+ // Check results against currently used device (`card_name`), in case the user has multiple graphics cards.
+ const String device_lit = "Device"; // line of interest
+ class_vga_device_candidates = OS_LinuxBSD::lspci_device_filter(class_vga_device_candidates, dc_vga, device_lit, card_name);
+ class_display_device_candidates = OS_LinuxBSD::lspci_device_filter(class_display_device_candidates, dc_display, device_lit, card_name);
+ class_3d_device_candidates = OS_LinuxBSD::lspci_device_filter(class_3d_device_candidates, dc_3d, device_lit, card_name);
+
+ // Get driver names and filter out invalid ones, because some adapters are dummys used only for passthrough.
+ // And they have no indicator besides certain driver names.
+ const String kernel_lit = "Kernel driver in use"; // line of interest
+ const String dummys = "vfio"; // for e.g. pci passthrough dummy kernel driver `vfio-pci`
+ Vector<String> class_vga_device_drivers = OS_LinuxBSD::lspci_get_device_value(class_vga_device_candidates, kernel_lit, dummys);
+ Vector<String> class_display_device_drivers = OS_LinuxBSD::lspci_get_device_value(class_display_device_candidates, kernel_lit, dummys);
+ Vector<String> class_3d_device_drivers = OS_LinuxBSD::lspci_get_device_value(class_3d_device_candidates, kernel_lit, dummys);
+
+ static String driver_name;
+ static String driver_version;
+
+ // Use first valid value:
+ for (const String &driver : class_3d_device_drivers) {
+ driver_name = driver;
+ break;
+ }
+ if (driver_name.is_empty()) {
+ for (const String &driver : class_display_device_drivers) {
+ driver_name = driver;
+ break;
+ }
+ }
+ if (driver_name.is_empty()) {
+ for (const String &driver : class_vga_device_drivers) {
+ driver_name = driver;
+ break;
+ }
+ }
+
+ Vector<String> info;
+ info.push_back(driver_name);
+
+ String modinfo;
+ List<String> modinfo_args;
+ modinfo_args.push_back(driver_name);
+ err = const_cast<OS_LinuxBSD *>(this)->execute("modinfo", modinfo_args, &modinfo);
+ if (err != OK || modinfo.is_empty()) {
+ info.push_back(""); // So that this method always either returns an empty array, or an array of length 2.
+ return info;
+ }
+ Vector<String> lines = modinfo.split("\n", false);
+ for (const String &line : lines) {
+ Vector<String> columns = line.split(":", false, 1);
+ if (columns.size() < 2) {
+ continue;
+ }
+ if (columns[0].strip_edges() == "version") {
+ driver_version = columns[1].strip_edges(); // example value: `510.85.02` on Linux/BSD
+ break;
+ }
+ }
+
+ info.push_back(driver_version);
+
+ return info;
+}
+
+Vector<String> OS_LinuxBSD::lspci_device_filter(Vector<String> vendor_device_id_mapping, String class_suffix, String check_column, String whitelist) const {
+ // NOTE: whitelist can be changed to `Vector<String>`, if the need arises.
+ const String sep = ":";
+ Vector<String> devices;
+ for (const String &mapping : vendor_device_id_mapping) {
+ String device;
+ List<String> d_args;
+ d_args.push_back("-d");
+ d_args.push_back(mapping + sep + class_suffix);
+ d_args.push_back("-vmm");
+ Error err = const_cast<OS_LinuxBSD *>(this)->execute("lspci", d_args, &device); // e.g. `lspci -d 10de:13c2:0300 -vmm`
+ if (err != OK) {
+ return Vector<String>();
+ } else if (device.is_empty()) {
+ continue;
+ }
+
+ Vector<String> device_lines = device.split("\n", false);
+ for (const String &line : device_lines) {
+ Vector<String> columns = line.split(":", false, 1);
+ if (columns.size() < 2) {
+ continue;
+ }
+ if (columns[0].strip_edges() == check_column) {
+ // for `column[0] == "Device"` this may contain `GM204 [GeForce GTX 970]`
+ bool is_valid = true;
+ if (!whitelist.is_empty()) {
+ is_valid = columns[1].strip_edges().contains(whitelist);
+ }
+ if (is_valid) {
+ devices.push_back(mapping);
+ }
+ break;
+ }
+ }
+ }
+ return devices;
+}
+
+Vector<String> OS_LinuxBSD::lspci_get_device_value(Vector<String> vendor_device_id_mapping, String check_column, String blacklist) const {
+ // NOTE: blacklist can be changed to `Vector<String>`, if the need arises.
+ const String sep = ":";
+ Vector<String> values;
+ for (const String &mapping : vendor_device_id_mapping) {
+ String device;
+ List<String> d_args;
+ d_args.push_back("-d");
+ d_args.push_back(mapping);
+ d_args.push_back("-k");
+ Error err = const_cast<OS_LinuxBSD *>(this)->execute("lspci", d_args, &device); // e.g. `lspci -d 10de:13c2 -k`
+ if (err != OK) {
+ return Vector<String>();
+ } else if (device.is_empty()) {
+ continue;
+ }
+
+ Vector<String> device_lines = device.split("\n", false);
+ for (const String &line : device_lines) {
+ Vector<String> columns = line.split(":", false, 1);
+ if (columns.size() < 2) {
+ continue;
+ }
+ if (columns[0].strip_edges() == check_column) {
+ // for `column[0] == "Kernel driver in use"` this may contain `nvidia`
+ bool is_valid = true;
+ const String value = columns[1].strip_edges();
+ if (!blacklist.is_empty()) {
+ is_valid = !value.contains(blacklist);
+ }
+ if (is_valid) {
+ values.push_back(value);
+ }
+ break;
+ }
+ }
+ }
+ return values;
+}
+
Error OS_LinuxBSD::shell_open(String p_uri) {
Error ok;
int err_code;
@@ -243,7 +479,16 @@ Error OS_LinuxBSD::shell_open(String p_uri) {
}
bool OS_LinuxBSD::_check_internal_feature_support(const String &p_feature) {
- return p_feature == "pc";
+#ifdef FONTCONFIG_ENABLED
+ if (p_feature == "system_fonts") {
+ return font_config_initialized;
+ }
+#endif
+ if (p_feature == "pc") {
+ return true;
+ }
+
+ return false;
}
uint64_t OS_LinuxBSD::get_embedded_pck_offset() const {
@@ -336,15 +581,9 @@ Vector<String> OS_LinuxBSD::get_system_fonts() const {
if (!font_config_initialized) {
ERR_FAIL_V_MSG(Vector<String>(), "Unable to load fontconfig, system font support is disabled.");
}
+
HashSet<String> font_names;
Vector<String> ret;
-
- FcConfig *config = FcInitLoadConfigAndFonts();
- ERR_FAIL_COND_V(!config, ret);
-
- FcObjectSet *object_set = FcObjectSetBuild(FC_FAMILY, nullptr);
- ERR_FAIL_COND_V(!object_set, ret);
-
static const char *allowed_formats[] = { "TrueType", "CFF" };
for (size_t i = 0; i < sizeof(allowed_formats) / sizeof(const char *); i++) {
FcPattern *pattern = FcPatternCreate();
@@ -367,8 +606,6 @@ Vector<String> OS_LinuxBSD::get_system_fonts() const {
}
FcPatternDestroy(pattern);
}
- FcObjectSetDestroy(object_set);
- FcConfigDestroy(config);
for (const String &E : font_names) {
ret.push_back(E);
@@ -379,25 +616,122 @@ Vector<String> OS_LinuxBSD::get_system_fonts() const {
#endif
}
-String OS_LinuxBSD::get_system_font_path(const String &p_font_name, bool p_bold, bool p_italic) const {
+#ifdef FONTCONFIG_ENABLED
+int OS_LinuxBSD::_weight_to_fc(int p_weight) const {
+ if (p_weight < 150) {
+ return FC_WEIGHT_THIN;
+ } else if (p_weight < 250) {
+ return FC_WEIGHT_EXTRALIGHT;
+ } else if (p_weight < 325) {
+ return FC_WEIGHT_LIGHT;
+ } else if (p_weight < 375) {
+ return FC_WEIGHT_DEMILIGHT;
+ } else if (p_weight < 390) {
+ return FC_WEIGHT_BOOK;
+ } else if (p_weight < 450) {
+ return FC_WEIGHT_REGULAR;
+ } else if (p_weight < 550) {
+ return FC_WEIGHT_MEDIUM;
+ } else if (p_weight < 650) {
+ return FC_WEIGHT_DEMIBOLD;
+ } else if (p_weight < 750) {
+ return FC_WEIGHT_BOLD;
+ } else if (p_weight < 850) {
+ return FC_WEIGHT_EXTRABOLD;
+ } else if (p_weight < 925) {
+ return FC_WEIGHT_BLACK;
+ } else {
+ return FC_WEIGHT_EXTRABLACK;
+ }
+}
+
+int OS_LinuxBSD::_stretch_to_fc(int p_stretch) const {
+ if (p_stretch < 56) {
+ return FC_WIDTH_ULTRACONDENSED;
+ } else if (p_stretch < 69) {
+ return FC_WIDTH_EXTRACONDENSED;
+ } else if (p_stretch < 81) {
+ return FC_WIDTH_CONDENSED;
+ } else if (p_stretch < 93) {
+ return FC_WIDTH_SEMICONDENSED;
+ } else if (p_stretch < 106) {
+ return FC_WIDTH_NORMAL;
+ } else if (p_stretch < 137) {
+ return FC_WIDTH_SEMIEXPANDED;
+ } else if (p_stretch < 144) {
+ return FC_WIDTH_EXPANDED;
+ } else if (p_stretch < 162) {
+ return FC_WIDTH_EXTRAEXPANDED;
+ } else {
+ return FC_WIDTH_ULTRAEXPANDED;
+ }
+}
+#endif // FONTCONFIG_ENABLED
+
+Vector<String> OS_LinuxBSD::get_system_font_path_for_text(const String &p_font_name, const String &p_text, const String &p_locale, const String &p_script, int p_weight, int p_stretch, bool p_italic) const {
#ifdef FONTCONFIG_ENABLED
if (!font_config_initialized) {
- ERR_FAIL_V_MSG(String(), "Unable to load fontconfig, system font support is disabled.");
+ ERR_FAIL_V_MSG(Vector<String>(), "Unable to load fontconfig, system font support is disabled.");
}
- String ret;
+ Vector<String> ret;
+ FcPattern *pattern = FcPatternCreate();
+ if (pattern) {
+ FcPatternAddString(pattern, FC_FAMILY, reinterpret_cast<const FcChar8 *>(p_font_name.utf8().get_data()));
+ FcPatternAddInteger(pattern, FC_WEIGHT, _weight_to_fc(p_weight));
+ FcPatternAddInteger(pattern, FC_WIDTH, _stretch_to_fc(p_stretch));
+ FcPatternAddInteger(pattern, FC_SLANT, p_italic ? FC_SLANT_ITALIC : FC_SLANT_ROMAN);
+
+ FcCharSet *char_set = FcCharSetCreate();
+ for (int i = 0; i < p_text.size(); i++) {
+ FcCharSetAddChar(char_set, p_text[i]);
+ }
+ FcPatternAddCharSet(pattern, FC_CHARSET, char_set);
- FcConfig *config = FcInitLoadConfigAndFonts();
- ERR_FAIL_COND_V(!config, ret);
+ FcLangSet *lang_set = FcLangSetCreate();
+ FcLangSetAdd(lang_set, reinterpret_cast<const FcChar8 *>(p_locale.utf8().get_data()));
+ FcPatternAddLangSet(pattern, FC_LANG, lang_set);
- FcObjectSet *object_set = FcObjectSetBuild(FC_FAMILY, FC_FILE, nullptr);
- ERR_FAIL_COND_V(!object_set, ret);
+ FcConfigSubstitute(0, pattern, FcMatchPattern);
+ FcDefaultSubstitute(pattern);
+ FcResult result;
+ FcPattern *match = FcFontMatch(0, pattern, &result);
+ if (match) {
+ char *file_name = nullptr;
+ if (FcPatternGetString(match, FC_FILE, 0, reinterpret_cast<FcChar8 **>(&file_name)) == FcResultMatch) {
+ if (file_name) {
+ ret.push_back(String::utf8(file_name));
+ }
+ }
+ FcPatternDestroy(match);
+ }
+ FcPatternDestroy(pattern);
+ FcCharSetDestroy(char_set);
+ FcLangSetDestroy(lang_set);
+ }
+
+ return ret;
+#else
+ ERR_FAIL_V_MSG(Vector<String>(), "Godot was compiled without fontconfig, system font support is disabled.");
+#endif
+}
+
+String OS_LinuxBSD::get_system_font_path(const String &p_font_name, int p_weight, int p_stretch, bool p_italic) const {
+#ifdef FONTCONFIG_ENABLED
+ if (!font_config_initialized) {
+ ERR_FAIL_V_MSG(String(), "Unable to load fontconfig, system font support is disabled.");
+ }
+
+ String ret;
FcPattern *pattern = FcPatternCreate();
if (pattern) {
+ bool allow_substitutes = (p_font_name.to_lower() == "sans-serif") || (p_font_name.to_lower() == "serif") || (p_font_name.to_lower() == "monospace") || (p_font_name.to_lower() == "cursive") || (p_font_name.to_lower() == "fantasy");
+
FcPatternAddBool(pattern, FC_SCALABLE, FcTrue);
FcPatternAddString(pattern, FC_FAMILY, reinterpret_cast<const FcChar8 *>(p_font_name.utf8().get_data()));
- FcPatternAddInteger(pattern, FC_WEIGHT, p_bold ? FC_WEIGHT_BOLD : FC_WEIGHT_NORMAL);
+ FcPatternAddInteger(pattern, FC_WEIGHT, _weight_to_fc(p_weight));
+ FcPatternAddInteger(pattern, FC_WIDTH, _stretch_to_fc(p_stretch));
FcPatternAddInteger(pattern, FC_SLANT, p_italic ? FC_SLANT_ITALIC : FC_SLANT_ROMAN);
FcConfigSubstitute(0, pattern, FcMatchPattern);
@@ -406,6 +740,17 @@ String OS_LinuxBSD::get_system_font_path(const String &p_font_name, bool p_bold,
FcResult result;
FcPattern *match = FcFontMatch(0, pattern, &result);
if (match) {
+ if (!allow_substitutes) {
+ char *family_name = nullptr;
+ if (FcPatternGetString(match, FC_FAMILY, 0, reinterpret_cast<FcChar8 **>(&family_name)) == FcResultMatch) {
+ if (family_name && String::utf8(family_name).to_lower() != p_font_name.to_lower()) {
+ FcPatternDestroy(match);
+ FcPatternDestroy(pattern);
+
+ return String();
+ }
+ }
+ }
char *file_name = nullptr;
if (FcPatternGetString(match, FC_FILE, 0, reinterpret_cast<FcChar8 **>(&file_name)) == FcResultMatch) {
if (file_name) {
@@ -417,8 +762,6 @@ String OS_LinuxBSD::get_system_font_path(const String &p_font_name, bool p_bold,
}
FcPatternDestroy(pattern);
}
- FcObjectSetDestroy(object_set);
- FcConfigDestroy(config);
return ret;
#else
@@ -472,6 +815,10 @@ String OS_LinuxBSD::get_cache_path() const {
}
String OS_LinuxBSD::get_system_dir(SystemDir p_dir, bool p_shared_storage) const {
+ if (p_dir == SYSTEM_DIR_DESKTOP && !system_dir_desktop_cache.is_empty()) {
+ return system_dir_desktop_cache;
+ }
+
String xdgparam;
switch (p_dir) {
@@ -480,31 +827,24 @@ String OS_LinuxBSD::get_system_dir(SystemDir p_dir, bool p_shared_storage) const
} break;
case SYSTEM_DIR_DCIM: {
xdgparam = "PICTURES";
-
} break;
case SYSTEM_DIR_DOCUMENTS: {
xdgparam = "DOCUMENTS";
-
} break;
case SYSTEM_DIR_DOWNLOADS: {
xdgparam = "DOWNLOAD";
-
} break;
case SYSTEM_DIR_MOVIES: {
xdgparam = "VIDEOS";
-
} break;
case SYSTEM_DIR_MUSIC: {
xdgparam = "MUSIC";
-
} break;
case SYSTEM_DIR_PICTURES: {
xdgparam = "PICTURES";
-
} break;
case SYSTEM_DIR_RINGTONES: {
xdgparam = "MUSIC";
-
} break;
}
@@ -686,10 +1026,9 @@ Error OS_LinuxBSD::move_to_trash(const String &p_path) {
String renamed_path = path.get_base_dir() + "/" + file_name;
// Generates the .trashinfo file
- OS::Date date = OS::get_singleton()->get_date(false);
- OS::Time time = OS::get_singleton()->get_time(false);
- String timestamp = vformat("%04d-%02d-%02dT%02d:%02d:", date.year, (int)date.month, date.day, time.hour, time.minute);
- timestamp = vformat("%s%02d", timestamp, time.second); // vformat only supports up to 6 arguments.
+ OS::DateTime dt = OS::get_singleton()->get_datetime(false);
+ String timestamp = vformat("%04d-%02d-%02dT%02d:%02d:", dt.year, (int)dt.month, dt.day, dt.hour, dt.minute);
+ timestamp = vformat("%s%02d", timestamp, dt.second); // vformat only supports up to 6 arguments.
String trash_info = "[Trash Info]\nPath=" + path.uri_encode() + "\nDeletionDate=" + timestamp + "\n";
{
Error err;
@@ -748,5 +1087,26 @@ OS_LinuxBSD::OS_LinuxBSD() {
int dylibloader_verbose = 0;
#endif
font_config_initialized = (initialize_fontconfig(dylibloader_verbose) == 0);
+ if (font_config_initialized) {
+ config = FcInitLoadConfigAndFonts();
+ if (!config) {
+ font_config_initialized = false;
+ }
+ object_set = FcObjectSetBuild(FC_FAMILY, FC_FILE, nullptr);
+ if (!object_set) {
+ font_config_initialized = false;
+ }
+ }
+#endif // FONTCONFIG_ENABLED
+}
+
+OS_LinuxBSD::~OS_LinuxBSD() {
+#ifdef FONTCONFIG_ENABLED
+ if (object_set) {
+ FcObjectSetDestroy(object_set);
+ }
+ if (config) {
+ FcConfigDestroy(config);
+ }
#endif // FONTCONFIG_ENABLED
}
diff --git a/platform/linuxbsd/os_linuxbsd.h b/platform/linuxbsd/os_linuxbsd.h
index d5b2321316..045d3d95ba 100644
--- a/platform/linuxbsd/os_linuxbsd.h
+++ b/platform/linuxbsd/os_linuxbsd.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* os_linuxbsd.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* os_linuxbsd.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef OS_LINUXBSD_H
#define OS_LINUXBSD_H
@@ -40,11 +40,20 @@
#include "joypad_linux.h"
#include "servers/audio_server.h"
+#ifdef FONTCONFIG_ENABLED
+#include "fontconfig-so_wrap.h"
+#endif
+
class OS_LinuxBSD : public OS_Unix {
virtual void delete_main_loop() override;
#ifdef FONTCONFIG_ENABLED
bool font_config_initialized = false;
+ FcConfig *config = nullptr;
+ FcObjectSet *object_set = nullptr;
+
+ int _weight_to_fc(int p_weight) const;
+ int _stretch_to_fc(int p_stretch) const;
#endif
#ifdef JOYDEV_ENABLED
@@ -67,6 +76,13 @@ class OS_LinuxBSD : public OS_Unix {
MainLoop *main_loop = nullptr;
+ String get_systemd_os_release_info_value(const String &key) const;
+
+ Vector<String> lspci_device_filter(Vector<String> vendor_device_id_mapping, String class_suffix, String check_column, String whitelist) const;
+ Vector<String> lspci_get_device_value(Vector<String> vendor_device_id_mapping, String check_column, String blacklist) const;
+
+ String system_dir_desktop_cache;
+
protected:
virtual void initialize() override;
virtual void finalize() override;
@@ -77,13 +93,18 @@ protected:
public:
virtual String get_name() const override;
+ virtual String get_distribution_name() const override;
+ virtual String get_version() const override;
+
+ virtual Vector<String> get_video_adapter_driver_info() const override;
virtual MainLoop *get_main_loop() const override;
virtual uint64_t get_embedded_pck_offset() const override;
virtual Vector<String> get_system_fonts() const override;
- virtual String get_system_font_path(const String &p_font_name, bool p_bold = false, bool p_italic = false) const override;
+ virtual String get_system_font_path(const String &p_font_name, int p_weight = 400, int p_stretch = 100, bool p_italic = false) const override;
+ virtual Vector<String> get_system_font_path_for_text(const String &p_font_name, const String &p_text, const String &p_locale = String(), const String &p_script = String(), int p_weight = 400, int p_stretch = 100, bool p_italic = false) const override;
virtual String get_config_path() const override;
virtual String get_data_path() const override;
@@ -108,6 +129,7 @@ public:
virtual Error move_to_trash(const String &p_path) override;
OS_LinuxBSD();
+ ~OS_LinuxBSD();
};
#endif // OS_LINUXBSD_H
diff --git a/platform/linuxbsd/platform_config.h b/platform/linuxbsd/platform_config.h
index 3c05c67444..82c9c54879 100644
--- a/platform/linuxbsd/platform_config.h
+++ b/platform/linuxbsd/platform_config.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* platform_config.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* platform_config.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifdef __linux__
#include <alloca.h>
@@ -44,4 +44,4 @@
#endif
#endif
-#define OPENGL_INCLUDE_H "thirdparty/glad/glad/glad.h"
+#define OPENGL_INCLUDE_H "thirdparty/glad/glad/gl.h"
diff --git a/platform/linuxbsd/run_icon.svg b/platform/linuxbsd/run_icon.svg
new file mode 100644
index 0000000000..56465a0df3
--- /dev/null
+++ b/platform/linuxbsd/run_icon.svg
@@ -0,0 +1 @@
+<svg height="16" width="16" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"><path d="M7.941 13.966a3.62 3.62 0 0 1-.096.444 2.129 2.129 0 0 1-.31.668c.15.01.305.01.464.003.16.008.314.007.465-.003a2.129 2.129 0 0 1-.31-.668 3.62 3.62 0 0 1-.097-.444l-.058.001-.058-.001z" fill="#333" style="stroke-width:.472092;fill:#e0e0e0;fill-opacity:1"/><path d="M10.688 10.793c-.297.005-.441.299-.707.33-.328.038-.533-.34-.996-.058-.463.283-.862 3.528.212 3.97 1.074.442 3.072-2.146 2.942-2.673-.13-.527-.542-.403-.747-.66-.206-.258 0-.666-.47-.86a.588.588 0 0 0-.234-.05zm-5.411 0a.62.62 0 0 0-.199.05c-.47.193-.264.601-.47.859-.205.257-.618.133-.748.66s1.867 3.115 2.942 2.673c1.074-.442.674-3.687.211-3.97-.463-.283-.668.096-.995.058-.277-.032-.42-.349-.741-.33z" fill="#f4bb37" style="stroke-width:.472092;fill:#e0e0e0;fill-opacity:1"/><path d="M8 .914c-1.386 0-2.2.845-2.353 1.985-.153 1.14.094 1.348-.29 2.515s-2.103 3.168-2.063 5.013c.012.575.078 1.072.194 1.507a1.25 1.25 0 0 1 .503-.47 4.37 4.37 0 0 1 .204-.09c.004-.03.019-.098.046-.23.038-.182.183-.467.43-.654a4.773 4.773 0 0 1-.006-.172c-.029-1.431 1.45-2.982 1.723-3.888.272-.905.154-.998.199-1.223.045-.225.218-.487.468-.696a.11.11 0 0 1 .07-.028c.228-.003.456.826.897.827.44 0 .67-1.01.923-.799.25.21.423.471.468.696.045.225-.073.318.199 1.223.272.906 1.75 2.457 1.722 3.888-.001.058-.004.114-.007.17a1.2 1.2 0 0 1 .432.656c.027.132.042.2.046.23.027.01.085.037.204.092.153.07.36.236.502.47.115-.435.183-.933.195-1.509.04-1.845-1.681-3.846-2.065-5.013-.383-1.167-.135-1.376-.288-2.515C10.2 1.759 9.385.914 7.999.914Z" fill="#333" style="stroke-width:.472092;fill:#e0e0e0;fill-opacity:1"/></svg>
diff --git a/platform/linuxbsd/speechd-so_wrap.c b/platform/linuxbsd/speechd-so_wrap.c
index 749474e181..c860c686f0 100644
--- a/platform/linuxbsd/speechd-so_wrap.c
+++ b/platform/linuxbsd/speechd-so_wrap.c
@@ -1,7 +1,7 @@
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by ./dynload-wrapper/generate-wrapper.py 0.3 on 2022-04-28 14:34:21
-// flags: ./dynload-wrapper/generate-wrapper.py --sys-include <libspeechd.h> --include /usr/include/speech-dispatcher/libspeechd.h --soname libspeechd.so.2 --init-name speechd --omit-prefix spd_get_client_list --output-header speechd-so_wrap.h --output-implementation speechd-so_wrap.c
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:07:46
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/speechd/libspeechd.h --sys-include "thirdparty/linuxbsd_headers/speechd/libspeechd.h" --soname libspeechd.so.2 --init-name speechd --omit-prefix spd_get_client_list --output-header ./platform/linuxbsd/speechd-so_wrap.h --output-implementation ./platform/linuxbsd/speechd-so_wrap.c
//
#include <stdint.h>
@@ -47,9 +47,6 @@
#define spd_set_voice_pitch_all spd_set_voice_pitch_all_dylibloader_orig_speechd
#define spd_set_voice_pitch_uid spd_set_voice_pitch_uid_dylibloader_orig_speechd
#define spd_get_voice_pitch spd_get_voice_pitch_dylibloader_orig_speechd
-#define spd_set_voice_pitch_range spd_set_voice_pitch_range_dylibloader_orig_speechd
-#define spd_set_voice_pitch_range_all spd_set_voice_pitch_range_all_dylibloader_orig_speechd
-#define spd_set_voice_pitch_range_uid spd_set_voice_pitch_range_uid_dylibloader_orig_speechd
#define spd_set_volume spd_set_volume_dylibloader_orig_speechd
#define spd_set_volume_all spd_set_volume_all_dylibloader_orig_speechd
#define spd_set_volume_uid spd_set_volume_uid_dylibloader_orig_speechd
@@ -83,7 +80,7 @@
#define spd_execute_command_wo_mutex spd_execute_command_wo_mutex_dylibloader_orig_speechd
#define spd_send_data spd_send_data_dylibloader_orig_speechd
#define spd_send_data_wo_mutex spd_send_data_wo_mutex_dylibloader_orig_speechd
-#include <libspeechd.h>
+#include "thirdparty/linuxbsd_headers/speechd/libspeechd.h"
#undef SPDConnectionAddress__free
#undef spd_get_default_address
#undef spd_open
@@ -126,9 +123,6 @@
#undef spd_set_voice_pitch_all
#undef spd_set_voice_pitch_uid
#undef spd_get_voice_pitch
-#undef spd_set_voice_pitch_range
-#undef spd_set_voice_pitch_range_all
-#undef spd_set_voice_pitch_range_uid
#undef spd_set_volume
#undef spd_set_volume_all
#undef spd_set_volume_uid
@@ -206,9 +200,6 @@ int (*spd_set_voice_pitch_dylibloader_wrapper_speechd)( SPDConnection*, signed i
int (*spd_set_voice_pitch_all_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
int (*spd_set_voice_pitch_uid_dylibloader_wrapper_speechd)( SPDConnection*, signed int, unsigned int);
int (*spd_get_voice_pitch_dylibloader_wrapper_speechd)( SPDConnection*);
-int (*spd_set_voice_pitch_range_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
-int (*spd_set_voice_pitch_range_all_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
-int (*spd_set_voice_pitch_range_uid_dylibloader_wrapper_speechd)( SPDConnection*, signed int, unsigned int);
int (*spd_set_volume_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
int (*spd_set_volume_all_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
int (*spd_set_volume_uid_dylibloader_wrapper_speechd)( SPDConnection*, signed int, unsigned int);
@@ -589,30 +580,6 @@ int initialize_speechd(int verbose) {
fprintf(stderr, "%s\n", error);
}
}
-// spd_set_voice_pitch_range
- *(void **) (&spd_set_voice_pitch_range_dylibloader_wrapper_speechd) = dlsym(handle, "spd_set_voice_pitch_range");
- if (verbose) {
- error = dlerror();
- if (error != NULL) {
- fprintf(stderr, "%s\n", error);
- }
- }
-// spd_set_voice_pitch_range_all
- *(void **) (&spd_set_voice_pitch_range_all_dylibloader_wrapper_speechd) = dlsym(handle, "spd_set_voice_pitch_range_all");
- if (verbose) {
- error = dlerror();
- if (error != NULL) {
- fprintf(stderr, "%s\n", error);
- }
- }
-// spd_set_voice_pitch_range_uid
- *(void **) (&spd_set_voice_pitch_range_uid_dylibloader_wrapper_speechd) = dlsym(handle, "spd_set_voice_pitch_range_uid");
- if (verbose) {
- error = dlerror();
- if (error != NULL) {
- fprintf(stderr, "%s\n", error);
- }
- }
// spd_set_volume
*(void **) (&spd_set_volume_dylibloader_wrapper_speechd) = dlsym(handle, "spd_set_volume");
if (verbose) {
diff --git a/platform/linuxbsd/speechd-so_wrap.h b/platform/linuxbsd/speechd-so_wrap.h
index 8e1c053348..8e0762041a 100644
--- a/platform/linuxbsd/speechd-so_wrap.h
+++ b/platform/linuxbsd/speechd-so_wrap.h
@@ -2,8 +2,8 @@
#define DYLIBLOAD_WRAPPER_SPEECHD
// This file is generated. Do not edit!
// see https://github.com/hpvb/dynload-wrapper for details
-// generated by ./dynload-wrapper/generate-wrapper.py 0.3 on 2022-04-28 14:34:21
-// flags: ./dynload-wrapper/generate-wrapper.py --sys-include <libspeechd.h> --include /usr/include/speech-dispatcher/libspeechd.h --soname libspeechd.so.2 --init-name speechd --omit-prefix spd_get_client_list --output-header speechd-so_wrap.h --output-implementation speechd-so_wrap.c
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-12 10:07:46
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/speechd/libspeechd.h --sys-include "thirdparty/linuxbsd_headers/speechd/libspeechd.h" --soname libspeechd.so.2 --init-name speechd --omit-prefix spd_get_client_list --output-header ./platform/linuxbsd/speechd-so_wrap.h --output-implementation ./platform/linuxbsd/speechd-so_wrap.c
//
#include <stdint.h>
@@ -49,9 +49,6 @@
#define spd_set_voice_pitch_all spd_set_voice_pitch_all_dylibloader_orig_speechd
#define spd_set_voice_pitch_uid spd_set_voice_pitch_uid_dylibloader_orig_speechd
#define spd_get_voice_pitch spd_get_voice_pitch_dylibloader_orig_speechd
-#define spd_set_voice_pitch_range spd_set_voice_pitch_range_dylibloader_orig_speechd
-#define spd_set_voice_pitch_range_all spd_set_voice_pitch_range_all_dylibloader_orig_speechd
-#define spd_set_voice_pitch_range_uid spd_set_voice_pitch_range_uid_dylibloader_orig_speechd
#define spd_set_volume spd_set_volume_dylibloader_orig_speechd
#define spd_set_volume_all spd_set_volume_all_dylibloader_orig_speechd
#define spd_set_volume_uid spd_set_volume_uid_dylibloader_orig_speechd
@@ -85,7 +82,7 @@
#define spd_execute_command_wo_mutex spd_execute_command_wo_mutex_dylibloader_orig_speechd
#define spd_send_data spd_send_data_dylibloader_orig_speechd
#define spd_send_data_wo_mutex spd_send_data_wo_mutex_dylibloader_orig_speechd
-#include <libspeechd.h>
+#include "thirdparty/linuxbsd_headers/speechd/libspeechd.h"
#undef SPDConnectionAddress__free
#undef spd_get_default_address
#undef spd_open
@@ -128,9 +125,6 @@
#undef spd_set_voice_pitch_all
#undef spd_set_voice_pitch_uid
#undef spd_get_voice_pitch
-#undef spd_set_voice_pitch_range
-#undef spd_set_voice_pitch_range_all
-#undef spd_set_voice_pitch_range_uid
#undef spd_set_volume
#undef spd_set_volume_all
#undef spd_set_volume_uid
@@ -209,9 +203,6 @@ extern "C" {
#define spd_set_voice_pitch_all spd_set_voice_pitch_all_dylibloader_wrapper_speechd
#define spd_set_voice_pitch_uid spd_set_voice_pitch_uid_dylibloader_wrapper_speechd
#define spd_get_voice_pitch spd_get_voice_pitch_dylibloader_wrapper_speechd
-#define spd_set_voice_pitch_range spd_set_voice_pitch_range_dylibloader_wrapper_speechd
-#define spd_set_voice_pitch_range_all spd_set_voice_pitch_range_all_dylibloader_wrapper_speechd
-#define spd_set_voice_pitch_range_uid spd_set_voice_pitch_range_uid_dylibloader_wrapper_speechd
#define spd_set_volume spd_set_volume_dylibloader_wrapper_speechd
#define spd_set_volume_all spd_set_volume_all_dylibloader_wrapper_speechd
#define spd_set_volume_uid spd_set_volume_uid_dylibloader_wrapper_speechd
@@ -287,9 +278,6 @@ extern int (*spd_set_voice_pitch_dylibloader_wrapper_speechd)( SPDConnection*, s
extern int (*spd_set_voice_pitch_all_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
extern int (*spd_set_voice_pitch_uid_dylibloader_wrapper_speechd)( SPDConnection*, signed int, unsigned int);
extern int (*spd_get_voice_pitch_dylibloader_wrapper_speechd)( SPDConnection*);
-extern int (*spd_set_voice_pitch_range_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
-extern int (*spd_set_voice_pitch_range_all_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
-extern int (*spd_set_voice_pitch_range_uid_dylibloader_wrapper_speechd)( SPDConnection*, signed int, unsigned int);
extern int (*spd_set_volume_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
extern int (*spd_set_volume_all_dylibloader_wrapper_speechd)( SPDConnection*, signed int);
extern int (*spd_set_volume_uid_dylibloader_wrapper_speechd)( SPDConnection*, signed int, unsigned int);
diff --git a/platform/linuxbsd/tts_linux.cpp b/platform/linuxbsd/tts_linux.cpp
index aea1183d3d..4662aaf02d 100644
--- a/platform/linuxbsd/tts_linux.cpp
+++ b/platform/linuxbsd/tts_linux.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* tts_linux.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* tts_linux.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "tts_linux.h"
@@ -117,13 +117,12 @@ void TTS_Linux::speech_event_callback(size_t p_msg_id, size_t p_client_id, SPDNo
free_spd_voices(voices);
}
PackedInt32Array breaks = TS->string_get_word_breaks(message.text, language);
- int prev = 0;
- for (int i = 0; i < breaks.size(); i++) {
- text += message.text.substr(prev, breaks[i] - prev);
- text += "<mark name=\"" + String::num_int64(breaks[i], 10) + "\"/>";
- prev = breaks[i];
+ for (int i = 0; i < breaks.size(); i += 2) {
+ const int start = breaks[i];
+ const int end = breaks[i + 1];
+ text += message.text.substr(start, end - start + 1);
+ text += "<mark name=\"" + String::num_int64(end, 10) + "\"/>";
}
- text += message.text.substr(prev, -1);
spd_set_synthesis_voice(tts->synth, message.voice.utf8().get_data());
spd_set_volume(tts->synth, message.volume * 2 - 100);
diff --git a/platform/linuxbsd/tts_linux.h b/platform/linuxbsd/tts_linux.h
index 4e3f348ae4..425654d975 100644
--- a/platform/linuxbsd/tts_linux.h
+++ b/platform/linuxbsd/tts_linux.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* tts_linux.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* tts_linux.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef TTS_LINUX_H
#define TTS_LINUX_H
diff --git a/platform/linuxbsd/x11/SCsub b/platform/linuxbsd/x11/SCsub
new file mode 100644
index 0000000000..d869ce9ecc
--- /dev/null
+++ b/platform/linuxbsd/x11/SCsub
@@ -0,0 +1,30 @@
+#!/usr/bin/env python
+
+Import("env")
+
+source_files = [
+ "display_server_x11.cpp",
+ "key_mapping_x11.cpp",
+ "dynwrappers/xlib-so_wrap.c",
+ "dynwrappers/xcursor-so_wrap.c",
+ "dynwrappers/xinerama-so_wrap.c",
+ "dynwrappers/xinput2-so_wrap.c",
+ "dynwrappers/xkbcommon-so_wrap.c",
+ "dynwrappers/xrandr-so_wrap.c",
+ "dynwrappers/xrender-so_wrap.c",
+ "dynwrappers/xext-so_wrap.c",
+]
+
+if env["vulkan"]:
+ source_files.append("vulkan_context_x11.cpp")
+
+if env["opengl3"]:
+ env.Append(CPPDEFINES=["GLAD_GLX_NO_X11"])
+ source_files.append(["gl_manager_x11.cpp", "detect_prime_x11.cpp", "#thirdparty/glad/glx.c"])
+
+objects = []
+
+for source_file in source_files:
+ objects.append(env.Object(source_file))
+
+Return("objects")
diff --git a/platform/linuxbsd/detect_prime_x11.cpp b/platform/linuxbsd/x11/detect_prime_x11.cpp
index fb833ab5e6..8d586599e6 100644
--- a/platform/linuxbsd/detect_prime_x11.cpp
+++ b/platform/linuxbsd/x11/detect_prime_x11.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* detect_prime_x11.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* detect_prime_x11.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifdef X11_ENABLED
#if defined(GLES3_ENABLED)
@@ -38,10 +38,10 @@
#include <stdlib.h>
-#include <GL/gl.h>
-#include <GL/glx.h>
-#include <X11/Xlib.h>
-#include <X11/Xutil.h>
+#include "thirdparty/glad/glad/gl.h"
+#include "thirdparty/glad/glad/glx.h"
+
+#include "dynwrappers/xlib-so_wrap.h"
#include <cstring>
@@ -77,8 +77,6 @@ void create_context() {
Window x11_window;
GLXContext glx_context;
- GLXCREATECONTEXTATTRIBSARBPROC glXCreateContextAttribsARB = (GLXCREATECONTEXTATTRIBSARBPROC)glXGetProcAddress((const GLubyte *)"glXCreateContextAttribsARB");
-
static int visual_attribs[] = {
GLX_RENDER_TYPE, GLX_RGBA_BIT,
GLX_DRAWABLE_TYPE, GLX_WINDOW_BIT,
@@ -90,6 +88,10 @@ void create_context() {
None
};
+ if (gladLoaderLoadGLX(x11_display, XScreenNumberOfScreen(XDefaultScreenOfDisplay(x11_display))) == 0) {
+ print_verbose("Unable to load GLX, GPU detection skipped.");
+ quick_exit(1);
+ }
int fbcount;
GLXFBConfig fbconfig = nullptr;
XVisualInfo *vi = nullptr;
@@ -101,7 +103,7 @@ void create_context() {
GLXFBConfig *fbc = glXChooseFBConfig(x11_display, DefaultScreen(x11_display), visual_attribs, &fbcount);
if (!fbc) {
- exit(1);
+ quick_exit(1);
}
vi = glXGetVisualFromFBConfig(x11_display, fbc[0]);
@@ -122,7 +124,7 @@ void create_context() {
x11_window = XCreateWindow(x11_display, RootWindow(x11_display, vi->screen), 0, 0, 10, 10, 0, vi->depth, InputOutput, vi->visual, valuemask, &swa);
if (!x11_window) {
- exit(1);
+ quick_exit(1);
}
glXMakeCurrent(x11_display, x11_window, glx_context);
@@ -189,8 +191,15 @@ int detect_prime() {
if (i) {
setenv("DRI_PRIME", "1", 1);
}
+
create_context();
+ PFNGLGETSTRINGPROC glGetString = (PFNGLGETSTRINGPROC)glXGetProcAddressARB((GLubyte *)"glGetString");
+ if (!glGetString) {
+ print_verbose("Unable to get glGetString, GPU detection skipped.");
+ quick_exit(1);
+ }
+
const char *vendor = (const char *)glGetString(GL_VENDOR);
const char *renderer = (const char *)glGetString(GL_RENDERER);
@@ -208,7 +217,10 @@ int detect_prime() {
print_verbose("Couldn't write vendor/renderer string.");
}
close(fdset[1]);
- exit(0);
+
+ // The function quick_exit() is used because exit() will call destructors on static objects copied by fork().
+ // These objects will be freed anyway when the process finishes execution.
+ quick_exit(0);
}
}
diff --git a/platform/linuxbsd/detect_prime_x11.h b/platform/linuxbsd/x11/detect_prime_x11.h
index 21ebaead32..62fe426026 100644
--- a/platform/linuxbsd/detect_prime_x11.h
+++ b/platform/linuxbsd/x11/detect_prime_x11.h
@@ -1,38 +1,40 @@
-/*************************************************************************/
-/* detect_prime_x11.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* detect_prime_x11.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
-#ifdef X11_ENABLED
-#if defined(GLES3_ENABLED)
+#ifndef DETECT_PRIME_X11_H
+#define DETECT_PRIME_X11_H
+
+#if defined(X11_ENABLED) && defined(GLES3_ENABLED)
int detect_prime();
-#endif
+#endif // X11_ENABLED && GLES3_ENABLED
#endif // DETECT_PRIME_X11_H
diff --git a/platform/linuxbsd/display_server_x11.cpp b/platform/linuxbsd/x11/display_server_x11.cpp
index 607c583df8..9971fe8c79 100644
--- a/platform/linuxbsd/display_server_x11.cpp
+++ b/platform/linuxbsd/x11/display_server_x11.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* display_server_x11.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* display_server_x11.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "display_server_x11.h"
@@ -49,15 +49,14 @@
#include "drivers/gles3/rasterizer_gles3.h"
#endif
+#include <dlfcn.h>
#include <limits.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
-
-#include <X11/Xatom.h>
-#include <X11/Xutil.h>
-#include <X11/extensions/Xinerama.h>
-#include <X11/extensions/shape.h>
+#include <sys/stat.h>
+#include <sys/types.h>
+#include <unistd.h>
// ICCCM
#define WM_NormalState 1L // window normal state
@@ -66,17 +65,6 @@
#define _NET_WM_STATE_REMOVE 0L // remove/unset property
#define _NET_WM_STATE_ADD 1L // add/set property
-#include <dlfcn.h>
-#include <fcntl.h>
-#include <sys/stat.h>
-#include <sys/types.h>
-#include <unistd.h>
-
-//stupid linux.h
-#ifdef KEY_TAB
-#undef KEY_TAB
-#endif
-
#undef CursorShape
#include <X11/XKBlib.h>
@@ -133,7 +121,7 @@ bool DisplayServerX11::has_feature(Feature p_feature) const {
case FEATURE_WINDOW_TRANSPARENCY:
//case FEATURE_HIDPI:
case FEATURE_ICON:
- case FEATURE_NATIVE_ICON:
+ //case FEATURE_NATIVE_ICON:
case FEATURE_SWAP_BUFFERS:
#ifdef DBUS_ENABLED
case FEATURE_KEEP_SCREEN_ON:
@@ -383,10 +371,18 @@ void DisplayServerX11::mouse_set_mode(MouseMode p_mode) {
}
// The only modes that show a cursor are VISIBLE and CONFINED
- bool showCursor = (p_mode == MOUSE_MODE_VISIBLE || p_mode == MOUSE_MODE_CONFINED);
+ bool show_cursor = (p_mode == MOUSE_MODE_VISIBLE || p_mode == MOUSE_MODE_CONFINED);
+ bool previously_shown = (mouse_mode == MOUSE_MODE_VISIBLE || mouse_mode == MOUSE_MODE_CONFINED);
+
+ if (show_cursor && !previously_shown) {
+ WindowID window_id = get_window_at_screen_position(mouse_get_position());
+ if (window_id != INVALID_WINDOW_ID) {
+ _send_window_event(windows[window_id], WINDOW_EVENT_MOUSE_ENTER);
+ }
+ }
for (const KeyValue<WindowID, WindowData> &E : windows) {
- if (showCursor) {
+ if (show_cursor) {
XDefineCursor(x11_display, E.value.x11_window, cursors[current_cursor]); // show cursor
} else {
XDefineCursor(x11_display, E.value.x11_window, null_cursor); // hide cursor
@@ -397,7 +393,10 @@ void DisplayServerX11::mouse_set_mode(MouseMode p_mode) {
if (mouse_mode == MOUSE_MODE_CAPTURED || mouse_mode == MOUSE_MODE_CONFINED || mouse_mode == MOUSE_MODE_CONFINED_HIDDEN) {
//flush pending motion events
_flush_mouse_motion();
- WindowID window_id = windows.has(last_focused_window) ? last_focused_window : MAIN_WINDOW_ID;
+ WindowID window_id = _get_focused_window_or_popup();
+ if (!windows.has(window_id)) {
+ window_id = MAIN_WINDOW_ID;
+ }
WindowData &window = windows[window_id];
if (XGrabPointer(
@@ -433,7 +432,11 @@ void DisplayServerX11::warp_mouse(const Point2i &p_position) {
if (mouse_mode == MOUSE_MODE_CAPTURED) {
last_mouse_pos = p_position;
} else {
- WindowID window_id = windows.has(last_focused_window) ? last_focused_window : MAIN_WINDOW_ID;
+ WindowID window_id = _get_focused_window_or_popup();
+ if (!windows.has(window_id)) {
+ window_id = MAIN_WINDOW_ID;
+ }
+
XWarpPointer(x11_display, None, windows[window_id].x11_window,
0, 0, 0, 0, (int)p_position.x, (int)p_position.y);
}
@@ -455,7 +458,7 @@ Point2i DisplayServerX11::mouse_get_position() const {
return Vector2i();
}
-MouseButton DisplayServerX11::mouse_get_button_state() const {
+BitField<MouseButtonMask> DisplayServerX11::mouse_get_button_state() const {
return last_button_state;
}
@@ -748,11 +751,22 @@ int DisplayServerX11::get_screen_count() const {
return count;
}
+int DisplayServerX11::get_primary_screen() const {
+ return XDefaultScreen(x11_display);
+}
+
Rect2i DisplayServerX11::_screen_get_rect(int p_screen) const {
Rect2i rect(0, 0, 0, 0);
- if (p_screen == SCREEN_OF_MAIN_WINDOW) {
- p_screen = window_get_current_screen();
+ switch (p_screen) {
+ case SCREEN_PRIMARY: {
+ p_screen = get_primary_screen();
+ } break;
+ case SCREEN_OF_MAIN_WINDOW: {
+ p_screen = window_get_current_screen(MAIN_WINDOW_ID);
+ } break;
+ default:
+ break;
}
ERR_FAIL_COND_V(p_screen < 0, rect);
@@ -819,8 +833,15 @@ int bad_window_error_handler(Display *display, XErrorEvent *error) {
Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const {
_THREAD_SAFE_METHOD_
- if (p_screen == SCREEN_OF_MAIN_WINDOW) {
- p_screen = window_get_current_screen();
+ switch (p_screen) {
+ case SCREEN_PRIMARY: {
+ p_screen = get_primary_screen();
+ } break;
+ case SCREEN_OF_MAIN_WINDOW: {
+ p_screen = window_get_current_screen(MAIN_WINDOW_ID);
+ } break;
+ default:
+ break;
}
int screen_count = get_screen_count();
@@ -1015,7 +1036,7 @@ Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const {
Rect2i left_rect(pos.x, pos.y + left_start_y, left, left_end_y - left_start_y);
if (left_rect.size.x > 0) {
Rect2i intersection = rect.intersection(left_rect);
- if (!intersection.has_no_area() && intersection.size.x < rect.size.x) {
+ if (intersection.has_area() && intersection.size.x < rect.size.x) {
rect.position.x = left_rect.size.x;
rect.size.x = rect.size.x - intersection.size.x;
}
@@ -1024,7 +1045,7 @@ Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const {
Rect2i right_rect(pos.x + size.x - right, pos.y + right_start_y, right, right_end_y - right_start_y);
if (right_rect.size.x > 0) {
Rect2i intersection = rect.intersection(right_rect);
- if (!intersection.has_no_area() && right_rect.size.x < rect.size.x) {
+ if (intersection.has_area() && right_rect.size.x < rect.size.x) {
rect.size.x = intersection.position.x - rect.position.x;
}
}
@@ -1032,7 +1053,7 @@ Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const {
Rect2i top_rect(pos.x + top_start_x, pos.y, top_end_x - top_start_x, top);
if (top_rect.size.y > 0) {
Rect2i intersection = rect.intersection(top_rect);
- if (!intersection.has_no_area() && intersection.size.y < rect.size.y) {
+ if (intersection.has_area() && intersection.size.y < rect.size.y) {
rect.position.y = top_rect.size.y;
rect.size.y = rect.size.y - intersection.size.y;
}
@@ -1041,7 +1062,7 @@ Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const {
Rect2i bottom_rect(pos.x + bottom_start_x, pos.y + size.y - bottom, bottom_end_x - bottom_start_x, bottom);
if (bottom_rect.size.y > 0) {
Rect2i intersection = rect.intersection(bottom_rect);
- if (!intersection.has_no_area() && right_rect.size.y < rect.size.y) {
+ if (intersection.has_area() && right_rect.size.y < rect.size.y) {
rect.size.y = intersection.position.y - rect.position.y;
}
}
@@ -1099,8 +1120,15 @@ Rect2i DisplayServerX11::screen_get_usable_rect(int p_screen) const {
int DisplayServerX11::screen_get_dpi(int p_screen) const {
_THREAD_SAFE_METHOD_
- if (p_screen == SCREEN_OF_MAIN_WINDOW) {
- p_screen = window_get_current_screen();
+ switch (p_screen) {
+ case SCREEN_PRIMARY: {
+ p_screen = get_primary_screen();
+ } break;
+ case SCREEN_OF_MAIN_WINDOW: {
+ p_screen = window_get_current_screen(MAIN_WINDOW_ID);
+ } break;
+ default:
+ break;
}
//invalid screen?
@@ -1144,8 +1172,15 @@ int DisplayServerX11::screen_get_dpi(int p_screen) const {
float DisplayServerX11::screen_get_refresh_rate(int p_screen) const {
_THREAD_SAFE_METHOD_
- if (p_screen == SCREEN_OF_MAIN_WINDOW) {
- p_screen = window_get_current_screen();
+ switch (p_screen) {
+ case SCREEN_PRIMARY: {
+ p_screen = get_primary_screen();
+ } break;
+ case SCREEN_OF_MAIN_WINDOW: {
+ p_screen = window_get_current_screen(MAIN_WINDOW_ID);
+ } break;
+ default:
+ break;
}
//invalid screen?
@@ -1202,16 +1237,6 @@ float DisplayServerX11::screen_get_refresh_rate(int p_screen) const {
return SCREEN_REFRESH_RATE_FALLBACK;
}
-bool DisplayServerX11::screen_is_touchscreen(int p_screen) const {
- _THREAD_SAFE_METHOD_
-
-#ifndef _MSC_VER
-#warning Need to get from proper window
-#endif
-
- return DisplayServer::screen_is_touchscreen(p_screen);
-}
-
#ifdef DBUS_ENABLED
void DisplayServerX11::screen_set_keep_on(bool p_enable) {
if (screen_is_kept_on() == p_enable) {
@@ -1264,6 +1289,8 @@ void DisplayServerX11::show_window(WindowID p_id) {
DEBUG_LOG_X11("show_window: %lu (%u) \n", wd.x11_window, p_id);
XMapWindow(x11_display, wd.x11_window);
+ XSync(x11_display, False);
+ _validate_mode_on_map(p_id);
}
void DisplayServerX11::delete_sub_window(WindowID p_id) {
@@ -1297,6 +1324,8 @@ void DisplayServerX11::delete_sub_window(WindowID p_id) {
}
#endif
+ XDestroyWindow(x11_display, wd.x11_xim_window);
+
XUnmapWindow(x11_display, wd.x11_window);
XDestroyWindow(x11_display, wd.x11_window);
if (wd.xic) {
@@ -1319,6 +1348,14 @@ int64_t DisplayServerX11::window_get_native_handle(HandleType p_handle_type, Win
case WINDOW_VIEW: {
return 0; // Not supported.
}
+#ifdef GLES3_ENABLED
+ case OPENGL_CONTEXT: {
+ if (gl_manager) {
+ return (int64_t)gl_manager->get_glx_context(p_window);
+ }
+ return 0;
+ }
+#endif
default: {
return 0;
}
@@ -1385,31 +1422,35 @@ void DisplayServerX11::window_set_mouse_passthrough(const Vector<Vector2> &p_reg
_THREAD_SAFE_METHOD_
ERR_FAIL_COND(!windows.has(p_window));
- const WindowData &wd = windows[p_window];
+ windows[p_window].mpath = p_region;
+ _update_window_mouse_passthrough(p_window);
+}
+
+void DisplayServerX11::_update_window_mouse_passthrough(WindowID p_window) {
+ ERR_FAIL_COND(!windows.has(p_window));
+
+ const Vector<Vector2> region_path = windows[p_window].mpath;
int event_base, error_base;
const Bool ext_okay = XShapeQueryExtension(x11_display, &event_base, &error_base);
if (ext_okay) {
- Region region;
- if (p_region.size() == 0) {
- region = XCreateRegion();
- XRectangle rect;
- rect.x = 0;
- rect.y = 0;
- rect.width = window_get_real_size(p_window).x;
- rect.height = window_get_real_size(p_window).y;
- XUnionRectWithRegion(&rect, region, region);
+ if (windows[p_window].mpass) {
+ Region region = XCreateRegion();
+ XShapeCombineRegion(x11_display, windows[p_window].x11_window, ShapeInput, 0, 0, region, ShapeSet);
+ XDestroyRegion(region);
+ } else if (region_path.size() == 0) {
+ XShapeCombineMask(x11_display, windows[p_window].x11_window, ShapeInput, 0, 0, None, ShapeSet);
} else {
- XPoint *points = (XPoint *)memalloc(sizeof(XPoint) * p_region.size());
- for (int i = 0; i < p_region.size(); i++) {
- points[i].x = p_region[i].x;
- points[i].y = p_region[i].y;
+ XPoint *points = (XPoint *)memalloc(sizeof(XPoint) * region_path.size());
+ for (int i = 0; i < region_path.size(); i++) {
+ points[i].x = region_path[i].x;
+ points[i].y = region_path[i].y;
}
- region = XPolygonRegion(points, p_region.size(), EvenOddRule);
+ Region region = XPolygonRegion(points, region_path.size(), EvenOddRule);
memfree(points);
+ XShapeCombineRegion(x11_display, windows[p_window].x11_window, ShapeInput, 0, 0, region, ShapeSet);
+ XDestroyRegion(region);
}
- XShapeCombineRegion(x11_display, wd.x11_window, ShapeInput, 0, 0, region, ShapeSet);
- XDestroyRegion(region);
}
}
@@ -1497,23 +1538,39 @@ void DisplayServerX11::window_set_current_screen(int p_screen, WindowID p_window
ERR_FAIL_COND(!windows.has(p_window));
WindowData &wd = windows[p_window];
- if (p_screen == SCREEN_OF_MAIN_WINDOW) {
- p_screen = window_get_current_screen();
+ switch (p_screen) {
+ case SCREEN_PRIMARY: {
+ p_screen = get_primary_screen();
+ } break;
+ case SCREEN_OF_MAIN_WINDOW: {
+ p_screen = window_get_current_screen(MAIN_WINDOW_ID);
+ } break;
+ default:
+ break;
}
// Check if screen is valid
ERR_FAIL_INDEX(p_screen, get_screen_count());
+ if (window_get_current_screen(p_window) == p_screen) {
+ return;
+ }
+
if (window_get_mode(p_window) == WINDOW_MODE_FULLSCREEN) {
Point2i position = screen_get_position(p_screen);
Size2i size = screen_get_size(p_screen);
XMoveResizeWindow(x11_display, wd.x11_window, position.x, position.y, size.x, size.y);
} else {
- if (p_screen != window_get_current_screen(p_window)) {
- Vector2 ofs = window_get_position(p_window) - screen_get_position(window_get_current_screen(p_window));
- window_set_position(ofs + screen_get_position(p_screen), p_window);
+ Rect2i srect = screen_get_usable_rect(p_screen);
+ Point2i wpos = window_get_position(p_window) - screen_get_position(window_get_current_screen(p_window));
+ Size2i wsize = window_get_size(p_window);
+ wpos += srect.position;
+ if (srect != Rect2i()) {
+ wpos.x = CLAMP(wpos.x, srect.position.x, srect.position.x + srect.size.width - wsize.width / 3);
+ wpos.y = CLAMP(wpos.y, srect.position.y, srect.position.y + srect.size.height - wsize.height / 3);
}
+ window_set_position(wpos, p_window);
}
}
@@ -1581,7 +1638,7 @@ void DisplayServerX11::_update_size_hints(WindowID p_window) {
xsh->width = wd.size.width;
xsh->height = wd.size.height;
- if (window_mode == WINDOW_MODE_FULLSCREEN) {
+ if (window_mode == WINDOW_MODE_FULLSCREEN || window_mode == WINDOW_MODE_EXCLUSIVE_FULLSCREEN) {
// Do not set any other hints to prevent the window manager from ignoring the fullscreen flags
} else if (window_get_flag(WINDOW_FLAG_RESIZE_DISABLED, p_window)) {
// If resizing is disabled, use the forced size
@@ -1617,6 +1674,40 @@ Point2i DisplayServerX11::window_get_position(WindowID p_window) const {
return wd.position;
}
+Point2i DisplayServerX11::window_get_position_with_decorations(WindowID p_window) const {
+ _THREAD_SAFE_METHOD_
+
+ ERR_FAIL_COND_V(!windows.has(p_window), Size2i());
+ const WindowData &wd = windows[p_window];
+
+ if (wd.fullscreen) {
+ return wd.position;
+ }
+
+ XWindowAttributes xwa;
+ XSync(x11_display, False);
+ XGetWindowAttributes(x11_display, wd.x11_window, &xwa);
+ int x = wd.position.x;
+ int y = wd.position.y;
+ Atom prop = XInternAtom(x11_display, "_NET_FRAME_EXTENTS", True);
+ if (prop != None) {
+ Atom type;
+ int format;
+ unsigned long len;
+ unsigned long remaining;
+ unsigned char *data = nullptr;
+ if (XGetWindowProperty(x11_display, wd.x11_window, prop, 0, 4, False, AnyPropertyType, &type, &format, &len, &remaining, &data) == Success) {
+ if (format == 32 && len == 4 && data) {
+ long *extents = (long *)data;
+ x -= extents[0]; // left
+ y -= extents[2]; // top
+ }
+ XFree(data);
+ }
+ }
+ return Size2i(x, y);
+}
+
void DisplayServerX11::window_set_position(const Point2i &p_position, WindowID p_window) {
_THREAD_SAFE_METHOD_
@@ -1739,6 +1830,18 @@ void DisplayServerX11::window_set_size(const Size2i p_size, WindowID p_window) {
usleep(10000);
}
+
+ // Keep rendering context window size in sync
+#if defined(VULKAN_ENABLED)
+ if (context_vulkan) {
+ context_vulkan->window_resize(p_window, xwa.width, xwa.height);
+ }
+#endif
+#if defined(GLES3_ENABLED)
+ if (gl_manager) {
+ gl_manager->window_resize(p_window, xwa.width, xwa.height);
+ }
+#endif
}
Size2i DisplayServerX11::window_get_size(WindowID p_window) const {
@@ -1749,12 +1852,16 @@ Size2i DisplayServerX11::window_get_size(WindowID p_window) const {
return wd.size;
}
-Size2i DisplayServerX11::window_get_real_size(WindowID p_window) const {
+Size2i DisplayServerX11::window_get_size_with_decorations(WindowID p_window) const {
_THREAD_SAFE_METHOD_
ERR_FAIL_COND_V(!windows.has(p_window), Size2i());
const WindowData &wd = windows[p_window];
+ if (wd.fullscreen) {
+ return wd.size;
+ }
+
XWindowAttributes xwa;
XSync(x11_display, False);
XGetWindowAttributes(x11_display, wd.x11_window, &xwa);
@@ -1936,7 +2043,7 @@ void DisplayServerX11::_validate_mode_on_map(WindowID p_window) {
// Check if we applied any window modes that didn't take effect while unmapped
const WindowData &wd = windows[p_window];
if (wd.fullscreen && !_window_fullscreen_check(p_window)) {
- _set_wm_fullscreen(p_window, true);
+ _set_wm_fullscreen(p_window, true, wd.exclusive_fullscreen);
} else if (wd.maximized && !_window_maximize_check(p_window, "_NET_WM_STATE")) {
_set_wm_maximized(p_window, true);
} else if (wd.minimized && !_window_minimize_check(p_window)) {
@@ -2011,7 +2118,7 @@ void DisplayServerX11::_set_wm_minimized(WindowID p_window, bool p_enabled) {
wd.minimized = p_enabled;
}
-void DisplayServerX11::_set_wm_fullscreen(WindowID p_window, bool p_enabled) {
+void DisplayServerX11::_set_wm_fullscreen(WindowID p_window, bool p_enabled, bool p_exclusive) {
ERR_FAIL_COND(!windows.has(p_window));
WindowData &wd = windows[p_window];
@@ -2050,7 +2157,14 @@ void DisplayServerX11::_set_wm_fullscreen(WindowID p_window, bool p_enabled) {
// set bypass compositor hint
Atom bypass_compositor = XInternAtom(x11_display, "_NET_WM_BYPASS_COMPOSITOR", False);
- unsigned long compositing_disable_on = p_enabled ? 1 : 0;
+ unsigned long compositing_disable_on = 0; // Use default.
+ if (p_enabled) {
+ if (p_exclusive) {
+ compositing_disable_on = 1; // Force composition OFF to reduce overhead.
+ } else {
+ compositing_disable_on = 2; // Force composition ON to allow popup windows.
+ }
+ }
if (bypass_compositor != None) {
XChangeProperty(x11_display, wd.x11_window, bypass_compositor, XA_CARDINAL, 32, PropModeReplace, (unsigned char *)&compositing_disable_on, 1);
}
@@ -2096,8 +2210,9 @@ void DisplayServerX11::window_set_mode(WindowMode p_mode, WindowID p_window) {
case WINDOW_MODE_FULLSCREEN: {
//Remove full-screen
wd.fullscreen = false;
+ wd.exclusive_fullscreen = false;
- _set_wm_fullscreen(p_window, false);
+ _set_wm_fullscreen(p_window, false, false);
//un-maximize required for always on top
bool on_top = window_get_flag(WINDOW_FLAG_ALWAYS_ON_TOP, p_window);
@@ -2130,7 +2245,13 @@ void DisplayServerX11::window_set_mode(WindowMode p_mode, WindowID p_window) {
}
wd.fullscreen = true;
- _set_wm_fullscreen(p_window, true);
+ if (p_mode == WINDOW_MODE_EXCLUSIVE_FULLSCREEN) {
+ wd.exclusive_fullscreen = true;
+ _set_wm_fullscreen(p_window, true, true);
+ } else {
+ wd.exclusive_fullscreen = false;
+ _set_wm_fullscreen(p_window, true, false);
+ }
} break;
case WINDOW_MODE_MAXIMIZED: {
_set_wm_maximized(p_window, true);
@@ -2145,7 +2266,11 @@ DisplayServer::WindowMode DisplayServerX11::window_get_mode(WindowID p_window) c
const WindowData &wd = windows[p_window];
if (wd.fullscreen) { //if fullscreen, it's not in another mode
- return WINDOW_MODE_FULLSCREEN;
+ if (wd.exclusive_fullscreen) {
+ return WINDOW_MODE_EXCLUSIVE_FULLSCREEN;
+ } else {
+ return WINDOW_MODE_FULLSCREEN;
+ }
}
// Test maximized.
@@ -2193,6 +2318,7 @@ void DisplayServerX11::window_set_flag(WindowFlags p_flag, bool p_enabled, Windo
window_set_size(window_get_size(p_window), p_window);
wd.borderless = p_enabled;
+ _update_window_mouse_passthrough(p_window);
} break;
case WINDOW_FLAG_ALWAYS_ON_TOP: {
ERR_FAIL_COND_MSG(wd.transient_parent != INVALID_WINDOW_ID, "Can't make a window transient if the 'on top' flag is active.");
@@ -2226,6 +2352,10 @@ void DisplayServerX11::window_set_flag(WindowFlags p_flag, bool p_enabled, Windo
case WINDOW_FLAG_NO_FOCUS: {
wd.no_focus = p_enabled;
} break;
+ case WINDOW_FLAG_MOUSE_PASSTHROUGH: {
+ wd.mpass = p_enabled;
+ _update_window_mouse_passthrough(p_window);
+ } break;
case WINDOW_FLAG_POPUP: {
XWindowAttributes xwa;
XSync(x11_display, False);
@@ -2279,6 +2409,9 @@ bool DisplayServerX11::window_get_flag(WindowFlags p_flag, WindowID p_window) co
case WINDOW_FLAG_NO_FOCUS: {
return wd.no_focus;
} break;
+ case WINDOW_FLAG_MOUSE_PASSTHROUGH: {
+ return wd.mpass;
+ } break;
case WINDOW_FLAG_POPUP: {
return wd.is_popup;
} break;
@@ -2359,24 +2492,39 @@ void DisplayServerX11::window_set_ime_active(const bool p_active, WindowID p_win
ERR_FAIL_COND(!windows.has(p_window));
WindowData &wd = windows[p_window];
- wd.im_active = p_active;
-
if (!wd.xic) {
return;
}
+ if (!wd.focused) {
+ return;
+ }
// Block events polling while changing input focus
// because it triggers some event polling internally.
if (p_active) {
- {
- MutexLock mutex_lock(events_mutex);
- XSetICFocus(wd.xic);
+ MutexLock mutex_lock(events_mutex);
+
+ wd.ime_active = true;
+
+ XMapWindow(x11_display, wd.x11_xim_window);
+
+ XWindowAttributes xwa;
+ XSync(x11_display, False);
+ XGetWindowAttributes(x11_display, wd.x11_xim_window, &xwa);
+ if (xwa.map_state == IsViewable) {
+ XSetInputFocus(x11_display, wd.x11_xim_window, RevertToPointerRoot, CurrentTime);
}
- window_set_ime_position(wd.im_position, p_window);
+ XSetICFocus(wd.xic);
} else {
MutexLock mutex_lock(events_mutex);
XUnsetICFocus(wd.xic);
+ XUnmapWindow(x11_display, wd.x11_xim_window);
+ wd.ime_active = false;
+
+ im_text = String();
+ im_selection = Vector2i();
}
+ OS_Unix::get_singleton()->get_main_loop()->notification(MainLoop::NOTIFICATION_OS_IME_UPDATE);
}
void DisplayServerX11::window_set_ime_position(const Point2i &p_pos, WindowID p_window) {
@@ -2385,25 +2533,29 @@ void DisplayServerX11::window_set_ime_position(const Point2i &p_pos, WindowID p_
ERR_FAIL_COND(!windows.has(p_window));
WindowData &wd = windows[p_window];
- wd.im_position = p_pos;
-
if (!wd.xic) {
return;
}
+ if (!wd.focused) {
+ return;
+ }
- ::XPoint spot;
- spot.x = short(p_pos.x);
- spot.y = short(p_pos.y);
- XVaNestedList preedit_attr = XVaCreateNestedList(0, XNSpotLocation, &spot, nullptr);
-
- {
- // Block events polling during this call
- // because it triggers some event polling internally.
- MutexLock mutex_lock(events_mutex);
- XSetICValues(wd.xic, XNPreeditAttributes, preedit_attr, nullptr);
+ if (wd.ime_active) {
+ XWindowAttributes xwa;
+ XSync(x11_display, False);
+ XGetWindowAttributes(x11_display, wd.x11_xim_window, &xwa);
+ if (xwa.map_state == IsViewable) {
+ XMoveWindow(x11_display, wd.x11_xim_window, p_pos.x, p_pos.y);
+ }
}
+}
+
+Point2i DisplayServerX11::ime_get_selection() const {
+ return im_selection;
+}
- XFree(preedit_attr);
+String DisplayServerX11::ime_get_text() const {
+ return im_text;
}
void DisplayServerX11::cursor_set_shape(CursorShape p_shape) {
@@ -2724,13 +2876,13 @@ void DisplayServerX11::_get_key_modifier_state(unsigned int p_x11_state, Ref<Inp
state->set_meta_pressed((p_x11_state & Mod4Mask));
}
-MouseButton DisplayServerX11::_get_mouse_button_state(MouseButton p_x11_button, int p_x11_type) {
- MouseButton mask = mouse_button_to_mask(p_x11_button);
+BitField<MouseButtonMask> DisplayServerX11::_get_mouse_button_state(MouseButton p_x11_button, int p_x11_type) {
+ MouseButtonMask mask = mouse_button_to_mask(p_x11_button);
if (p_x11_type == ButtonPress) {
- last_button_state |= mask;
+ last_button_state.set_flag(mask);
} else {
- last_button_state &= ~mask;
+ last_button_state.clear_flag(mask);
}
return last_button_state;
@@ -2741,6 +2893,16 @@ void DisplayServerX11::_handle_key_event(WindowID p_window, XKeyEvent *p_event,
// X11 functions don't know what const is
XKeyEvent *xkeyevent = p_event;
+ if (wd.ime_in_progress) {
+ return;
+ }
+ if (wd.ime_suppress_next_keyup) {
+ wd.ime_suppress_next_keyup = false;
+ if (xkeyevent->type != KeyPress) {
+ return;
+ }
+ }
+
// This code was pretty difficult to write.
// The docs stink and every toolkit seems to
// do it in a different way.
@@ -2764,12 +2926,18 @@ void DisplayServerX11::_handle_key_event(WindowID p_window, XKeyEvent *p_event,
KeySym keysym_unicode = 0; // keysym used to find unicode
// XLookupString returns keysyms usable as nice keycodes.
- char str[256 + 1];
+ char str[256] = {};
XKeyEvent xkeyevent_no_mod = *xkeyevent;
xkeyevent_no_mod.state &= ~ShiftMask;
xkeyevent_no_mod.state &= ~ControlMask;
- XLookupString(xkeyevent, str, 256, &keysym_unicode, nullptr);
- XLookupString(&xkeyevent_no_mod, nullptr, 0, &keysym_keycode, nullptr);
+ XLookupString(xkeyevent, str, 255, &keysym_unicode, nullptr);
+
+ String keysym;
+ if (xkb_keysym_to_utf32 && xkb_keysym_to_upper) {
+ KeySym keysym_unicode_nm = 0; // keysym used to find unicode
+ XLookupString(&xkeyevent_no_mod, nullptr, 0, &keysym_unicode_nm, nullptr);
+ keysym = String::chr(xkb_keysym_to_utf32(xkb_keysym_to_upper(keysym_unicode_nm)));
+ }
// Meanwhile, XLookupString returns keysyms useful for unicode.
@@ -2819,13 +2987,18 @@ void DisplayServerX11::_handle_key_event(WindowID p_window, XKeyEvent *p_event,
_get_key_modifier_state(xkeyevent->state, k);
k->set_window_id(p_window);
- k->set_unicode(tmp[i]);
-
k->set_pressed(keypress);
k->set_keycode(keycode);
-
- k->set_physical_keycode((Key)physical_keycode);
+ k->set_physical_keycode(physical_keycode);
+ if (!keysym.is_empty()) {
+ k->set_key_label(fix_key_label(keysym[0], keycode));
+ } else {
+ k->set_key_label(keycode);
+ }
+ if (keypress) {
+ k->set_unicode(fix_unicode(tmp[i]));
+ }
k->set_echo(false);
@@ -2868,7 +3041,7 @@ void DisplayServerX11::_handle_key_event(WindowID p_window, XKeyEvent *p_event,
// KeyMappingX11 also translates keysym to unicode.
// It does a binary search on a table to translate
// most properly.
- unsigned int unicode = keysym_unicode > 0 ? KeyMappingX11::get_unicode_from_keysym(keysym_unicode) : 0;
+ char32_t unicode = keysym_unicode > 0 ? KeyMappingX11::get_unicode_from_keysym(keysym_unicode) : 0;
/* Phase 4, determine if event must be filtered */
@@ -2954,7 +3127,14 @@ void DisplayServerX11::_handle_key_event(WindowID p_window, XKeyEvent *p_event,
k->set_keycode(keycode);
k->set_physical_keycode((Key)physical_keycode);
- k->set_unicode(unicode);
+ if (!keysym.is_empty()) {
+ k->set_key_label(fix_key_label(keysym[0], keycode));
+ } else {
+ k->set_key_label(keycode);
+ }
+ if (keypress) {
+ k->set_unicode(fix_unicode(unicode));
+ }
k->set_echo(p_echo);
if (k->get_keycode() == Key::BACKTAB) {
@@ -3106,6 +3286,80 @@ void DisplayServerX11::_handle_selection_request_event(XSelectionRequestEvent *p
XFlush(x11_display);
}
+int DisplayServerX11::_xim_preedit_start_callback(::XIM xim, ::XPointer client_data,
+ ::XPointer call_data) {
+ DisplayServerX11 *ds = reinterpret_cast<DisplayServerX11 *>(client_data);
+ WindowID window_id = ds->_get_focused_window_or_popup();
+ WindowData &wd = ds->windows[window_id];
+ if (wd.ime_active) {
+ wd.ime_in_progress = true;
+ }
+
+ return -1; // Allow preedit strings of any length (no limit).
+}
+
+void DisplayServerX11::_xim_preedit_done_callback(::XIM xim, ::XPointer client_data,
+ ::XPointer call_data) {
+ DisplayServerX11 *ds = reinterpret_cast<DisplayServerX11 *>(client_data);
+ WindowID window_id = ds->_get_focused_window_or_popup();
+ WindowData &wd = ds->windows[window_id];
+ if (wd.ime_active) {
+ wd.ime_in_progress = false;
+ wd.ime_suppress_next_keyup = true;
+ }
+}
+
+void DisplayServerX11::_xim_preedit_draw_callback(::XIM xim, ::XPointer client_data,
+ ::XIMPreeditDrawCallbackStruct *call_data) {
+ DisplayServerX11 *ds = reinterpret_cast<DisplayServerX11 *>(client_data);
+ WindowID window_id = ds->_get_focused_window_or_popup();
+ WindowData &wd = ds->windows[window_id];
+
+ XIMText *xim_text = call_data->text;
+ if (xim_text != nullptr) {
+ String changed_text;
+ if (xim_text->encoding_is_wchar) {
+ changed_text = String(xim_text->string.wide_char);
+ } else {
+ changed_text.parse_utf8(xim_text->string.multi_byte);
+ }
+
+ if (call_data->chg_length < 0) {
+ ds->im_text = ds->im_text.substr(0, call_data->chg_first) + changed_text;
+ } else {
+ ds->im_text = ds->im_text.substr(0, call_data->chg_first) + changed_text + ds->im_text.substr(call_data->chg_length);
+ }
+
+ // Find the start and end of the selection.
+ int start = 0, count = 0;
+ for (int i = 0; i < xim_text->length; i++) {
+ if (xim_text->feedback[i] & XIMReverse) {
+ if (count == 0) {
+ start = i;
+ count = 1;
+ } else {
+ count++;
+ }
+ }
+ }
+ if (count > 0) {
+ ds->im_selection = Point2i(start + call_data->chg_first, count);
+ } else {
+ ds->im_selection = Point2i(call_data->caret, 0);
+ }
+ } else {
+ ds->im_text = String();
+ ds->im_selection = Point2i();
+ }
+ if (wd.ime_active) {
+ OS_Unix::get_singleton()->get_main_loop()->notification(MainLoop::NOTIFICATION_OS_IME_UPDATE);
+ }
+}
+
+void DisplayServerX11::_xim_preedit_caret_callback(::XIM xim, ::XPointer client_data,
+ ::XIMPreeditCaretCallbackStruct *call_data) {
+}
+
void DisplayServerX11::_xim_destroy_callback(::XIM im, ::XPointer client_data,
::XPointer call_data) {
WARN_PRINT("Input method stopped");
@@ -3135,9 +3389,14 @@ void DisplayServerX11::_window_changed(XEvent *event) {
return;
}
+ // Query display server about a possible new window state.
+ wd.fullscreen = _window_fullscreen_check(window_id);
+ wd.minimized = _window_minimize_check(window_id);
+ wd.maximized = _window_maximize_check(window_id, "_NET_WM_STATE");
+
{
//the position in xconfigure is not useful here, obtain it manually
- int x, y;
+ int x = 0, y = 0;
Window child;
XTranslateCoordinates(x11_display, wd.x11_window, DefaultRootWindow(x11_display), 0, 0, &x, &y, &child);
new_rect.position.x = x;
@@ -3150,10 +3409,6 @@ void DisplayServerX11::_window_changed(XEvent *event) {
if (new_rect == Rect2i(wd.position, wd.size)) {
return;
}
- if (wd.xic) {
- // Not portable.
- window_set_ime_position(Point2(0, 1));
- }
wd.position = new_rect.position;
wd.size = new_rect.size;
@@ -3181,6 +3436,15 @@ void DisplayServerX11::_window_changed(XEvent *event) {
}
}
+DisplayServer::WindowID DisplayServerX11::_get_focused_window_or_popup() const {
+ const List<WindowID>::Element *E = popup_list.back();
+ if (E) {
+ return E->get();
+ }
+
+ return last_focused_window;
+}
+
void DisplayServerX11::_dispatch_input_events(const Ref<InputEvent> &p_event) {
static_cast<DisplayServerX11 *>(get_singleton())->_dispatch_input_event(p_event);
}
@@ -3291,7 +3555,7 @@ void DisplayServerX11::_check_pending_events(LocalVector<XEvent> &r_events) {
XFlush(x11_display);
// Non-blocking wait for next event and remove it from the queue.
- XEvent ev;
+ XEvent ev = {};
while (XCheckIfEvent(x11_display, &ev, _predicate_all_events, nullptr)) {
// Check if the input manager wants to process the event.
if (XFilterEvent(&ev, None)) {
@@ -3398,7 +3662,7 @@ bool DisplayServerX11::mouse_process_popups() {
XWindowAttributes root_attrs;
XGetWindowAttributes(x11_display, root, &root_attrs);
Vector2i pos = Vector2i(root_attrs.x + root_x, root_attrs.y + root_y);
- if ((pos != last_mouse_monitor_pos) || (mask != last_mouse_monitor_mask)) {
+ if (mask != last_mouse_monitor_mask) {
if (((mask & Button1Mask) || (mask & Button2Mask) || (mask & Button3Mask) || (mask & Button4Mask) || (mask & Button5Mask))) {
List<WindowID>::Element *C = nullptr;
List<WindowID>::Element *E = popup_list.back();
@@ -3424,7 +3688,6 @@ bool DisplayServerX11::mouse_process_popups() {
}
}
last_mouse_monitor_mask = mask;
- last_mouse_monitor_pos = pos;
}
}
return closed;
@@ -3493,6 +3756,7 @@ void DisplayServerX11::process_events() {
continue;
}
+ bool ime_window_event = false;
WindowID window_id = MAIN_WINDOW_ID;
// Assign the event to the relevant window
@@ -3501,6 +3765,11 @@ void DisplayServerX11::process_events() {
window_id = E.key;
break;
}
+ if (event.xany.window == E.value.x11_xim_window) {
+ window_id = E.key;
+ ime_window_event = true;
+ break;
+ }
}
if (XGetEventData(x11_display, &event.xcookie)) {
@@ -3515,6 +3784,9 @@ void DisplayServerX11::process_events() {
_refresh_device_info();
} break;
case XI_RawMotion: {
+ if (ime_window_event) {
+ break;
+ }
XIRawEvent *raw_event = (XIRawEvent *)event_data;
int device_id = raw_event->sourceid;
@@ -3617,6 +3889,9 @@ void DisplayServerX11::process_events() {
#ifdef TOUCH_ENABLED
case XI_TouchBegin:
case XI_TouchEnd: {
+ if (ime_window_event) {
+ break;
+ }
bool is_begin = event_data->evtype == XI_TouchBegin;
Ref<InputEventScreenTouch> st;
@@ -3647,6 +3922,9 @@ void DisplayServerX11::process_events() {
} break;
case XI_TouchUpdate: {
+ if (ime_window_event) {
+ break;
+ }
HashMap<int, Vector2>::Iterator curr_pos_elem = xi.state.find(index);
if (!curr_pos_elem) { // Defensive
break;
@@ -3673,6 +3951,9 @@ void DisplayServerX11::process_events() {
switch (event.type) {
case MapNotify: {
DEBUG_LOG_X11("[%u] MapNotify window=%lu (%u) \n", frame, event.xmap.window, window_id);
+ if (ime_window_event) {
+ break;
+ }
const WindowData &wd = windows[window_id];
@@ -3693,6 +3974,9 @@ void DisplayServerX11::process_events() {
case Expose: {
DEBUG_LOG_X11("[%u] Expose window=%lu (%u), count='%u' \n", frame, event.xexpose.window, window_id, event.xexpose.count);
+ if (ime_window_event) {
+ break;
+ }
windows[window_id].fullscreen = _window_fullscreen_check(window_id);
@@ -3701,18 +3985,27 @@ void DisplayServerX11::process_events() {
case NoExpose: {
DEBUG_LOG_X11("[%u] NoExpose drawable=%lu (%u) \n", frame, event.xnoexpose.drawable, window_id);
+ if (ime_window_event) {
+ break;
+ }
windows[window_id].minimized = true;
} break;
case VisibilityNotify: {
DEBUG_LOG_X11("[%u] VisibilityNotify window=%lu (%u), state=%u \n", frame, event.xvisibility.window, window_id, event.xvisibility.state);
+ if (ime_window_event) {
+ break;
+ }
windows[window_id].minimized = _window_minimize_check(window_id);
} break;
case LeaveNotify: {
DEBUG_LOG_X11("[%u] LeaveNotify window=%lu (%u), mode='%u' \n", frame, event.xcrossing.window, window_id, event.xcrossing.mode);
+ if (ime_window_event) {
+ break;
+ }
if (!mouse_mode_grab) {
_send_window_event(windows[window_id], WINDOW_EVENT_MOUSE_EXIT);
@@ -3722,6 +4015,9 @@ void DisplayServerX11::process_events() {
case EnterNotify: {
DEBUG_LOG_X11("[%u] EnterNotify window=%lu (%u), mode='%u' \n", frame, event.xcrossing.window, window_id, event.xcrossing.mode);
+ if (ime_window_event) {
+ break;
+ }
if (!mouse_mode_grab) {
_send_window_event(windows[window_id], WINDOW_EVENT_MOUSE_ENTER);
@@ -3730,18 +4026,14 @@ void DisplayServerX11::process_events() {
case FocusIn: {
DEBUG_LOG_X11("[%u] FocusIn window=%lu (%u), mode='%u' \n", frame, event.xfocus.window, window_id, event.xfocus.mode);
+ if (ime_window_event) {
+ break;
+ }
WindowData &wd = windows[window_id];
last_focused_window = window_id;
wd.focused = true;
- if (wd.xic) {
- // Block events polling while changing input focus
- // because it triggers some event polling internally.
- MutexLock mutex_lock(events_mutex);
- XSetICFocus(wd.xic);
- }
-
// Keep track of focus order for overlapping windows.
static unsigned int focus_order = 0;
wd.focus_order = ++focus_order;
@@ -3781,17 +4073,20 @@ void DisplayServerX11::process_events() {
case FocusOut: {
DEBUG_LOG_X11("[%u] FocusOut window=%lu (%u), mode='%u' \n", frame, event.xfocus.window, window_id, event.xfocus.mode);
-
WindowData &wd = windows[window_id];
-
- wd.focused = false;
-
- if (wd.xic) {
- // Block events polling while changing input focus
- // because it triggers some event polling internally.
+ if (wd.ime_active && event.xfocus.detail == NotifyInferior) {
+ break;
+ }
+ if (wd.ime_active) {
MutexLock mutex_lock(events_mutex);
XUnsetICFocus(wd.xic);
+ XUnmapWindow(x11_display, wd.x11_xim_window);
+ wd.ime_active = false;
+ im_text = String();
+ im_selection = Vector2i();
+ OS_Unix::get_singleton()->get_main_loop()->notification(MainLoop::NOTIFICATION_OS_IME_UPDATE);
}
+ wd.focused = false;
Input::get_singleton()->release_pressed_events();
_send_window_event(wd, WINDOW_EVENT_FOCUS_OUT);
@@ -3827,6 +4122,9 @@ void DisplayServerX11::process_events() {
case ConfigureNotify: {
DEBUG_LOG_X11("[%u] ConfigureNotify window=%lu (%u), event=%lu, above=%lu, override_redirect=%u \n", frame, event.xconfigure.window, window_id, event.xconfigure.event, event.xconfigure.above, event.xconfigure.override_redirect);
+ if (event.xconfigure.window == windows[window_id].x11_xim_window) {
+ break;
+ }
const WindowData &wd = windows[window_id];
@@ -3846,6 +4144,9 @@ void DisplayServerX11::process_events() {
case ButtonPress:
case ButtonRelease: {
+ if (ime_window_event) {
+ break;
+ }
/* exit in case of a mouse button press */
last_timestamp = event.xbutton.time;
if (mouse_mode == MOUSE_MODE_CAPTURED) {
@@ -3903,40 +4204,58 @@ void DisplayServerX11::process_events() {
} else {
DEBUG_LOG_X11("[%u] ButtonRelease window=%lu (%u), button_index=%u \n", frame, event.xbutton.window, window_id, mb->get_button_index());
- if (!wd.focused) {
+ WindowID window_id_other = INVALID_WINDOW_ID;
+ Window wd_other_x11_window;
+ if (wd.focused) {
+ // Handle cases where an unfocused popup is open that needs to receive button-up events.
+ WindowID popup_id = _get_focused_window_or_popup();
+ if (popup_id != INVALID_WINDOW_ID && popup_id != window_id) {
+ window_id_other = popup_id;
+ wd_other_x11_window = windows[popup_id].x11_window;
+ }
+ } else {
// Propagate the event to the focused window,
// because it's received only on the topmost window.
// Note: This is needed for drag & drop to work between windows,
// because the engine expects events to keep being processed
// on the same window dragging started.
for (const KeyValue<WindowID, WindowData> &E : windows) {
- const WindowData &wd_other = E.value;
- WindowID window_id_other = E.key;
- if (wd_other.focused) {
- if (window_id_other != window_id) {
- int x, y;
- Window child;
- XTranslateCoordinates(x11_display, wd.x11_window, wd_other.x11_window, event.xbutton.x, event.xbutton.y, &x, &y, &child);
-
- mb->set_window_id(window_id_other);
- mb->set_position(Vector2(x, y));
- mb->set_global_position(mb->get_position());
- Input::get_singleton()->parse_input_event(mb);
+ if (E.value.focused) {
+ if (E.key != window_id) {
+ window_id_other = E.key;
+ wd_other_x11_window = E.value.x11_window;
}
break;
}
}
}
+
+ if (window_id_other != INVALID_WINDOW_ID) {
+ int x, y;
+ Window child;
+ XTranslateCoordinates(x11_display, wd.x11_window, wd_other_x11_window, event.xbutton.x, event.xbutton.y, &x, &y, &child);
+
+ mb->set_window_id(window_id_other);
+ mb->set_position(Vector2(x, y));
+ mb->set_global_position(mb->get_position());
+ }
}
Input::get_singleton()->parse_input_event(mb);
} break;
case MotionNotify: {
+ if (ime_window_event) {
+ break;
+ }
// The X11 API requires filtering one-by-one through the motion
// notify events, in order to figure out which event is the one
// generated by warping the mouse pointer.
- WindowID focused_window_id = windows.has(last_focused_window) ? last_focused_window : MAIN_WINDOW_ID;
+ WindowID focused_window_id = _get_focused_window_or_popup();
+ if (!windows.has(focused_window_id)) {
+ focused_window_id = MAIN_WINDOW_ID;
+ }
+
while (true) {
if (mouse_mode == MOUSE_MODE_CAPTURED && event.xmotion.x == windows[focused_window_id].size.width / 2 && event.xmotion.y == windows[focused_window_id].size.height / 2) {
//this is likely the warp event since it was warped here
@@ -4024,13 +4343,13 @@ void DisplayServerX11::process_events() {
if (xi.pressure_supported) {
mm->set_pressure(xi.pressure);
} else {
- mm->set_pressure(bool(mouse_get_button_state() & MouseButton::MASK_LEFT) ? 1.0f : 0.0f);
+ mm->set_pressure(bool(mouse_get_button_state().has_flag(MouseButtonMask::LEFT)) ? 1.0f : 0.0f);
}
mm->set_tilt(xi.tilt);
mm->set_pen_inverted(xi.pen_inverted);
_get_key_modifier_state(event.xmotion.state, mm);
- mm->set_button_mask((MouseButton)mouse_get_button_state());
+ mm->set_button_mask(mouse_get_button_state());
mm->set_position(pos);
mm->set_global_position(pos);
mm->set_velocity(Input::get_singleton()->get_last_mouse_velocity());
@@ -4089,14 +4408,16 @@ void DisplayServerX11::process_events() {
} break;
case SelectionNotify:
-
+ if (ime_window_event) {
+ break;
+ }
if (event.xselection.target == requested) {
Property p = _read_property(x11_display, windows[window_id].x11_window, XInternAtom(x11_display, "PRIMARY", 0));
- Vector<String> files = String((char *)p.data).split("\n", false);
+ Vector<String> files = String((char *)p.data).split("\r\n", false);
XFree(p.data);
for (int i = 0; i < files.size(); i++) {
- files.write[i] = files[i].replace("file://", "").uri_decode().strip_edges();
+ files.write[i] = files[i].replace("file://", "").uri_decode();
}
if (!windows[window_id].drop_files_callback.is_null()) {
@@ -4124,7 +4445,9 @@ void DisplayServerX11::process_events() {
break;
case ClientMessage:
-
+ if (ime_window_event) {
+ break;
+ }
if ((unsigned int)event.xclient.data.l[0] == (unsigned int)wm_delete) {
_send_window_event(windows[window_id], WINDOW_EVENT_CLOSE_REQUEST);
}
@@ -4379,7 +4702,7 @@ void DisplayServerX11::window_set_vsync_mode(DisplayServer::VSyncMode p_vsync_mo
#if defined(GLES3_ENABLED)
if (gl_manager) {
- gl_manager->set_use_vsync(p_vsync_mode == DisplayServer::VSYNC_ENABLED);
+ gl_manager->set_use_vsync(p_vsync_mode != DisplayServer::VSYNC_DISABLED);
}
#endif
}
@@ -4412,13 +4735,26 @@ Vector<String> DisplayServerX11::get_rendering_drivers_func() {
return drivers;
}
-DisplayServer *DisplayServerX11::create_func(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i &p_resolution, Error &r_error) {
- DisplayServer *ds = memnew(DisplayServerX11(p_rendering_driver, p_mode, p_vsync_mode, p_flags, p_resolution, r_error));
+DisplayServer *DisplayServerX11::create_func(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Error &r_error) {
+ DisplayServer *ds = memnew(DisplayServerX11(p_rendering_driver, p_mode, p_vsync_mode, p_flags, p_position, p_resolution, p_screen, r_error));
if (r_error != OK) {
- OS::get_singleton()->alert("Your video card driver does not support any of the supported Vulkan or OpenGL versions.\n"
- "Please update your drivers or if you have a very old or integrated GPU, upgrade it.\n"
- "If you have updated your graphics drivers recently, try rebooting.",
- "Unable to initialize Video driver");
+ if (p_rendering_driver == "vulkan") {
+ String executable_name = OS::get_singleton()->get_executable_path().get_file();
+ OS::get_singleton()->alert(
+ vformat("Your video card drivers seem not to support the required Vulkan version.\n\n"
+ "If possible, consider updating your video card drivers or using the OpenGL 3 driver.\n\n"
+ "You can enable the OpenGL 3 driver by starting the engine from the\n"
+ "command line with the command:\n'%s --rendering-driver opengl3'\n\n"
+ "If you recently updated your video card drivers, try rebooting.",
+ executable_name),
+ "Unable to initialize Vulkan video driver");
+ } else {
+ OS::get_singleton()->alert(
+ "Your video card drivers seem not to support the required OpenGL 3.3 version.\n\n"
+ "If possible, consider updating your video card drivers.\n\n"
+ "If you recently updated your video card drivers, try rebooting.",
+ "Unable to initialize OpenGL video driver");
+ }
}
return ds;
}
@@ -4499,8 +4835,28 @@ DisplayServerX11::WindowID DisplayServerX11::_create_window(WindowMode p_mode, V
valuemask |= CWOverrideRedirect | CWSaveUnder;
}
+ int rq_screen = get_screen_from_rect(p_rect);
+ if (rq_screen < 0) {
+ rq_screen = get_primary_screen(); // Requested window rect is outside any screen bounds.
+ }
+
+ Rect2i win_rect = p_rect;
+ if (p_mode == WINDOW_MODE_FULLSCREEN || p_mode == WINDOW_MODE_EXCLUSIVE_FULLSCREEN) {
+ Rect2i screen_rect = Rect2i(screen_get_position(rq_screen), screen_get_size(rq_screen));
+
+ win_rect = screen_rect;
+ } else {
+ Rect2i srect = screen_get_usable_rect(rq_screen);
+ Point2i wpos = p_rect.position;
+ wpos.x = CLAMP(wpos.x, srect.position.x, srect.position.x + srect.size.width - p_rect.size.width / 3);
+ wpos.y = CLAMP(wpos.y, srect.position.y, srect.position.y + srect.size.height - p_rect.size.height / 3);
+
+ win_rect.position = wpos;
+ }
+
{
- wd.x11_window = XCreateWindow(x11_display, RootWindow(x11_display, visualInfo.screen), p_rect.position.x, p_rect.position.y, p_rect.size.width > 0 ? p_rect.size.width : 1, p_rect.size.height > 0 ? p_rect.size.height : 1, 0, visualInfo.depth, InputOutput, visualInfo.visual, valuemask, &windowAttributes);
+ wd.x11_window = XCreateWindow(x11_display, RootWindow(x11_display, visualInfo.screen), win_rect.position.x, win_rect.position.y, win_rect.size.width > 0 ? win_rect.size.width : 1, win_rect.size.height > 0 ? win_rect.size.height : 1, 0, visualInfo.depth, InputOutput, visualInfo.visual, valuemask, &windowAttributes);
+ wd.x11_xim_window = XCreateWindow(x11_display, wd.x11_window, 0, 0, 1, 1, 0, visualInfo.depth, InputOutput, visualInfo.visual, valuemask, &windowAttributes);
// Enable receiving notification when the window is initialized (MapNotify)
// so the focus can be set at the right time.
@@ -4572,7 +4928,50 @@ DisplayServerX11::WindowID DisplayServerX11::_create_window(WindowMode p_mode, V
// because it triggers some event polling internally.
MutexLock mutex_lock(events_mutex);
- wd.xic = XCreateIC(xim, XNInputStyle, xim_style, XNClientWindow, wd.x11_window, XNFocusWindow, wd.x11_window, (char *)nullptr);
+ // Force on-the-spot for the over-the-spot style.
+ if ((xim_style & XIMPreeditPosition) != 0) {
+ xim_style &= ~XIMPreeditPosition;
+ xim_style |= XIMPreeditCallbacks;
+ }
+ if ((xim_style & XIMPreeditCallbacks) != 0) {
+ ::XIMCallback preedit_start_callback;
+ preedit_start_callback.client_data = (::XPointer)(this);
+ preedit_start_callback.callback = (::XIMProc)(void *)(_xim_preedit_start_callback);
+
+ ::XIMCallback preedit_done_callback;
+ preedit_done_callback.client_data = (::XPointer)(this);
+ preedit_done_callback.callback = (::XIMProc)(_xim_preedit_done_callback);
+
+ ::XIMCallback preedit_draw_callback;
+ preedit_draw_callback.client_data = (::XPointer)(this);
+ preedit_draw_callback.callback = (::XIMProc)(_xim_preedit_draw_callback);
+
+ ::XIMCallback preedit_caret_callback;
+ preedit_caret_callback.client_data = (::XPointer)(this);
+ preedit_caret_callback.callback = (::XIMProc)(_xim_preedit_caret_callback);
+
+ ::XVaNestedList preedit_attributes = XVaCreateNestedList(0,
+ XNPreeditStartCallback, &preedit_start_callback,
+ XNPreeditDoneCallback, &preedit_done_callback,
+ XNPreeditDrawCallback, &preedit_draw_callback,
+ XNPreeditCaretCallback, &preedit_caret_callback,
+ (char *)nullptr);
+
+ wd.xic = XCreateIC(xim,
+ XNInputStyle, xim_style,
+ XNClientWindow, wd.x11_xim_window,
+ XNFocusWindow, wd.x11_xim_window,
+ XNPreeditAttributes, preedit_attributes,
+ (char *)nullptr);
+ XFree(preedit_attributes);
+ } else {
+ wd.xic = XCreateIC(xim,
+ XNInputStyle, xim_style,
+ XNClientWindow, wd.x11_xim_window,
+ XNFocusWindow, wd.x11_xim_window,
+ (char *)nullptr);
+ }
+
if (XGetICValues(wd.xic, XNFilterEvents, &im_event_mask, nullptr) != nullptr) {
WARN_PRINT("XGetICValues couldn't obtain XNFilterEvents value");
XDestroyIC(wd.xic);
@@ -4621,14 +5020,15 @@ DisplayServerX11::WindowID DisplayServerX11::_create_window(WindowMode p_mode, V
#if defined(VULKAN_ENABLED)
if (context_vulkan) {
- Error err = context_vulkan->window_create(id, p_vsync_mode, wd.x11_window, x11_display, p_rect.size.width, p_rect.size.height);
+ Error err = context_vulkan->window_create(id, p_vsync_mode, wd.x11_window, x11_display, win_rect.size.width, win_rect.size.height);
ERR_FAIL_COND_V_MSG(err != OK, INVALID_WINDOW_ID, "Can't create a Vulkan window");
}
#endif
#ifdef GLES3_ENABLED
if (gl_manager) {
- Error err = gl_manager->window_create(id, wd.x11_window, x11_display, p_rect.size.width, p_rect.size.height);
+ Error err = gl_manager->window_create(id, wd.x11_window, x11_display, win_rect.size.width, win_rect.size.height);
ERR_FAIL_COND_V_MSG(err != OK, INVALID_WINDOW_ID, "Can't create an OpenGL window");
+ window_set_vsync_mode(p_vsync_mode, id);
}
#endif
@@ -4662,7 +5062,108 @@ DisplayServerX11::WindowID DisplayServerX11::_create_window(WindowMode p_mode, V
return id;
}
-DisplayServerX11::DisplayServerX11(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i &p_resolution, Error &r_error) {
+static bool _is_xim_style_supported(const ::XIMStyle &p_style) {
+ const ::XIMStyle supported_preedit = XIMPreeditCallbacks | XIMPreeditPosition | XIMPreeditNothing | XIMPreeditNone;
+ const ::XIMStyle supported_status = XIMStatusNothing | XIMStatusNone;
+
+ // Check preedit style is supported
+ if ((p_style & supported_preedit) == 0) {
+ return false;
+ }
+
+ // Check status style is supported
+ if ((p_style & supported_status) == 0) {
+ return false;
+ }
+
+ return true;
+}
+
+static ::XIMStyle _get_best_xim_style(const ::XIMStyle &p_style_a, const ::XIMStyle &p_style_b) {
+ if (p_style_a == 0) {
+ return p_style_b;
+ }
+ if (p_style_b == 0) {
+ return p_style_a;
+ }
+
+ const ::XIMStyle preedit = XIMPreeditArea | XIMPreeditCallbacks | XIMPreeditPosition | XIMPreeditNothing | XIMPreeditNone;
+ const ::XIMStyle status = XIMStatusArea | XIMStatusCallbacks | XIMStatusNothing | XIMStatusNone;
+
+ ::XIMStyle a = p_style_a & preedit;
+ ::XIMStyle b = p_style_b & preedit;
+ if (a != b) {
+ // Compare preedit styles.
+ if ((a | b) & XIMPreeditCallbacks) {
+ return a == XIMPreeditCallbacks ? p_style_a : p_style_b;
+ } else if ((a | b) & XIMPreeditPosition) {
+ return a == XIMPreeditPosition ? p_style_a : p_style_b;
+ } else if ((a | b) & XIMPreeditArea) {
+ return a == XIMPreeditArea ? p_style_a : p_style_b;
+ } else if ((a | b) & XIMPreeditNothing) {
+ return a == XIMPreeditNothing ? p_style_a : p_style_b;
+ }
+ } else {
+ // Preedit styles are the same, compare status styles.
+ a = p_style_a & status;
+ b = p_style_b & status;
+
+ if ((a | b) & XIMStatusCallbacks) {
+ return a == XIMStatusCallbacks ? p_style_a : p_style_b;
+ } else if ((a | b) & XIMStatusArea) {
+ return a == XIMStatusArea ? p_style_a : p_style_b;
+ } else if ((a | b) & XIMStatusNothing) {
+ return a == XIMStatusNothing ? p_style_a : p_style_b;
+ }
+ }
+ return p_style_a;
+}
+
+DisplayServerX11::DisplayServerX11(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Error &r_error) {
+ KeyMappingX11::initialize();
+
+#ifdef DEBUG_ENABLED
+ int dylibloader_verbose = 1;
+#else
+ int dylibloader_verbose = 0;
+#endif
+ if (initialize_xlib(dylibloader_verbose) != 0) {
+ r_error = ERR_UNAVAILABLE;
+ ERR_FAIL_MSG("Can't load Xlib dynamically.");
+ }
+
+ if (initialize_xcursor(dylibloader_verbose) != 0) {
+ r_error = ERR_UNAVAILABLE;
+ ERR_FAIL_MSG("Can't load XCursor dynamically.");
+ }
+
+ initialize_xkbcommon(dylibloader_verbose); // Optional, used for key_label.
+
+ if (initialize_xext(dylibloader_verbose) != 0) {
+ r_error = ERR_UNAVAILABLE;
+ ERR_FAIL_MSG("Can't load Xext dynamically.");
+ }
+
+ if (initialize_xinerama(dylibloader_verbose) != 0) {
+ r_error = ERR_UNAVAILABLE;
+ ERR_FAIL_MSG("Can't load Xinerama dynamically.");
+ }
+
+ if (initialize_xrandr(dylibloader_verbose) != 0) {
+ r_error = ERR_UNAVAILABLE;
+ ERR_FAIL_MSG("Can't load Xrandr dynamically.");
+ }
+
+ if (initialize_xrender(dylibloader_verbose) != 0) {
+ r_error = ERR_UNAVAILABLE;
+ ERR_FAIL_MSG("Can't load Xrender dynamically.");
+ }
+
+ if (initialize_xinput2(dylibloader_verbose) != 0) {
+ r_error = ERR_UNAVAILABLE;
+ ERR_FAIL_MSG("Can't load Xinput2 dynamically.");
+ }
+
Input::get_singleton()->set_event_dispatch_function(_dispatch_input_events);
r_error = OK;
@@ -4769,11 +5270,13 @@ DisplayServerX11::DisplayServerX11(const String &p_rendering_driver, WindowMode
if (xim_styles) {
xim_style = 0L;
for (int i = 0; i < xim_styles->count_styles; i++) {
- if (xim_styles->supported_styles[i] ==
- (XIMPreeditNothing | XIMStatusNothing)) {
- xim_style = xim_styles->supported_styles[i];
- break;
+ const ::XIMStyle &style = xim_styles->supported_styles[i];
+
+ if (!_is_xim_style_supported(style)) {
+ continue;
}
+
+ xim_style = _get_best_xim_style(xim_style, style);
}
XFree(xim_styles);
@@ -4863,7 +5366,7 @@ DisplayServerX11::DisplayServerX11(const String &p_rendering_driver, WindowMode
gl_manager = memnew(GLManager_X11(p_resolution, opengl_api_type));
- if (gl_manager->initialize() != OK) {
+ if (gl_manager->initialize(x11_display) != OK) {
memdelete(gl_manager);
gl_manager = nullptr;
r_error = ERR_UNAVAILABLE;
@@ -4886,9 +5389,16 @@ DisplayServerX11::DisplayServerX11(const String &p_rendering_driver, WindowMode
ERR_FAIL_MSG("Video driver not found");
}
- Point2i window_position(
- (screen_get_size(0).width - p_resolution.width) / 2,
- (screen_get_size(0).height - p_resolution.height) / 2);
+ Point2i window_position;
+ if (p_position != nullptr) {
+ window_position = *p_position;
+ } else {
+ if (p_screen == SCREEN_OF_MAIN_WINDOW) {
+ p_screen = SCREEN_PRIMARY;
+ }
+ window_position = screen_get_position(p_screen) + (screen_get_size(p_screen) - p_resolution) / 2;
+ }
+
WindowID main_window = _create_window(p_mode, p_vsync_mode, p_flags, Rect2i(window_position, p_resolution));
if (main_window == INVALID_WINDOW_ID) {
r_error = ERR_CANT_CREATE;
@@ -5046,24 +5556,13 @@ DisplayServerX11::DisplayServerX11(const String &p_rendering_driver, WindowMode
}
cursor_set_shape(CURSOR_BUSY);
- Vector<XEvent> save_events;
- while (XPending(x11_display) > 0) {
- XEvent xevent{ 0 };
- XNextEvent(x11_display, &xevent);
- if (xevent.type == ConfigureNotify) {
- _window_changed(&xevent);
- } else {
- // Don't discard this event, we must resend it...
- save_events.push_back(xevent);
- }
- }
-
- // Resend events that would have been dropped by the early event queue
- // processing we just performed.
- for (XEvent &ev : save_events) {
- XSendEvent(x11_display, ev.xany.window, False, 0, &ev);
+ // Search the X11 event queue for ConfigureNotify events and process all
+ // that are currently queued early, so we can get the final window size
+ // for correctly drawing of the bootsplash.
+ XEvent config_event;
+ while (XCheckTypedEvent(x11_display, ConfigureNotify, &config_event)) {
+ _window_changed(&config_event);
}
-
events_thread.start(_poll_events_thread, this);
_update_real_mouse_position(windows[MAIN_WINDOW_ID]);
diff --git a/platform/linuxbsd/display_server_x11.h b/platform/linuxbsd/x11/display_server_x11.h
index ea03b2328c..290e3d6a5e 100644
--- a/platform/linuxbsd/display_server_x11.h
+++ b/platform/linuxbsd/x11/display_server_x11.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* display_server_x11.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* display_server_x11.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef DISPLAY_SERVER_X11_H
#define DISPLAY_SERVER_X11_H
@@ -47,7 +47,7 @@
#include "servers/rendering_server.h"
#if defined(SPEECHD_ENABLED)
-#include "tts_linux.h"
+#include "../tts_linux.h"
#endif
#if defined(GLES3_ENABLED)
@@ -56,20 +56,29 @@
#if defined(VULKAN_ENABLED)
#include "drivers/vulkan/rendering_device_vulkan.h"
-#include "platform/linuxbsd/vulkan_context_x11.h"
+#include "vulkan_context_x11.h"
#endif
#if defined(DBUS_ENABLED)
-#include "freedesktop_portal_desktop.h"
-#include "freedesktop_screensaver.h"
+#include "../freedesktop_portal_desktop.h"
+#include "../freedesktop_screensaver.h"
#endif
-#include <X11/Xcursor/Xcursor.h>
+#include <X11/Xatom.h>
#include <X11/Xlib.h>
-#include <X11/extensions/XInput2.h>
-#include <X11/extensions/Xrandr.h>
+#include <X11/Xutil.h>
#include <X11/keysym.h>
+#include "dynwrappers/xlib-so_wrap.h"
+
+#include "dynwrappers/xcursor-so_wrap.h"
+#include "dynwrappers/xext-so_wrap.h"
+#include "dynwrappers/xinerama-so_wrap.h"
+#include "dynwrappers/xinput2-so_wrap.h"
+#include "dynwrappers/xkbcommon-so_wrap.h"
+#include "dynwrappers/xrandr-so_wrap.h"
+#include "dynwrappers/xrender-so_wrap.h"
+
typedef struct _xrr_monitor_info {
Atom name;
Bool primary = false;
@@ -127,20 +136,24 @@ class DisplayServerX11 : public DisplayServer {
struct WindowData {
Window x11_window;
+ Window x11_xim_window;
::XIC xic;
+ bool ime_active = false;
+ bool ime_in_progress = false;
+ bool ime_suppress_next_keyup = false;
Size2i min_size;
Size2i max_size;
Point2i position;
Size2i size;
- Point2i im_position;
- bool im_active = false;
Callable rect_changed_callback;
Callable event_callback;
Callable input_event_callback;
Callable input_text_callback;
Callable drop_files_callback;
+ Vector<Vector2> mpath;
+
WindowID transient_parent = INVALID_WINDOW_ID;
HashSet<WindowID> transient_children;
@@ -151,6 +164,7 @@ class DisplayServerX11 : public DisplayServer {
//better to guess on the fly, given WM can change it
//WindowMode mode;
bool fullscreen = false; //OS can't exit from this mode
+ bool exclusive_fullscreen = false;
bool on_top = false;
bool borderless = false;
bool resize_disabled = false;
@@ -160,16 +174,19 @@ class DisplayServerX11 : public DisplayServer {
bool maximized = false;
bool is_popup = false;
bool layered_window = false;
+ bool mpass = false;
Rect2i parent_safe_rect;
unsigned int focus_order = 0;
};
+ Point2i im_selection;
+ String im_text;
+
HashMap<WindowID, WindowData> windows;
unsigned int last_mouse_monitor_mask = 0;
- Vector2i last_mouse_monitor_pos;
uint64_t time_since_popup = 0;
List<WindowID> popup_list;
@@ -189,6 +206,15 @@ class DisplayServerX11 : public DisplayServer {
::Time last_keyrelease_time = 0;
::XIM xim;
::XIMStyle xim_style;
+
+ static int _xim_preedit_start_callback(::XIM xim, ::XPointer client_data,
+ ::XPointer call_data);
+ static void _xim_preedit_done_callback(::XIM xim, ::XPointer client_data,
+ ::XPointer call_data);
+ static void _xim_preedit_draw_callback(::XIM xim, ::XPointer client_data,
+ ::XIMPreeditDrawCallbackStruct *call_data);
+ static void _xim_preedit_caret_callback(::XIM xim, ::XPointer client_data,
+ ::XIMPreeditCaretCallbackStruct *call_data);
static void _xim_destroy_callback(::XIM im, ::XPointer client_data,
::XPointer call_data);
@@ -197,7 +223,7 @@ class DisplayServerX11 : public DisplayServer {
Point2i last_click_pos = Point2i(-100, -100);
uint64_t last_click_ms = 0;
MouseButton last_click_button_index = MouseButton::NONE;
- MouseButton last_button_state = MouseButton::NONE;
+ BitField<MouseButtonMask> last_button_state;
bool app_focused = false;
uint64_t time_since_no_focus = 0;
@@ -226,7 +252,7 @@ class DisplayServerX11 : public DisplayServer {
Rect2i _screen_get_rect(int p_screen) const;
- MouseButton _get_mouse_button_state(MouseButton p_x11_button, int p_x11_type);
+ BitField<MouseButtonMask> _get_mouse_button_state(MouseButton p_x11_button, int p_x11_type);
void _get_key_modifier_state(unsigned int p_x11_state, Ref<InputEventWithModifiers> state);
void _flush_mouse_motion();
@@ -237,6 +263,7 @@ class DisplayServerX11 : public DisplayServer {
Atom _process_selection_request_target(Atom p_target, Window p_requestor, Atom p_property, Atom p_selection) const;
void _handle_selection_request_event(XSelectionRequestEvent *p_event) const;
+ void _update_window_mouse_passthrough(WindowID p_window);
String _clipboard_get_impl(Atom p_source, Window x11_window, Atom target) const;
String _clipboard_get(Atom p_source, Window x11_window) const;
@@ -276,7 +303,7 @@ class DisplayServerX11 : public DisplayServer {
bool _window_minimize_check(WindowID p_window) const;
void _validate_mode_on_map(WindowID p_window);
void _update_size_hints(WindowID p_window);
- void _set_wm_fullscreen(WindowID p_window, bool p_enabled);
+ void _set_wm_fullscreen(WindowID p_window, bool p_enabled, bool p_exclusive);
void _set_wm_maximized(WindowID p_window, bool p_enabled);
void _set_wm_minimized(WindowID p_window, bool p_enabled);
@@ -284,6 +311,8 @@ class DisplayServerX11 : public DisplayServer {
Context context = CONTEXT_ENGINE;
+ WindowID _get_focused_window_or_popup() const;
+
void _send_window_event(const WindowData &wd, WindowEvent p_event);
static void _dispatch_input_events(const Ref<InputEvent> &p_event);
void _dispatch_input_event(const Ref<InputEvent> &p_event);
@@ -334,7 +363,7 @@ public:
virtual void warp_mouse(const Point2i &p_position) override;
virtual Point2i mouse_get_position() const override;
- virtual MouseButton mouse_get_button_state() const override;
+ virtual BitField<MouseButtonMask> mouse_get_button_state() const override;
virtual void clipboard_set(const String &p_text) override;
virtual String clipboard_get() const override;
@@ -342,12 +371,12 @@ public:
virtual String clipboard_get_primary() const override;
virtual int get_screen_count() const override;
+ virtual int get_primary_screen() const override;
virtual Point2i screen_get_position(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
virtual Size2i screen_get_size(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
virtual Rect2i screen_get_usable_rect(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
virtual int screen_get_dpi(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
virtual float screen_get_refresh_rate(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
- virtual bool screen_is_touchscreen(int p_screen = SCREEN_OF_MAIN_WINDOW) const override;
#if defined(DBUS_ENABLED)
virtual void screen_set_keep_on(bool p_enable) override;
@@ -384,6 +413,7 @@ public:
virtual void window_set_current_screen(int p_screen, WindowID p_window = MAIN_WINDOW_ID) override;
virtual Point2i window_get_position(WindowID p_window = MAIN_WINDOW_ID) const override;
+ virtual Point2i window_get_position_with_decorations(WindowID p_window = MAIN_WINDOW_ID) const override;
virtual void window_set_position(const Point2i &p_position, WindowID p_window = MAIN_WINDOW_ID) override;
virtual void window_set_max_size(const Size2i p_size, WindowID p_window = MAIN_WINDOW_ID) override;
@@ -397,7 +427,7 @@ public:
virtual void window_set_size(const Size2i p_size, WindowID p_window = MAIN_WINDOW_ID) override;
virtual Size2i window_get_size(WindowID p_window = MAIN_WINDOW_ID) const override;
- virtual Size2i window_get_real_size(WindowID p_window = MAIN_WINDOW_ID) const override;
+ virtual Size2i window_get_size_with_decorations(WindowID p_window = MAIN_WINDOW_ID) const override;
virtual void window_set_mode(WindowMode p_mode, WindowID p_window = MAIN_WINDOW_ID) override;
virtual WindowMode window_get_mode(WindowID p_window = MAIN_WINDOW_ID) const override;
@@ -418,6 +448,9 @@ public:
virtual void window_set_ime_active(const bool p_active, WindowID p_window = MAIN_WINDOW_ID) override;
virtual void window_set_ime_position(const Point2i &p_pos, WindowID p_window = MAIN_WINDOW_ID) override;
+ virtual Point2i ime_get_selection() const override;
+ virtual String ime_get_text() const override;
+
virtual void window_set_vsync_mode(DisplayServer::VSyncMode p_vsync_mode, WindowID p_window = MAIN_WINDOW_ID) override;
virtual DisplayServer::VSyncMode window_get_vsync_mode(WindowID p_vsync_mode) const override;
@@ -443,12 +476,12 @@ public:
virtual void set_native_icon(const String &p_filename) override;
virtual void set_icon(const Ref<Image> &p_icon) override;
- static DisplayServer *create_func(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i &p_resolution, Error &r_error);
+ static DisplayServer *create_func(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Error &r_error);
static Vector<String> get_rendering_drivers_func();
static void register_x11_driver();
- DisplayServerX11(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i &p_resolution, Error &r_error);
+ DisplayServerX11(const String &p_rendering_driver, WindowMode p_mode, VSyncMode p_vsync_mode, uint32_t p_flags, const Vector2i *p_position, const Vector2i &p_resolution, int p_screen, Error &r_error);
~DisplayServerX11();
};
diff --git a/platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.c
new file mode 100644
index 0000000000..ecd2c25662
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.c
@@ -0,0 +1,676 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:09:53
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/Xcursor/Xcursor.h --sys-include "thirdparty/linuxbsd_headers/X11/Xcursor/Xcursor.h" --soname libXcursor.so.1 --init-name xcursor --output-header ./platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.c
+//
+// NOTE: Generated from Xcursor 1.2.0.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXcursor.so.1, were removed.
+#include <stdint.h>
+
+#define XcursorImageCreate XcursorImageCreate_dylibloader_orig_xcursor
+#define XcursorImageDestroy XcursorImageDestroy_dylibloader_orig_xcursor
+#define XcursorImagesCreate XcursorImagesCreate_dylibloader_orig_xcursor
+#define XcursorImagesDestroy XcursorImagesDestroy_dylibloader_orig_xcursor
+#define XcursorImagesSetName XcursorImagesSetName_dylibloader_orig_xcursor
+#define XcursorCursorsCreate XcursorCursorsCreate_dylibloader_orig_xcursor
+#define XcursorCursorsDestroy XcursorCursorsDestroy_dylibloader_orig_xcursor
+#define XcursorAnimateCreate XcursorAnimateCreate_dylibloader_orig_xcursor
+#define XcursorAnimateDestroy XcursorAnimateDestroy_dylibloader_orig_xcursor
+#define XcursorAnimateNext XcursorAnimateNext_dylibloader_orig_xcursor
+#define XcursorCommentCreate XcursorCommentCreate_dylibloader_orig_xcursor
+#define XcursorCommentDestroy XcursorCommentDestroy_dylibloader_orig_xcursor
+#define XcursorCommentsCreate XcursorCommentsCreate_dylibloader_orig_xcursor
+#define XcursorCommentsDestroy XcursorCommentsDestroy_dylibloader_orig_xcursor
+#define XcursorXcFileLoadImage XcursorXcFileLoadImage_dylibloader_orig_xcursor
+#define XcursorXcFileLoadImages XcursorXcFileLoadImages_dylibloader_orig_xcursor
+#define XcursorXcFileLoadAllImages XcursorXcFileLoadAllImages_dylibloader_orig_xcursor
+#define XcursorXcFileLoad XcursorXcFileLoad_dylibloader_orig_xcursor
+#define XcursorXcFileSave XcursorXcFileSave_dylibloader_orig_xcursor
+#define XcursorFileLoadImage XcursorFileLoadImage_dylibloader_orig_xcursor
+#define XcursorFileLoadImages XcursorFileLoadImages_dylibloader_orig_xcursor
+#define XcursorFileLoadAllImages XcursorFileLoadAllImages_dylibloader_orig_xcursor
+#define XcursorFileLoad XcursorFileLoad_dylibloader_orig_xcursor
+#define XcursorFileSaveImages XcursorFileSaveImages_dylibloader_orig_xcursor
+#define XcursorFileSave XcursorFileSave_dylibloader_orig_xcursor
+#define XcursorFilenameLoadImage XcursorFilenameLoadImage_dylibloader_orig_xcursor
+#define XcursorFilenameLoadImages XcursorFilenameLoadImages_dylibloader_orig_xcursor
+#define XcursorFilenameLoadAllImages XcursorFilenameLoadAllImages_dylibloader_orig_xcursor
+#define XcursorFilenameLoad XcursorFilenameLoad_dylibloader_orig_xcursor
+#define XcursorFilenameSaveImages XcursorFilenameSaveImages_dylibloader_orig_xcursor
+#define XcursorFilenameSave XcursorFilenameSave_dylibloader_orig_xcursor
+#define XcursorLibraryLoadImage XcursorLibraryLoadImage_dylibloader_orig_xcursor
+#define XcursorLibraryLoadImages XcursorLibraryLoadImages_dylibloader_orig_xcursor
+#define XcursorLibraryPath XcursorLibraryPath_dylibloader_orig_xcursor
+#define XcursorLibraryShape XcursorLibraryShape_dylibloader_orig_xcursor
+#define XcursorImageLoadCursor XcursorImageLoadCursor_dylibloader_orig_xcursor
+#define XcursorImagesLoadCursors XcursorImagesLoadCursors_dylibloader_orig_xcursor
+#define XcursorImagesLoadCursor XcursorImagesLoadCursor_dylibloader_orig_xcursor
+#define XcursorFilenameLoadCursor XcursorFilenameLoadCursor_dylibloader_orig_xcursor
+#define XcursorFilenameLoadCursors XcursorFilenameLoadCursors_dylibloader_orig_xcursor
+#define XcursorLibraryLoadCursor XcursorLibraryLoadCursor_dylibloader_orig_xcursor
+#define XcursorLibraryLoadCursors XcursorLibraryLoadCursors_dylibloader_orig_xcursor
+#define XcursorShapeLoadImage XcursorShapeLoadImage_dylibloader_orig_xcursor
+#define XcursorShapeLoadImages XcursorShapeLoadImages_dylibloader_orig_xcursor
+#define XcursorShapeLoadCursor XcursorShapeLoadCursor_dylibloader_orig_xcursor
+#define XcursorShapeLoadCursors XcursorShapeLoadCursors_dylibloader_orig_xcursor
+#define XcursorTryShapeCursor XcursorTryShapeCursor_dylibloader_orig_xcursor
+#define XcursorNoticeCreateBitmap XcursorNoticeCreateBitmap_dylibloader_orig_xcursor
+#define XcursorNoticePutBitmap XcursorNoticePutBitmap_dylibloader_orig_xcursor
+#define XcursorTryShapeBitmapCursor XcursorTryShapeBitmapCursor_dylibloader_orig_xcursor
+#define XcursorImageHash XcursorImageHash_dylibloader_orig_xcursor
+#define XcursorSupportsARGB XcursorSupportsARGB_dylibloader_orig_xcursor
+#define XcursorSupportsAnim XcursorSupportsAnim_dylibloader_orig_xcursor
+#define XcursorSetDefaultSize XcursorSetDefaultSize_dylibloader_orig_xcursor
+#define XcursorGetDefaultSize XcursorGetDefaultSize_dylibloader_orig_xcursor
+#define XcursorSetTheme XcursorSetTheme_dylibloader_orig_xcursor
+#define XcursorGetTheme XcursorGetTheme_dylibloader_orig_xcursor
+#define XcursorGetThemeCore XcursorGetThemeCore_dylibloader_orig_xcursor
+#define XcursorSetThemeCore XcursorSetThemeCore_dylibloader_orig_xcursor
+#include "thirdparty/linuxbsd_headers/X11/Xcursor/Xcursor.h"
+#undef XcursorImageCreate
+#undef XcursorImageDestroy
+#undef XcursorImagesCreate
+#undef XcursorImagesDestroy
+#undef XcursorImagesSetName
+#undef XcursorCursorsCreate
+#undef XcursorCursorsDestroy
+#undef XcursorAnimateCreate
+#undef XcursorAnimateDestroy
+#undef XcursorAnimateNext
+#undef XcursorCommentCreate
+#undef XcursorCommentDestroy
+#undef XcursorCommentsCreate
+#undef XcursorCommentsDestroy
+#undef XcursorXcFileLoadImage
+#undef XcursorXcFileLoadImages
+#undef XcursorXcFileLoadAllImages
+#undef XcursorXcFileLoad
+#undef XcursorXcFileSave
+#undef XcursorFileLoadImage
+#undef XcursorFileLoadImages
+#undef XcursorFileLoadAllImages
+#undef XcursorFileLoad
+#undef XcursorFileSaveImages
+#undef XcursorFileSave
+#undef XcursorFilenameLoadImage
+#undef XcursorFilenameLoadImages
+#undef XcursorFilenameLoadAllImages
+#undef XcursorFilenameLoad
+#undef XcursorFilenameSaveImages
+#undef XcursorFilenameSave
+#undef XcursorLibraryLoadImage
+#undef XcursorLibraryLoadImages
+#undef XcursorLibraryPath
+#undef XcursorLibraryShape
+#undef XcursorImageLoadCursor
+#undef XcursorImagesLoadCursors
+#undef XcursorImagesLoadCursor
+#undef XcursorFilenameLoadCursor
+#undef XcursorFilenameLoadCursors
+#undef XcursorLibraryLoadCursor
+#undef XcursorLibraryLoadCursors
+#undef XcursorShapeLoadImage
+#undef XcursorShapeLoadImages
+#undef XcursorShapeLoadCursor
+#undef XcursorShapeLoadCursors
+#undef XcursorTryShapeCursor
+#undef XcursorNoticeCreateBitmap
+#undef XcursorNoticePutBitmap
+#undef XcursorTryShapeBitmapCursor
+#undef XcursorImageHash
+#undef XcursorSupportsARGB
+#undef XcursorSupportsAnim
+#undef XcursorSetDefaultSize
+#undef XcursorGetDefaultSize
+#undef XcursorSetTheme
+#undef XcursorGetTheme
+#undef XcursorGetThemeCore
+#undef XcursorSetThemeCore
+#include <dlfcn.h>
+#include <stdio.h>
+XcursorImage* (*XcursorImageCreate_dylibloader_wrapper_xcursor)( int, int);
+void (*XcursorImageDestroy_dylibloader_wrapper_xcursor)( XcursorImage*);
+XcursorImages* (*XcursorImagesCreate_dylibloader_wrapper_xcursor)( int);
+void (*XcursorImagesDestroy_dylibloader_wrapper_xcursor)( XcursorImages*);
+void (*XcursorImagesSetName_dylibloader_wrapper_xcursor)( XcursorImages*,const char*);
+XcursorCursors* (*XcursorCursorsCreate_dylibloader_wrapper_xcursor)( Display*, int);
+void (*XcursorCursorsDestroy_dylibloader_wrapper_xcursor)( XcursorCursors*);
+XcursorAnimate* (*XcursorAnimateCreate_dylibloader_wrapper_xcursor)( XcursorCursors*);
+void (*XcursorAnimateDestroy_dylibloader_wrapper_xcursor)( XcursorAnimate*);
+Cursor (*XcursorAnimateNext_dylibloader_wrapper_xcursor)( XcursorAnimate*);
+XcursorComment* (*XcursorCommentCreate_dylibloader_wrapper_xcursor)( XcursorUInt, int);
+void (*XcursorCommentDestroy_dylibloader_wrapper_xcursor)( XcursorComment*);
+XcursorComments* (*XcursorCommentsCreate_dylibloader_wrapper_xcursor)( int);
+void (*XcursorCommentsDestroy_dylibloader_wrapper_xcursor)( XcursorComments*);
+XcursorImage* (*XcursorXcFileLoadImage_dylibloader_wrapper_xcursor)( XcursorFile*, int);
+XcursorImages* (*XcursorXcFileLoadImages_dylibloader_wrapper_xcursor)( XcursorFile*, int);
+XcursorImages* (*XcursorXcFileLoadAllImages_dylibloader_wrapper_xcursor)( XcursorFile*);
+XcursorBool (*XcursorXcFileLoad_dylibloader_wrapper_xcursor)( XcursorFile*, XcursorComments**, XcursorImages**);
+XcursorBool (*XcursorXcFileSave_dylibloader_wrapper_xcursor)( XcursorFile*,const XcursorComments*,const XcursorImages*);
+XcursorImage* (*XcursorFileLoadImage_dylibloader_wrapper_xcursor)( FILE*, int);
+XcursorImages* (*XcursorFileLoadImages_dylibloader_wrapper_xcursor)( FILE*, int);
+XcursorImages* (*XcursorFileLoadAllImages_dylibloader_wrapper_xcursor)( FILE*);
+XcursorBool (*XcursorFileLoad_dylibloader_wrapper_xcursor)( FILE*, XcursorComments**, XcursorImages**);
+XcursorBool (*XcursorFileSaveImages_dylibloader_wrapper_xcursor)( FILE*,const XcursorImages*);
+XcursorBool (*XcursorFileSave_dylibloader_wrapper_xcursor)( FILE*,const XcursorComments*,const XcursorImages*);
+XcursorImage* (*XcursorFilenameLoadImage_dylibloader_wrapper_xcursor)(const char*, int);
+XcursorImages* (*XcursorFilenameLoadImages_dylibloader_wrapper_xcursor)(const char*, int);
+XcursorImages* (*XcursorFilenameLoadAllImages_dylibloader_wrapper_xcursor)(const char*);
+XcursorBool (*XcursorFilenameLoad_dylibloader_wrapper_xcursor)(const char*, XcursorComments**, XcursorImages**);
+XcursorBool (*XcursorFilenameSaveImages_dylibloader_wrapper_xcursor)(const char*,const XcursorImages*);
+XcursorBool (*XcursorFilenameSave_dylibloader_wrapper_xcursor)(const char*,const XcursorComments*,const XcursorImages*);
+XcursorImage* (*XcursorLibraryLoadImage_dylibloader_wrapper_xcursor)(const char*,const char*, int);
+XcursorImages* (*XcursorLibraryLoadImages_dylibloader_wrapper_xcursor)(const char*,const char*, int);
+const char* (*XcursorLibraryPath_dylibloader_wrapper_xcursor)( void);
+int (*XcursorLibraryShape_dylibloader_wrapper_xcursor)(const char*);
+Cursor (*XcursorImageLoadCursor_dylibloader_wrapper_xcursor)( Display*,const XcursorImage*);
+XcursorCursors* (*XcursorImagesLoadCursors_dylibloader_wrapper_xcursor)( Display*,const XcursorImages*);
+Cursor (*XcursorImagesLoadCursor_dylibloader_wrapper_xcursor)( Display*,const XcursorImages*);
+Cursor (*XcursorFilenameLoadCursor_dylibloader_wrapper_xcursor)( Display*,const char*);
+XcursorCursors* (*XcursorFilenameLoadCursors_dylibloader_wrapper_xcursor)( Display*,const char*);
+Cursor (*XcursorLibraryLoadCursor_dylibloader_wrapper_xcursor)( Display*,const char*);
+XcursorCursors* (*XcursorLibraryLoadCursors_dylibloader_wrapper_xcursor)( Display*,const char*);
+XcursorImage* (*XcursorShapeLoadImage_dylibloader_wrapper_xcursor)( unsigned int,const char*, int);
+XcursorImages* (*XcursorShapeLoadImages_dylibloader_wrapper_xcursor)( unsigned int,const char*, int);
+Cursor (*XcursorShapeLoadCursor_dylibloader_wrapper_xcursor)( Display*, unsigned int);
+XcursorCursors* (*XcursorShapeLoadCursors_dylibloader_wrapper_xcursor)( Display*, unsigned int);
+Cursor (*XcursorTryShapeCursor_dylibloader_wrapper_xcursor)( Display*, Font, Font, unsigned int, unsigned int,const XColor*,const XColor*);
+void (*XcursorNoticeCreateBitmap_dylibloader_wrapper_xcursor)( Display*, Pixmap, unsigned int, unsigned int);
+void (*XcursorNoticePutBitmap_dylibloader_wrapper_xcursor)( Display*, Drawable, XImage*);
+Cursor (*XcursorTryShapeBitmapCursor_dylibloader_wrapper_xcursor)( Display*, Pixmap, Pixmap, XColor*, XColor*, unsigned int, unsigned int);
+void (*XcursorImageHash_dylibloader_wrapper_xcursor)( XImage*, unsigned char [16]);
+XcursorBool (*XcursorSupportsARGB_dylibloader_wrapper_xcursor)( Display*);
+XcursorBool (*XcursorSupportsAnim_dylibloader_wrapper_xcursor)( Display*);
+XcursorBool (*XcursorSetDefaultSize_dylibloader_wrapper_xcursor)( Display*, int);
+int (*XcursorGetDefaultSize_dylibloader_wrapper_xcursor)( Display*);
+XcursorBool (*XcursorSetTheme_dylibloader_wrapper_xcursor)( Display*,const char*);
+char* (*XcursorGetTheme_dylibloader_wrapper_xcursor)( Display*);
+XcursorBool (*XcursorGetThemeCore_dylibloader_wrapper_xcursor)( Display*);
+XcursorBool (*XcursorSetThemeCore_dylibloader_wrapper_xcursor)( Display*, XcursorBool);
+int initialize_xcursor(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libXcursor.so.1", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// XcursorImageCreate
+ *(void **) (&XcursorImageCreate_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImageCreate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImageDestroy
+ *(void **) (&XcursorImageDestroy_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImageDestroy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImagesCreate
+ *(void **) (&XcursorImagesCreate_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImagesCreate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImagesDestroy
+ *(void **) (&XcursorImagesDestroy_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImagesDestroy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImagesSetName
+ *(void **) (&XcursorImagesSetName_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImagesSetName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorCursorsCreate
+ *(void **) (&XcursorCursorsCreate_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorCursorsCreate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorCursorsDestroy
+ *(void **) (&XcursorCursorsDestroy_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorCursorsDestroy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorAnimateCreate
+ *(void **) (&XcursorAnimateCreate_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorAnimateCreate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorAnimateDestroy
+ *(void **) (&XcursorAnimateDestroy_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorAnimateDestroy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorAnimateNext
+ *(void **) (&XcursorAnimateNext_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorAnimateNext");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorCommentCreate
+ *(void **) (&XcursorCommentCreate_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorCommentCreate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorCommentDestroy
+ *(void **) (&XcursorCommentDestroy_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorCommentDestroy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorCommentsCreate
+ *(void **) (&XcursorCommentsCreate_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorCommentsCreate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorCommentsDestroy
+ *(void **) (&XcursorCommentsDestroy_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorCommentsDestroy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorXcFileLoadImage
+ *(void **) (&XcursorXcFileLoadImage_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorXcFileLoadImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorXcFileLoadImages
+ *(void **) (&XcursorXcFileLoadImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorXcFileLoadImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorXcFileLoadAllImages
+ *(void **) (&XcursorXcFileLoadAllImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorXcFileLoadAllImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorXcFileLoad
+ *(void **) (&XcursorXcFileLoad_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorXcFileLoad");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorXcFileSave
+ *(void **) (&XcursorXcFileSave_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorXcFileSave");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFileLoadImage
+ *(void **) (&XcursorFileLoadImage_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFileLoadImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFileLoadImages
+ *(void **) (&XcursorFileLoadImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFileLoadImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFileLoadAllImages
+ *(void **) (&XcursorFileLoadAllImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFileLoadAllImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFileLoad
+ *(void **) (&XcursorFileLoad_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFileLoad");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFileSaveImages
+ *(void **) (&XcursorFileSaveImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFileSaveImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFileSave
+ *(void **) (&XcursorFileSave_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFileSave");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameLoadImage
+ *(void **) (&XcursorFilenameLoadImage_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameLoadImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameLoadImages
+ *(void **) (&XcursorFilenameLoadImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameLoadImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameLoadAllImages
+ *(void **) (&XcursorFilenameLoadAllImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameLoadAllImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameLoad
+ *(void **) (&XcursorFilenameLoad_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameLoad");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameSaveImages
+ *(void **) (&XcursorFilenameSaveImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameSaveImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameSave
+ *(void **) (&XcursorFilenameSave_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameSave");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorLibraryLoadImage
+ *(void **) (&XcursorLibraryLoadImage_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorLibraryLoadImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorLibraryLoadImages
+ *(void **) (&XcursorLibraryLoadImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorLibraryLoadImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorLibraryPath
+ *(void **) (&XcursorLibraryPath_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorLibraryPath");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorLibraryShape
+ *(void **) (&XcursorLibraryShape_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorLibraryShape");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImageLoadCursor
+ *(void **) (&XcursorImageLoadCursor_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImageLoadCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImagesLoadCursors
+ *(void **) (&XcursorImagesLoadCursors_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImagesLoadCursors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImagesLoadCursor
+ *(void **) (&XcursorImagesLoadCursor_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImagesLoadCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameLoadCursor
+ *(void **) (&XcursorFilenameLoadCursor_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameLoadCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorFilenameLoadCursors
+ *(void **) (&XcursorFilenameLoadCursors_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorFilenameLoadCursors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorLibraryLoadCursor
+ *(void **) (&XcursorLibraryLoadCursor_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorLibraryLoadCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorLibraryLoadCursors
+ *(void **) (&XcursorLibraryLoadCursors_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorLibraryLoadCursors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorShapeLoadImage
+ *(void **) (&XcursorShapeLoadImage_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorShapeLoadImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorShapeLoadImages
+ *(void **) (&XcursorShapeLoadImages_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorShapeLoadImages");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorShapeLoadCursor
+ *(void **) (&XcursorShapeLoadCursor_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorShapeLoadCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorShapeLoadCursors
+ *(void **) (&XcursorShapeLoadCursors_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorShapeLoadCursors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorTryShapeCursor
+ *(void **) (&XcursorTryShapeCursor_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorTryShapeCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorNoticeCreateBitmap
+ *(void **) (&XcursorNoticeCreateBitmap_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorNoticeCreateBitmap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorNoticePutBitmap
+ *(void **) (&XcursorNoticePutBitmap_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorNoticePutBitmap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorTryShapeBitmapCursor
+ *(void **) (&XcursorTryShapeBitmapCursor_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorTryShapeBitmapCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorImageHash
+ *(void **) (&XcursorImageHash_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorImageHash");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorSupportsARGB
+ *(void **) (&XcursorSupportsARGB_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorSupportsARGB");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorSupportsAnim
+ *(void **) (&XcursorSupportsAnim_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorSupportsAnim");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorSetDefaultSize
+ *(void **) (&XcursorSetDefaultSize_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorSetDefaultSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorGetDefaultSize
+ *(void **) (&XcursorGetDefaultSize_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorGetDefaultSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorSetTheme
+ *(void **) (&XcursorSetTheme_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorSetTheme");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorGetTheme
+ *(void **) (&XcursorGetTheme_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorGetTheme");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorGetThemeCore
+ *(void **) (&XcursorGetThemeCore_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorGetThemeCore");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XcursorSetThemeCore
+ *(void **) (&XcursorSetThemeCore_dylibloader_wrapper_xcursor) = dlsym(handle, "XcursorSetThemeCore");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.h
new file mode 100644
index 0000000000..dc3684ff09
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.h
@@ -0,0 +1,258 @@
+#ifndef DYLIBLOAD_WRAPPER_XCURSOR
+#define DYLIBLOAD_WRAPPER_XCURSOR
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:09:53
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/Xcursor/Xcursor.h --sys-include "thirdparty/linuxbsd_headers/X11/Xcursor/Xcursor.h" --soname libXcursor.so.1 --init-name xcursor --output-header ./platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xcursor-so_wrap.c
+//
+// NOTE: Generated from Xcursor 1.2.0.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXcursor.so.1, were removed.
+#include <stdint.h>
+
+#define XcursorImageCreate XcursorImageCreate_dylibloader_orig_xcursor
+#define XcursorImageDestroy XcursorImageDestroy_dylibloader_orig_xcursor
+#define XcursorImagesCreate XcursorImagesCreate_dylibloader_orig_xcursor
+#define XcursorImagesDestroy XcursorImagesDestroy_dylibloader_orig_xcursor
+#define XcursorImagesSetName XcursorImagesSetName_dylibloader_orig_xcursor
+#define XcursorCursorsCreate XcursorCursorsCreate_dylibloader_orig_xcursor
+#define XcursorCursorsDestroy XcursorCursorsDestroy_dylibloader_orig_xcursor
+#define XcursorAnimateCreate XcursorAnimateCreate_dylibloader_orig_xcursor
+#define XcursorAnimateDestroy XcursorAnimateDestroy_dylibloader_orig_xcursor
+#define XcursorAnimateNext XcursorAnimateNext_dylibloader_orig_xcursor
+#define XcursorCommentCreate XcursorCommentCreate_dylibloader_orig_xcursor
+#define XcursorCommentDestroy XcursorCommentDestroy_dylibloader_orig_xcursor
+#define XcursorCommentsCreate XcursorCommentsCreate_dylibloader_orig_xcursor
+#define XcursorCommentsDestroy XcursorCommentsDestroy_dylibloader_orig_xcursor
+#define XcursorXcFileLoadImage XcursorXcFileLoadImage_dylibloader_orig_xcursor
+#define XcursorXcFileLoadImages XcursorXcFileLoadImages_dylibloader_orig_xcursor
+#define XcursorXcFileLoadAllImages XcursorXcFileLoadAllImages_dylibloader_orig_xcursor
+#define XcursorXcFileLoad XcursorXcFileLoad_dylibloader_orig_xcursor
+#define XcursorXcFileSave XcursorXcFileSave_dylibloader_orig_xcursor
+#define XcursorFileLoadImage XcursorFileLoadImage_dylibloader_orig_xcursor
+#define XcursorFileLoadImages XcursorFileLoadImages_dylibloader_orig_xcursor
+#define XcursorFileLoadAllImages XcursorFileLoadAllImages_dylibloader_orig_xcursor
+#define XcursorFileLoad XcursorFileLoad_dylibloader_orig_xcursor
+#define XcursorFileSaveImages XcursorFileSaveImages_dylibloader_orig_xcursor
+#define XcursorFileSave XcursorFileSave_dylibloader_orig_xcursor
+#define XcursorFilenameLoadImage XcursorFilenameLoadImage_dylibloader_orig_xcursor
+#define XcursorFilenameLoadImages XcursorFilenameLoadImages_dylibloader_orig_xcursor
+#define XcursorFilenameLoadAllImages XcursorFilenameLoadAllImages_dylibloader_orig_xcursor
+#define XcursorFilenameLoad XcursorFilenameLoad_dylibloader_orig_xcursor
+#define XcursorFilenameSaveImages XcursorFilenameSaveImages_dylibloader_orig_xcursor
+#define XcursorFilenameSave XcursorFilenameSave_dylibloader_orig_xcursor
+#define XcursorLibraryLoadImage XcursorLibraryLoadImage_dylibloader_orig_xcursor
+#define XcursorLibraryLoadImages XcursorLibraryLoadImages_dylibloader_orig_xcursor
+#define XcursorLibraryPath XcursorLibraryPath_dylibloader_orig_xcursor
+#define XcursorLibraryShape XcursorLibraryShape_dylibloader_orig_xcursor
+#define XcursorImageLoadCursor XcursorImageLoadCursor_dylibloader_orig_xcursor
+#define XcursorImagesLoadCursors XcursorImagesLoadCursors_dylibloader_orig_xcursor
+#define XcursorImagesLoadCursor XcursorImagesLoadCursor_dylibloader_orig_xcursor
+#define XcursorFilenameLoadCursor XcursorFilenameLoadCursor_dylibloader_orig_xcursor
+#define XcursorFilenameLoadCursors XcursorFilenameLoadCursors_dylibloader_orig_xcursor
+#define XcursorLibraryLoadCursor XcursorLibraryLoadCursor_dylibloader_orig_xcursor
+#define XcursorLibraryLoadCursors XcursorLibraryLoadCursors_dylibloader_orig_xcursor
+#define XcursorShapeLoadImage XcursorShapeLoadImage_dylibloader_orig_xcursor
+#define XcursorShapeLoadImages XcursorShapeLoadImages_dylibloader_orig_xcursor
+#define XcursorShapeLoadCursor XcursorShapeLoadCursor_dylibloader_orig_xcursor
+#define XcursorShapeLoadCursors XcursorShapeLoadCursors_dylibloader_orig_xcursor
+#define XcursorTryShapeCursor XcursorTryShapeCursor_dylibloader_orig_xcursor
+#define XcursorNoticeCreateBitmap XcursorNoticeCreateBitmap_dylibloader_orig_xcursor
+#define XcursorNoticePutBitmap XcursorNoticePutBitmap_dylibloader_orig_xcursor
+#define XcursorTryShapeBitmapCursor XcursorTryShapeBitmapCursor_dylibloader_orig_xcursor
+#define XcursorImageHash XcursorImageHash_dylibloader_orig_xcursor
+#define XcursorSupportsARGB XcursorSupportsARGB_dylibloader_orig_xcursor
+#define XcursorSupportsAnim XcursorSupportsAnim_dylibloader_orig_xcursor
+#define XcursorSetDefaultSize XcursorSetDefaultSize_dylibloader_orig_xcursor
+#define XcursorGetDefaultSize XcursorGetDefaultSize_dylibloader_orig_xcursor
+#define XcursorSetTheme XcursorSetTheme_dylibloader_orig_xcursor
+#define XcursorGetTheme XcursorGetTheme_dylibloader_orig_xcursor
+#define XcursorGetThemeCore XcursorGetThemeCore_dylibloader_orig_xcursor
+#define XcursorSetThemeCore XcursorSetThemeCore_dylibloader_orig_xcursor
+#include "thirdparty/linuxbsd_headers/X11/Xcursor/Xcursor.h"
+#undef XcursorImageCreate
+#undef XcursorImageDestroy
+#undef XcursorImagesCreate
+#undef XcursorImagesDestroy
+#undef XcursorImagesSetName
+#undef XcursorCursorsCreate
+#undef XcursorCursorsDestroy
+#undef XcursorAnimateCreate
+#undef XcursorAnimateDestroy
+#undef XcursorAnimateNext
+#undef XcursorCommentCreate
+#undef XcursorCommentDestroy
+#undef XcursorCommentsCreate
+#undef XcursorCommentsDestroy
+#undef XcursorXcFileLoadImage
+#undef XcursorXcFileLoadImages
+#undef XcursorXcFileLoadAllImages
+#undef XcursorXcFileLoad
+#undef XcursorXcFileSave
+#undef XcursorFileLoadImage
+#undef XcursorFileLoadImages
+#undef XcursorFileLoadAllImages
+#undef XcursorFileLoad
+#undef XcursorFileSaveImages
+#undef XcursorFileSave
+#undef XcursorFilenameLoadImage
+#undef XcursorFilenameLoadImages
+#undef XcursorFilenameLoadAllImages
+#undef XcursorFilenameLoad
+#undef XcursorFilenameSaveImages
+#undef XcursorFilenameSave
+#undef XcursorLibraryLoadImage
+#undef XcursorLibraryLoadImages
+#undef XcursorLibraryPath
+#undef XcursorLibraryShape
+#undef XcursorImageLoadCursor
+#undef XcursorImagesLoadCursors
+#undef XcursorImagesLoadCursor
+#undef XcursorFilenameLoadCursor
+#undef XcursorFilenameLoadCursors
+#undef XcursorLibraryLoadCursor
+#undef XcursorLibraryLoadCursors
+#undef XcursorShapeLoadImage
+#undef XcursorShapeLoadImages
+#undef XcursorShapeLoadCursor
+#undef XcursorShapeLoadCursors
+#undef XcursorTryShapeCursor
+#undef XcursorNoticeCreateBitmap
+#undef XcursorNoticePutBitmap
+#undef XcursorTryShapeBitmapCursor
+#undef XcursorImageHash
+#undef XcursorSupportsARGB
+#undef XcursorSupportsAnim
+#undef XcursorSetDefaultSize
+#undef XcursorGetDefaultSize
+#undef XcursorSetTheme
+#undef XcursorGetTheme
+#undef XcursorGetThemeCore
+#undef XcursorSetThemeCore
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define XcursorImageCreate XcursorImageCreate_dylibloader_wrapper_xcursor
+#define XcursorImageDestroy XcursorImageDestroy_dylibloader_wrapper_xcursor
+#define XcursorImagesCreate XcursorImagesCreate_dylibloader_wrapper_xcursor
+#define XcursorImagesDestroy XcursorImagesDestroy_dylibloader_wrapper_xcursor
+#define XcursorImagesSetName XcursorImagesSetName_dylibloader_wrapper_xcursor
+#define XcursorCursorsCreate XcursorCursorsCreate_dylibloader_wrapper_xcursor
+#define XcursorCursorsDestroy XcursorCursorsDestroy_dylibloader_wrapper_xcursor
+#define XcursorAnimateCreate XcursorAnimateCreate_dylibloader_wrapper_xcursor
+#define XcursorAnimateDestroy XcursorAnimateDestroy_dylibloader_wrapper_xcursor
+#define XcursorAnimateNext XcursorAnimateNext_dylibloader_wrapper_xcursor
+#define XcursorCommentCreate XcursorCommentCreate_dylibloader_wrapper_xcursor
+#define XcursorCommentDestroy XcursorCommentDestroy_dylibloader_wrapper_xcursor
+#define XcursorCommentsCreate XcursorCommentsCreate_dylibloader_wrapper_xcursor
+#define XcursorCommentsDestroy XcursorCommentsDestroy_dylibloader_wrapper_xcursor
+#define XcursorXcFileLoadImage XcursorXcFileLoadImage_dylibloader_wrapper_xcursor
+#define XcursorXcFileLoadImages XcursorXcFileLoadImages_dylibloader_wrapper_xcursor
+#define XcursorXcFileLoadAllImages XcursorXcFileLoadAllImages_dylibloader_wrapper_xcursor
+#define XcursorXcFileLoad XcursorXcFileLoad_dylibloader_wrapper_xcursor
+#define XcursorXcFileSave XcursorXcFileSave_dylibloader_wrapper_xcursor
+#define XcursorFileLoadImage XcursorFileLoadImage_dylibloader_wrapper_xcursor
+#define XcursorFileLoadImages XcursorFileLoadImages_dylibloader_wrapper_xcursor
+#define XcursorFileLoadAllImages XcursorFileLoadAllImages_dylibloader_wrapper_xcursor
+#define XcursorFileLoad XcursorFileLoad_dylibloader_wrapper_xcursor
+#define XcursorFileSaveImages XcursorFileSaveImages_dylibloader_wrapper_xcursor
+#define XcursorFileSave XcursorFileSave_dylibloader_wrapper_xcursor
+#define XcursorFilenameLoadImage XcursorFilenameLoadImage_dylibloader_wrapper_xcursor
+#define XcursorFilenameLoadImages XcursorFilenameLoadImages_dylibloader_wrapper_xcursor
+#define XcursorFilenameLoadAllImages XcursorFilenameLoadAllImages_dylibloader_wrapper_xcursor
+#define XcursorFilenameLoad XcursorFilenameLoad_dylibloader_wrapper_xcursor
+#define XcursorFilenameSaveImages XcursorFilenameSaveImages_dylibloader_wrapper_xcursor
+#define XcursorFilenameSave XcursorFilenameSave_dylibloader_wrapper_xcursor
+#define XcursorLibraryLoadImage XcursorLibraryLoadImage_dylibloader_wrapper_xcursor
+#define XcursorLibraryLoadImages XcursorLibraryLoadImages_dylibloader_wrapper_xcursor
+#define XcursorLibraryPath XcursorLibraryPath_dylibloader_wrapper_xcursor
+#define XcursorLibraryShape XcursorLibraryShape_dylibloader_wrapper_xcursor
+#define XcursorImageLoadCursor XcursorImageLoadCursor_dylibloader_wrapper_xcursor
+#define XcursorImagesLoadCursors XcursorImagesLoadCursors_dylibloader_wrapper_xcursor
+#define XcursorImagesLoadCursor XcursorImagesLoadCursor_dylibloader_wrapper_xcursor
+#define XcursorFilenameLoadCursor XcursorFilenameLoadCursor_dylibloader_wrapper_xcursor
+#define XcursorFilenameLoadCursors XcursorFilenameLoadCursors_dylibloader_wrapper_xcursor
+#define XcursorLibraryLoadCursor XcursorLibraryLoadCursor_dylibloader_wrapper_xcursor
+#define XcursorLibraryLoadCursors XcursorLibraryLoadCursors_dylibloader_wrapper_xcursor
+#define XcursorShapeLoadImage XcursorShapeLoadImage_dylibloader_wrapper_xcursor
+#define XcursorShapeLoadImages XcursorShapeLoadImages_dylibloader_wrapper_xcursor
+#define XcursorShapeLoadCursor XcursorShapeLoadCursor_dylibloader_wrapper_xcursor
+#define XcursorShapeLoadCursors XcursorShapeLoadCursors_dylibloader_wrapper_xcursor
+#define XcursorTryShapeCursor XcursorTryShapeCursor_dylibloader_wrapper_xcursor
+#define XcursorNoticeCreateBitmap XcursorNoticeCreateBitmap_dylibloader_wrapper_xcursor
+#define XcursorNoticePutBitmap XcursorNoticePutBitmap_dylibloader_wrapper_xcursor
+#define XcursorTryShapeBitmapCursor XcursorTryShapeBitmapCursor_dylibloader_wrapper_xcursor
+#define XcursorImageHash XcursorImageHash_dylibloader_wrapper_xcursor
+#define XcursorSupportsARGB XcursorSupportsARGB_dylibloader_wrapper_xcursor
+#define XcursorSupportsAnim XcursorSupportsAnim_dylibloader_wrapper_xcursor
+#define XcursorSetDefaultSize XcursorSetDefaultSize_dylibloader_wrapper_xcursor
+#define XcursorGetDefaultSize XcursorGetDefaultSize_dylibloader_wrapper_xcursor
+#define XcursorSetTheme XcursorSetTheme_dylibloader_wrapper_xcursor
+#define XcursorGetTheme XcursorGetTheme_dylibloader_wrapper_xcursor
+#define XcursorGetThemeCore XcursorGetThemeCore_dylibloader_wrapper_xcursor
+#define XcursorSetThemeCore XcursorSetThemeCore_dylibloader_wrapper_xcursor
+extern XcursorImage* (*XcursorImageCreate_dylibloader_wrapper_xcursor)( int, int);
+extern void (*XcursorImageDestroy_dylibloader_wrapper_xcursor)( XcursorImage*);
+extern XcursorImages* (*XcursorImagesCreate_dylibloader_wrapper_xcursor)( int);
+extern void (*XcursorImagesDestroy_dylibloader_wrapper_xcursor)( XcursorImages*);
+extern void (*XcursorImagesSetName_dylibloader_wrapper_xcursor)( XcursorImages*,const char*);
+extern XcursorCursors* (*XcursorCursorsCreate_dylibloader_wrapper_xcursor)( Display*, int);
+extern void (*XcursorCursorsDestroy_dylibloader_wrapper_xcursor)( XcursorCursors*);
+extern XcursorAnimate* (*XcursorAnimateCreate_dylibloader_wrapper_xcursor)( XcursorCursors*);
+extern void (*XcursorAnimateDestroy_dylibloader_wrapper_xcursor)( XcursorAnimate*);
+extern Cursor (*XcursorAnimateNext_dylibloader_wrapper_xcursor)( XcursorAnimate*);
+extern XcursorComment* (*XcursorCommentCreate_dylibloader_wrapper_xcursor)( XcursorUInt, int);
+extern void (*XcursorCommentDestroy_dylibloader_wrapper_xcursor)( XcursorComment*);
+extern XcursorComments* (*XcursorCommentsCreate_dylibloader_wrapper_xcursor)( int);
+extern void (*XcursorCommentsDestroy_dylibloader_wrapper_xcursor)( XcursorComments*);
+extern XcursorImage* (*XcursorXcFileLoadImage_dylibloader_wrapper_xcursor)( XcursorFile*, int);
+extern XcursorImages* (*XcursorXcFileLoadImages_dylibloader_wrapper_xcursor)( XcursorFile*, int);
+extern XcursorImages* (*XcursorXcFileLoadAllImages_dylibloader_wrapper_xcursor)( XcursorFile*);
+extern XcursorBool (*XcursorXcFileLoad_dylibloader_wrapper_xcursor)( XcursorFile*, XcursorComments**, XcursorImages**);
+extern XcursorBool (*XcursorXcFileSave_dylibloader_wrapper_xcursor)( XcursorFile*,const XcursorComments*,const XcursorImages*);
+extern XcursorImage* (*XcursorFileLoadImage_dylibloader_wrapper_xcursor)( FILE*, int);
+extern XcursorImages* (*XcursorFileLoadImages_dylibloader_wrapper_xcursor)( FILE*, int);
+extern XcursorImages* (*XcursorFileLoadAllImages_dylibloader_wrapper_xcursor)( FILE*);
+extern XcursorBool (*XcursorFileLoad_dylibloader_wrapper_xcursor)( FILE*, XcursorComments**, XcursorImages**);
+extern XcursorBool (*XcursorFileSaveImages_dylibloader_wrapper_xcursor)( FILE*,const XcursorImages*);
+extern XcursorBool (*XcursorFileSave_dylibloader_wrapper_xcursor)( FILE*,const XcursorComments*,const XcursorImages*);
+extern XcursorImage* (*XcursorFilenameLoadImage_dylibloader_wrapper_xcursor)(const char*, int);
+extern XcursorImages* (*XcursorFilenameLoadImages_dylibloader_wrapper_xcursor)(const char*, int);
+extern XcursorImages* (*XcursorFilenameLoadAllImages_dylibloader_wrapper_xcursor)(const char*);
+extern XcursorBool (*XcursorFilenameLoad_dylibloader_wrapper_xcursor)(const char*, XcursorComments**, XcursorImages**);
+extern XcursorBool (*XcursorFilenameSaveImages_dylibloader_wrapper_xcursor)(const char*,const XcursorImages*);
+extern XcursorBool (*XcursorFilenameSave_dylibloader_wrapper_xcursor)(const char*,const XcursorComments*,const XcursorImages*);
+extern XcursorImage* (*XcursorLibraryLoadImage_dylibloader_wrapper_xcursor)(const char*,const char*, int);
+extern XcursorImages* (*XcursorLibraryLoadImages_dylibloader_wrapper_xcursor)(const char*,const char*, int);
+extern const char* (*XcursorLibraryPath_dylibloader_wrapper_xcursor)( void);
+extern int (*XcursorLibraryShape_dylibloader_wrapper_xcursor)(const char*);
+extern Cursor (*XcursorImageLoadCursor_dylibloader_wrapper_xcursor)( Display*,const XcursorImage*);
+extern XcursorCursors* (*XcursorImagesLoadCursors_dylibloader_wrapper_xcursor)( Display*,const XcursorImages*);
+extern Cursor (*XcursorImagesLoadCursor_dylibloader_wrapper_xcursor)( Display*,const XcursorImages*);
+extern Cursor (*XcursorFilenameLoadCursor_dylibloader_wrapper_xcursor)( Display*,const char*);
+extern XcursorCursors* (*XcursorFilenameLoadCursors_dylibloader_wrapper_xcursor)( Display*,const char*);
+extern Cursor (*XcursorLibraryLoadCursor_dylibloader_wrapper_xcursor)( Display*,const char*);
+extern XcursorCursors* (*XcursorLibraryLoadCursors_dylibloader_wrapper_xcursor)( Display*,const char*);
+extern XcursorImage* (*XcursorShapeLoadImage_dylibloader_wrapper_xcursor)( unsigned int,const char*, int);
+extern XcursorImages* (*XcursorShapeLoadImages_dylibloader_wrapper_xcursor)( unsigned int,const char*, int);
+extern Cursor (*XcursorShapeLoadCursor_dylibloader_wrapper_xcursor)( Display*, unsigned int);
+extern XcursorCursors* (*XcursorShapeLoadCursors_dylibloader_wrapper_xcursor)( Display*, unsigned int);
+extern Cursor (*XcursorTryShapeCursor_dylibloader_wrapper_xcursor)( Display*, Font, Font, unsigned int, unsigned int,const XColor*,const XColor*);
+extern void (*XcursorNoticeCreateBitmap_dylibloader_wrapper_xcursor)( Display*, Pixmap, unsigned int, unsigned int);
+extern void (*XcursorNoticePutBitmap_dylibloader_wrapper_xcursor)( Display*, Drawable, XImage*);
+extern Cursor (*XcursorTryShapeBitmapCursor_dylibloader_wrapper_xcursor)( Display*, Pixmap, Pixmap, XColor*, XColor*, unsigned int, unsigned int);
+extern void (*XcursorImageHash_dylibloader_wrapper_xcursor)( XImage*, unsigned char [16]);
+extern XcursorBool (*XcursorSupportsARGB_dylibloader_wrapper_xcursor)( Display*);
+extern XcursorBool (*XcursorSupportsAnim_dylibloader_wrapper_xcursor)( Display*);
+extern XcursorBool (*XcursorSetDefaultSize_dylibloader_wrapper_xcursor)( Display*, int);
+extern int (*XcursorGetDefaultSize_dylibloader_wrapper_xcursor)( Display*);
+extern XcursorBool (*XcursorSetTheme_dylibloader_wrapper_xcursor)( Display*,const char*);
+extern char* (*XcursorGetTheme_dylibloader_wrapper_xcursor)( Display*);
+extern XcursorBool (*XcursorGetThemeCore_dylibloader_wrapper_xcursor)( Display*);
+extern XcursorBool (*XcursorSetThemeCore_dylibloader_wrapper_xcursor)( Display*, XcursorBool);
+int initialize_xcursor(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/x11/dynwrappers/xext-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xext-so_wrap.c
new file mode 100644
index 0000000000..e9af9033a3
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xext-so_wrap.c
@@ -0,0 +1,154 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:11:29
+// flags: ../dynload-wrapper/generate-wrapper.py --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xext.h" --include ./thirdparty/linuxbsd_headers/X11/extensions/shape.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/shape.h" --soname libXext.so.6 --init-name xext --output-header ./platform/linuxbsd/x11/dynwrappers/xext-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xext-so_wrap.c
+//
+// NOTE: Generated from Xext 1.3.5.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXext.so.6, were removed and an include needed for
+// proper parsing was added (this had also to be temporarily added to the
+// original header, as dynload-wrapper would complain otherwise)
+#include <stdint.h>
+
+// HANDPATCH: Needed for a successful compilation.
+#include "thirdparty/linuxbsd_headers/X11/Xlib.h"
+
+#define XShapeQueryExtension XShapeQueryExtension_dylibloader_orig_xext
+#define XShapeQueryVersion XShapeQueryVersion_dylibloader_orig_xext
+#define XShapeCombineRegion XShapeCombineRegion_dylibloader_orig_xext
+#define XShapeCombineRectangles XShapeCombineRectangles_dylibloader_orig_xext
+#define XShapeCombineMask XShapeCombineMask_dylibloader_orig_xext
+#define XShapeCombineShape XShapeCombineShape_dylibloader_orig_xext
+#define XShapeOffsetShape XShapeOffsetShape_dylibloader_orig_xext
+#define XShapeQueryExtents XShapeQueryExtents_dylibloader_orig_xext
+#define XShapeSelectInput XShapeSelectInput_dylibloader_orig_xext
+#define XShapeInputSelected XShapeInputSelected_dylibloader_orig_xext
+#define XShapeGetRectangles XShapeGetRectangles_dylibloader_orig_xext
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xext.h"
+#include "thirdparty/linuxbsd_headers/X11/extensions/shape.h"
+#undef XShapeQueryExtension
+#undef XShapeQueryVersion
+#undef XShapeCombineRegion
+#undef XShapeCombineRectangles
+#undef XShapeCombineMask
+#undef XShapeCombineShape
+#undef XShapeOffsetShape
+#undef XShapeQueryExtents
+#undef XShapeSelectInput
+#undef XShapeInputSelected
+#undef XShapeGetRectangles
+#include <dlfcn.h>
+#include <stdio.h>
+int (*XShapeQueryExtension_dylibloader_wrapper_xext)( Display*, int*, int*);
+int (*XShapeQueryVersion_dylibloader_wrapper_xext)( Display*, int*, int*);
+void (*XShapeCombineRegion_dylibloader_wrapper_xext)( Display*, Window, int, int, int, Region, int);
+void (*XShapeCombineRectangles_dylibloader_wrapper_xext)( Display*, Window, int, int, int, XRectangle*, int, int, int);
+void (*XShapeCombineMask_dylibloader_wrapper_xext)( Display*, Window, int, int, int, Pixmap, int);
+void (*XShapeCombineShape_dylibloader_wrapper_xext)( Display*, Window, int, int, int, Window, int, int);
+void (*XShapeOffsetShape_dylibloader_wrapper_xext)( Display*, Window, int, int, int);
+int (*XShapeQueryExtents_dylibloader_wrapper_xext)( Display*, Window, int*, int*, int*, unsigned int*, unsigned int*, int*, int*, int*, unsigned int*, unsigned int*);
+void (*XShapeSelectInput_dylibloader_wrapper_xext)( Display*, Window, unsigned long);
+unsigned long (*XShapeInputSelected_dylibloader_wrapper_xext)( Display*, Window);
+XRectangle* (*XShapeGetRectangles_dylibloader_wrapper_xext)( Display*, Window, int, int*, int*);
+int initialize_xext(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libXext.so.6", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// XShapeQueryExtension
+ *(void **) (&XShapeQueryExtension_dylibloader_wrapper_xext) = dlsym(handle, "XShapeQueryExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeQueryVersion
+ *(void **) (&XShapeQueryVersion_dylibloader_wrapper_xext) = dlsym(handle, "XShapeQueryVersion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeCombineRegion
+ *(void **) (&XShapeCombineRegion_dylibloader_wrapper_xext) = dlsym(handle, "XShapeCombineRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeCombineRectangles
+ *(void **) (&XShapeCombineRectangles_dylibloader_wrapper_xext) = dlsym(handle, "XShapeCombineRectangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeCombineMask
+ *(void **) (&XShapeCombineMask_dylibloader_wrapper_xext) = dlsym(handle, "XShapeCombineMask");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeCombineShape
+ *(void **) (&XShapeCombineShape_dylibloader_wrapper_xext) = dlsym(handle, "XShapeCombineShape");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeOffsetShape
+ *(void **) (&XShapeOffsetShape_dylibloader_wrapper_xext) = dlsym(handle, "XShapeOffsetShape");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeQueryExtents
+ *(void **) (&XShapeQueryExtents_dylibloader_wrapper_xext) = dlsym(handle, "XShapeQueryExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeSelectInput
+ *(void **) (&XShapeSelectInput_dylibloader_wrapper_xext) = dlsym(handle, "XShapeSelectInput");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeInputSelected
+ *(void **) (&XShapeInputSelected_dylibloader_wrapper_xext) = dlsym(handle, "XShapeInputSelected");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShapeGetRectangles
+ *(void **) (&XShapeGetRectangles_dylibloader_wrapper_xext) = dlsym(handle, "XShapeGetRectangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xext-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xext-so_wrap.h
new file mode 100644
index 0000000000..bbf23fff34
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xext-so_wrap.h
@@ -0,0 +1,72 @@
+#ifndef DYLIBLOAD_WRAPPER_XEXT
+#define DYLIBLOAD_WRAPPER_XEXT
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:11:29
+// flags: ../dynload-wrapper/generate-wrapper.py --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xext.h" --include ./thirdparty/linuxbsd_headers/X11/extensions/shape.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/shape.h" --soname libXext.so.6 --init-name xext --output-header ./platform/linuxbsd/x11/dynwrappers/xext-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xext-so_wrap.c
+//
+// NOTE: Generated from Xext 1.3.5.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXext.so.6, were removed and an include needed for
+// proper parsing was added (this had also to be temporarily added to the
+// original header, as dynload-wrapper would complain otherwise)
+#include <stdint.h>
+
+// HANDPATCH: Needed for a successful compilation.
+#include "thirdparty/linuxbsd_headers/X11/Xlib.h"
+
+#define XShapeQueryExtension XShapeQueryExtension_dylibloader_orig_xext
+#define XShapeQueryVersion XShapeQueryVersion_dylibloader_orig_xext
+#define XShapeCombineRegion XShapeCombineRegion_dylibloader_orig_xext
+#define XShapeCombineRectangles XShapeCombineRectangles_dylibloader_orig_xext
+#define XShapeCombineMask XShapeCombineMask_dylibloader_orig_xext
+#define XShapeCombineShape XShapeCombineShape_dylibloader_orig_xext
+#define XShapeOffsetShape XShapeOffsetShape_dylibloader_orig_xext
+#define XShapeQueryExtents XShapeQueryExtents_dylibloader_orig_xext
+#define XShapeSelectInput XShapeSelectInput_dylibloader_orig_xext
+#define XShapeInputSelected XShapeInputSelected_dylibloader_orig_xext
+#define XShapeGetRectangles XShapeGetRectangles_dylibloader_orig_xext
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xext.h"
+#include "thirdparty/linuxbsd_headers/X11/extensions/shape.h"
+#undef XShapeQueryExtension
+#undef XShapeQueryVersion
+#undef XShapeCombineRegion
+#undef XShapeCombineRectangles
+#undef XShapeCombineMask
+#undef XShapeCombineShape
+#undef XShapeOffsetShape
+#undef XShapeQueryExtents
+#undef XShapeSelectInput
+#undef XShapeInputSelected
+#undef XShapeGetRectangles
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define XShapeQueryExtension XShapeQueryExtension_dylibloader_wrapper_xext
+#define XShapeQueryVersion XShapeQueryVersion_dylibloader_wrapper_xext
+#define XShapeCombineRegion XShapeCombineRegion_dylibloader_wrapper_xext
+#define XShapeCombineRectangles XShapeCombineRectangles_dylibloader_wrapper_xext
+#define XShapeCombineMask XShapeCombineMask_dylibloader_wrapper_xext
+#define XShapeCombineShape XShapeCombineShape_dylibloader_wrapper_xext
+#define XShapeOffsetShape XShapeOffsetShape_dylibloader_wrapper_xext
+#define XShapeQueryExtents XShapeQueryExtents_dylibloader_wrapper_xext
+#define XShapeSelectInput XShapeSelectInput_dylibloader_wrapper_xext
+#define XShapeInputSelected XShapeInputSelected_dylibloader_wrapper_xext
+#define XShapeGetRectangles XShapeGetRectangles_dylibloader_wrapper_xext
+extern int (*XShapeQueryExtension_dylibloader_wrapper_xext)( Display*, int*, int*);
+extern int (*XShapeQueryVersion_dylibloader_wrapper_xext)( Display*, int*, int*);
+extern void (*XShapeCombineRegion_dylibloader_wrapper_xext)( Display*, Window, int, int, int, Region, int);
+extern void (*XShapeCombineRectangles_dylibloader_wrapper_xext)( Display*, Window, int, int, int, XRectangle*, int, int, int);
+extern void (*XShapeCombineMask_dylibloader_wrapper_xext)( Display*, Window, int, int, int, Pixmap, int);
+extern void (*XShapeCombineShape_dylibloader_wrapper_xext)( Display*, Window, int, int, int, Window, int, int);
+extern void (*XShapeOffsetShape_dylibloader_wrapper_xext)( Display*, Window, int, int, int);
+extern int (*XShapeQueryExtents_dylibloader_wrapper_xext)( Display*, Window, int*, int*, int*, unsigned int*, unsigned int*, int*, int*, int*, unsigned int*, unsigned int*);
+extern void (*XShapeSelectInput_dylibloader_wrapper_xext)( Display*, Window, unsigned long);
+extern unsigned long (*XShapeInputSelected_dylibloader_wrapper_xext)( Display*, Window);
+extern XRectangle* (*XShapeGetRectangles_dylibloader_wrapper_xext)( Display*, Window, int, int*, int*);
+int initialize_xext(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.c
new file mode 100644
index 0000000000..ab53b232d6
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.c
@@ -0,0 +1,71 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:11:35
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/Xinerama.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xinerama.h" --soname libXinerama.so.1 --init-name xinerama --output-header ./platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.c
+//
+// NOTE: Generated from Xinerama 1.1.4.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXinerama.so.1, were removed.
+#include <stdint.h>
+
+#define XineramaQueryExtension XineramaQueryExtension_dylibloader_orig_xinerama
+#define XineramaQueryVersion XineramaQueryVersion_dylibloader_orig_xinerama
+#define XineramaIsActive XineramaIsActive_dylibloader_orig_xinerama
+#define XineramaQueryScreens XineramaQueryScreens_dylibloader_orig_xinerama
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xinerama.h"
+#undef XineramaQueryExtension
+#undef XineramaQueryVersion
+#undef XineramaIsActive
+#undef XineramaQueryScreens
+#include <dlfcn.h>
+#include <stdio.h>
+int (*XineramaQueryExtension_dylibloader_wrapper_xinerama)( Display*, int*, int*);
+int (*XineramaQueryVersion_dylibloader_wrapper_xinerama)( Display*, int*, int*);
+int (*XineramaIsActive_dylibloader_wrapper_xinerama)( Display*);
+XineramaScreenInfo* (*XineramaQueryScreens_dylibloader_wrapper_xinerama)( Display*, int*);
+int initialize_xinerama(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libXinerama.so.1", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// XineramaQueryExtension
+ *(void **) (&XineramaQueryExtension_dylibloader_wrapper_xinerama) = dlsym(handle, "XineramaQueryExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XineramaQueryVersion
+ *(void **) (&XineramaQueryVersion_dylibloader_wrapper_xinerama) = dlsym(handle, "XineramaQueryVersion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XineramaIsActive
+ *(void **) (&XineramaIsActive_dylibloader_wrapper_xinerama) = dlsym(handle, "XineramaIsActive");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XineramaQueryScreens
+ *(void **) (&XineramaQueryScreens_dylibloader_wrapper_xinerama) = dlsym(handle, "XineramaQueryScreens");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.h
new file mode 100644
index 0000000000..48d5cc44b7
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.h
@@ -0,0 +1,38 @@
+#ifndef DYLIBLOAD_WRAPPER_XINERAMA
+#define DYLIBLOAD_WRAPPER_XINERAMA
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:11:35
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/Xinerama.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xinerama.h" --soname libXinerama.so.1 --init-name xinerama --output-header ./platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xinerama-so_wrap.c
+//
+// NOTE: Generated from Xinerama 1.1.4.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXinerama.so.1, were removed.
+#include <stdint.h>
+
+#define XineramaQueryExtension XineramaQueryExtension_dylibloader_orig_xinerama
+#define XineramaQueryVersion XineramaQueryVersion_dylibloader_orig_xinerama
+#define XineramaIsActive XineramaIsActive_dylibloader_orig_xinerama
+#define XineramaQueryScreens XineramaQueryScreens_dylibloader_orig_xinerama
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xinerama.h"
+#undef XineramaQueryExtension
+#undef XineramaQueryVersion
+#undef XineramaIsActive
+#undef XineramaQueryScreens
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define XineramaQueryExtension XineramaQueryExtension_dylibloader_wrapper_xinerama
+#define XineramaQueryVersion XineramaQueryVersion_dylibloader_wrapper_xinerama
+#define XineramaIsActive XineramaIsActive_dylibloader_wrapper_xinerama
+#define XineramaQueryScreens XineramaQueryScreens_dylibloader_wrapper_xinerama
+extern int (*XineramaQueryExtension_dylibloader_wrapper_xinerama)( Display*, int*, int*);
+extern int (*XineramaQueryVersion_dylibloader_wrapper_xinerama)( Display*, int*, int*);
+extern int (*XineramaIsActive_dylibloader_wrapper_xinerama)( Display*);
+extern XineramaScreenInfo* (*XineramaQueryScreens_dylibloader_wrapper_xinerama)( Display*, int*);
+int initialize_xinerama(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.c
new file mode 100644
index 0000000000..d37f2b4d94
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.c
@@ -0,0 +1,401 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:12:16
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/XInput2.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/XInput2.h" --soname libXi.so.6 --init-name xinput2 --output-header ./platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.c
+//
+// NOTE: Generated from Xi 1.7.10.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, liXext and libXfixes, but absent in libXi.so.6, were removed.
+#include <stdint.h>
+
+#define XIQueryPointer XIQueryPointer_dylibloader_orig_xinput2
+#define XIWarpPointer XIWarpPointer_dylibloader_orig_xinput2
+#define XIDefineCursor XIDefineCursor_dylibloader_orig_xinput2
+#define XIUndefineCursor XIUndefineCursor_dylibloader_orig_xinput2
+#define XIChangeHierarchy XIChangeHierarchy_dylibloader_orig_xinput2
+#define XISetClientPointer XISetClientPointer_dylibloader_orig_xinput2
+#define XIGetClientPointer XIGetClientPointer_dylibloader_orig_xinput2
+#define XISelectEvents XISelectEvents_dylibloader_orig_xinput2
+#define XIGetSelectedEvents XIGetSelectedEvents_dylibloader_orig_xinput2
+#define XIQueryVersion XIQueryVersion_dylibloader_orig_xinput2
+#define XIQueryDevice XIQueryDevice_dylibloader_orig_xinput2
+#define XISetFocus XISetFocus_dylibloader_orig_xinput2
+#define XIGetFocus XIGetFocus_dylibloader_orig_xinput2
+#define XIGrabDevice XIGrabDevice_dylibloader_orig_xinput2
+#define XIUngrabDevice XIUngrabDevice_dylibloader_orig_xinput2
+#define XIAllowEvents XIAllowEvents_dylibloader_orig_xinput2
+#define XIAllowTouchEvents XIAllowTouchEvents_dylibloader_orig_xinput2
+#define XIGrabButton XIGrabButton_dylibloader_orig_xinput2
+#define XIGrabKeycode XIGrabKeycode_dylibloader_orig_xinput2
+#define XIGrabEnter XIGrabEnter_dylibloader_orig_xinput2
+#define XIGrabFocusIn XIGrabFocusIn_dylibloader_orig_xinput2
+#define XIGrabTouchBegin XIGrabTouchBegin_dylibloader_orig_xinput2
+#define XIUngrabButton XIUngrabButton_dylibloader_orig_xinput2
+#define XIUngrabKeycode XIUngrabKeycode_dylibloader_orig_xinput2
+#define XIUngrabEnter XIUngrabEnter_dylibloader_orig_xinput2
+#define XIUngrabFocusIn XIUngrabFocusIn_dylibloader_orig_xinput2
+#define XIUngrabTouchBegin XIUngrabTouchBegin_dylibloader_orig_xinput2
+#define XIListProperties XIListProperties_dylibloader_orig_xinput2
+#define XIChangeProperty XIChangeProperty_dylibloader_orig_xinput2
+#define XIDeleteProperty XIDeleteProperty_dylibloader_orig_xinput2
+#define XIGetProperty XIGetProperty_dylibloader_orig_xinput2
+#define XIBarrierReleasePointers XIBarrierReleasePointers_dylibloader_orig_xinput2
+#define XIBarrierReleasePointer XIBarrierReleasePointer_dylibloader_orig_xinput2
+#define XIFreeDeviceInfo XIFreeDeviceInfo_dylibloader_orig_xinput2
+#include "thirdparty/linuxbsd_headers/X11/extensions/XInput2.h"
+#undef XIQueryPointer
+#undef XIWarpPointer
+#undef XIDefineCursor
+#undef XIUndefineCursor
+#undef XIChangeHierarchy
+#undef XISetClientPointer
+#undef XIGetClientPointer
+#undef XISelectEvents
+#undef XIGetSelectedEvents
+#undef XIQueryVersion
+#undef XIQueryDevice
+#undef XISetFocus
+#undef XIGetFocus
+#undef XIGrabDevice
+#undef XIUngrabDevice
+#undef XIAllowEvents
+#undef XIAllowTouchEvents
+#undef XIGrabButton
+#undef XIGrabKeycode
+#undef XIGrabEnter
+#undef XIGrabFocusIn
+#undef XIGrabTouchBegin
+#undef XIUngrabButton
+#undef XIUngrabKeycode
+#undef XIUngrabEnter
+#undef XIUngrabFocusIn
+#undef XIUngrabTouchBegin
+#undef XIListProperties
+#undef XIChangeProperty
+#undef XIDeleteProperty
+#undef XIGetProperty
+#undef XIBarrierReleasePointers
+#undef XIBarrierReleasePointer
+#undef XIFreeDeviceInfo
+#include <dlfcn.h>
+#include <stdio.h>
+int (*XIQueryPointer_dylibloader_wrapper_xinput2)( Display*, int, Window, Window*, Window*, double*, double*, double*, double*, XIButtonState*, XIModifierState*, XIGroupState*);
+int (*XIWarpPointer_dylibloader_wrapper_xinput2)( Display*, int, Window, Window, double, double, unsigned int, unsigned int, double, double);
+int (*XIDefineCursor_dylibloader_wrapper_xinput2)( Display*, int, Window, Cursor);
+int (*XIUndefineCursor_dylibloader_wrapper_xinput2)( Display*, int, Window);
+int (*XIChangeHierarchy_dylibloader_wrapper_xinput2)( Display*, XIAnyHierarchyChangeInfo*, int);
+int (*XISetClientPointer_dylibloader_wrapper_xinput2)( Display*, Window, int);
+int (*XIGetClientPointer_dylibloader_wrapper_xinput2)( Display*, Window, int*);
+int (*XISelectEvents_dylibloader_wrapper_xinput2)( Display*, Window, XIEventMask*, int);
+XIEventMask* (*XIGetSelectedEvents_dylibloader_wrapper_xinput2)( Display*, Window, int*);
+int (*XIQueryVersion_dylibloader_wrapper_xinput2)( Display*, int*, int*);
+XIDeviceInfo* (*XIQueryDevice_dylibloader_wrapper_xinput2)( Display*, int, int*);
+int (*XISetFocus_dylibloader_wrapper_xinput2)( Display*, int, Window, Time);
+int (*XIGetFocus_dylibloader_wrapper_xinput2)( Display*, int, Window*);
+int (*XIGrabDevice_dylibloader_wrapper_xinput2)( Display*, int, Window, Time, Cursor, int, int, int, XIEventMask*);
+int (*XIUngrabDevice_dylibloader_wrapper_xinput2)( Display*, int, Time);
+int (*XIAllowEvents_dylibloader_wrapper_xinput2)( Display*, int, int, Time);
+int (*XIAllowTouchEvents_dylibloader_wrapper_xinput2)( Display*, int, unsigned int, Window, int);
+int (*XIGrabButton_dylibloader_wrapper_xinput2)( Display*, int, int, Window, Cursor, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+int (*XIGrabKeycode_dylibloader_wrapper_xinput2)( Display*, int, int, Window, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+int (*XIGrabEnter_dylibloader_wrapper_xinput2)( Display*, int, Window, Cursor, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+int (*XIGrabFocusIn_dylibloader_wrapper_xinput2)( Display*, int, Window, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+int (*XIGrabTouchBegin_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIEventMask*, int, XIGrabModifiers*);
+int (*XIUngrabButton_dylibloader_wrapper_xinput2)( Display*, int, int, Window, int, XIGrabModifiers*);
+int (*XIUngrabKeycode_dylibloader_wrapper_xinput2)( Display*, int, int, Window, int, XIGrabModifiers*);
+int (*XIUngrabEnter_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIGrabModifiers*);
+int (*XIUngrabFocusIn_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIGrabModifiers*);
+int (*XIUngrabTouchBegin_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIGrabModifiers*);
+Atom* (*XIListProperties_dylibloader_wrapper_xinput2)( Display*, int, int*);
+void (*XIChangeProperty_dylibloader_wrapper_xinput2)( Display*, int, Atom, Atom, int, int, unsigned char*, int);
+void (*XIDeleteProperty_dylibloader_wrapper_xinput2)( Display*, int, Atom);
+int (*XIGetProperty_dylibloader_wrapper_xinput2)( Display*, int, Atom, long, long, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+void (*XIBarrierReleasePointers_dylibloader_wrapper_xinput2)( Display*, XIBarrierReleasePointerInfo*, int);
+void (*XIBarrierReleasePointer_dylibloader_wrapper_xinput2)( Display*, int, PointerBarrier, BarrierEventID);
+void (*XIFreeDeviceInfo_dylibloader_wrapper_xinput2)( XIDeviceInfo*);
+int initialize_xinput2(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libXi.so.6", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// XIQueryPointer
+ *(void **) (&XIQueryPointer_dylibloader_wrapper_xinput2) = dlsym(handle, "XIQueryPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIWarpPointer
+ *(void **) (&XIWarpPointer_dylibloader_wrapper_xinput2) = dlsym(handle, "XIWarpPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIDefineCursor
+ *(void **) (&XIDefineCursor_dylibloader_wrapper_xinput2) = dlsym(handle, "XIDefineCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIUndefineCursor
+ *(void **) (&XIUndefineCursor_dylibloader_wrapper_xinput2) = dlsym(handle, "XIUndefineCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIChangeHierarchy
+ *(void **) (&XIChangeHierarchy_dylibloader_wrapper_xinput2) = dlsym(handle, "XIChangeHierarchy");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XISetClientPointer
+ *(void **) (&XISetClientPointer_dylibloader_wrapper_xinput2) = dlsym(handle, "XISetClientPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGetClientPointer
+ *(void **) (&XIGetClientPointer_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGetClientPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XISelectEvents
+ *(void **) (&XISelectEvents_dylibloader_wrapper_xinput2) = dlsym(handle, "XISelectEvents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGetSelectedEvents
+ *(void **) (&XIGetSelectedEvents_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGetSelectedEvents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIQueryVersion
+ *(void **) (&XIQueryVersion_dylibloader_wrapper_xinput2) = dlsym(handle, "XIQueryVersion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIQueryDevice
+ *(void **) (&XIQueryDevice_dylibloader_wrapper_xinput2) = dlsym(handle, "XIQueryDevice");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XISetFocus
+ *(void **) (&XISetFocus_dylibloader_wrapper_xinput2) = dlsym(handle, "XISetFocus");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGetFocus
+ *(void **) (&XIGetFocus_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGetFocus");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGrabDevice
+ *(void **) (&XIGrabDevice_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGrabDevice");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIUngrabDevice
+ *(void **) (&XIUngrabDevice_dylibloader_wrapper_xinput2) = dlsym(handle, "XIUngrabDevice");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIAllowEvents
+ *(void **) (&XIAllowEvents_dylibloader_wrapper_xinput2) = dlsym(handle, "XIAllowEvents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIAllowTouchEvents
+ *(void **) (&XIAllowTouchEvents_dylibloader_wrapper_xinput2) = dlsym(handle, "XIAllowTouchEvents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGrabButton
+ *(void **) (&XIGrabButton_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGrabButton");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGrabKeycode
+ *(void **) (&XIGrabKeycode_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGrabKeycode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGrabEnter
+ *(void **) (&XIGrabEnter_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGrabEnter");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGrabFocusIn
+ *(void **) (&XIGrabFocusIn_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGrabFocusIn");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGrabTouchBegin
+ *(void **) (&XIGrabTouchBegin_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGrabTouchBegin");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIUngrabButton
+ *(void **) (&XIUngrabButton_dylibloader_wrapper_xinput2) = dlsym(handle, "XIUngrabButton");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIUngrabKeycode
+ *(void **) (&XIUngrabKeycode_dylibloader_wrapper_xinput2) = dlsym(handle, "XIUngrabKeycode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIUngrabEnter
+ *(void **) (&XIUngrabEnter_dylibloader_wrapper_xinput2) = dlsym(handle, "XIUngrabEnter");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIUngrabFocusIn
+ *(void **) (&XIUngrabFocusIn_dylibloader_wrapper_xinput2) = dlsym(handle, "XIUngrabFocusIn");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIUngrabTouchBegin
+ *(void **) (&XIUngrabTouchBegin_dylibloader_wrapper_xinput2) = dlsym(handle, "XIUngrabTouchBegin");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIListProperties
+ *(void **) (&XIListProperties_dylibloader_wrapper_xinput2) = dlsym(handle, "XIListProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIChangeProperty
+ *(void **) (&XIChangeProperty_dylibloader_wrapper_xinput2) = dlsym(handle, "XIChangeProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIDeleteProperty
+ *(void **) (&XIDeleteProperty_dylibloader_wrapper_xinput2) = dlsym(handle, "XIDeleteProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIGetProperty
+ *(void **) (&XIGetProperty_dylibloader_wrapper_xinput2) = dlsym(handle, "XIGetProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIBarrierReleasePointers
+ *(void **) (&XIBarrierReleasePointers_dylibloader_wrapper_xinput2) = dlsym(handle, "XIBarrierReleasePointers");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIBarrierReleasePointer
+ *(void **) (&XIBarrierReleasePointer_dylibloader_wrapper_xinput2) = dlsym(handle, "XIBarrierReleasePointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIFreeDeviceInfo
+ *(void **) (&XIFreeDeviceInfo_dylibloader_wrapper_xinput2) = dlsym(handle, "XIFreeDeviceInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.h
new file mode 100644
index 0000000000..e39661ffb9
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.h
@@ -0,0 +1,158 @@
+#ifndef DYLIBLOAD_WRAPPER_XINPUT2
+#define DYLIBLOAD_WRAPPER_XINPUT2
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:12:16
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/XInput2.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/XInput2.h" --soname libXi.so.6 --init-name xinput2 --output-header ./platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xinput2-so_wrap.c
+//
+// NOTE: Generated from Xi 1.7.10.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, liXext and libXfixes, but absent in libXi.so.6, were removed.
+#include <stdint.h>
+
+#define XIQueryPointer XIQueryPointer_dylibloader_orig_xinput2
+#define XIWarpPointer XIWarpPointer_dylibloader_orig_xinput2
+#define XIDefineCursor XIDefineCursor_dylibloader_orig_xinput2
+#define XIUndefineCursor XIUndefineCursor_dylibloader_orig_xinput2
+#define XIChangeHierarchy XIChangeHierarchy_dylibloader_orig_xinput2
+#define XISetClientPointer XISetClientPointer_dylibloader_orig_xinput2
+#define XIGetClientPointer XIGetClientPointer_dylibloader_orig_xinput2
+#define XISelectEvents XISelectEvents_dylibloader_orig_xinput2
+#define XIGetSelectedEvents XIGetSelectedEvents_dylibloader_orig_xinput2
+#define XIQueryVersion XIQueryVersion_dylibloader_orig_xinput2
+#define XIQueryDevice XIQueryDevice_dylibloader_orig_xinput2
+#define XISetFocus XISetFocus_dylibloader_orig_xinput2
+#define XIGetFocus XIGetFocus_dylibloader_orig_xinput2
+#define XIGrabDevice XIGrabDevice_dylibloader_orig_xinput2
+#define XIUngrabDevice XIUngrabDevice_dylibloader_orig_xinput2
+#define XIAllowEvents XIAllowEvents_dylibloader_orig_xinput2
+#define XIAllowTouchEvents XIAllowTouchEvents_dylibloader_orig_xinput2
+#define XIGrabButton XIGrabButton_dylibloader_orig_xinput2
+#define XIGrabKeycode XIGrabKeycode_dylibloader_orig_xinput2
+#define XIGrabEnter XIGrabEnter_dylibloader_orig_xinput2
+#define XIGrabFocusIn XIGrabFocusIn_dylibloader_orig_xinput2
+#define XIGrabTouchBegin XIGrabTouchBegin_dylibloader_orig_xinput2
+#define XIUngrabButton XIUngrabButton_dylibloader_orig_xinput2
+#define XIUngrabKeycode XIUngrabKeycode_dylibloader_orig_xinput2
+#define XIUngrabEnter XIUngrabEnter_dylibloader_orig_xinput2
+#define XIUngrabFocusIn XIUngrabFocusIn_dylibloader_orig_xinput2
+#define XIUngrabTouchBegin XIUngrabTouchBegin_dylibloader_orig_xinput2
+#define XIListProperties XIListProperties_dylibloader_orig_xinput2
+#define XIChangeProperty XIChangeProperty_dylibloader_orig_xinput2
+#define XIDeleteProperty XIDeleteProperty_dylibloader_orig_xinput2
+#define XIGetProperty XIGetProperty_dylibloader_orig_xinput2
+#define XIBarrierReleasePointers XIBarrierReleasePointers_dylibloader_orig_xinput2
+#define XIBarrierReleasePointer XIBarrierReleasePointer_dylibloader_orig_xinput2
+#define XIFreeDeviceInfo XIFreeDeviceInfo_dylibloader_orig_xinput2
+#include "thirdparty/linuxbsd_headers/X11/extensions/XInput2.h"
+#undef XIQueryPointer
+#undef XIWarpPointer
+#undef XIDefineCursor
+#undef XIUndefineCursor
+#undef XIChangeHierarchy
+#undef XISetClientPointer
+#undef XIGetClientPointer
+#undef XISelectEvents
+#undef XIGetSelectedEvents
+#undef XIQueryVersion
+#undef XIQueryDevice
+#undef XISetFocus
+#undef XIGetFocus
+#undef XIGrabDevice
+#undef XIUngrabDevice
+#undef XIAllowEvents
+#undef XIAllowTouchEvents
+#undef XIGrabButton
+#undef XIGrabKeycode
+#undef XIGrabEnter
+#undef XIGrabFocusIn
+#undef XIGrabTouchBegin
+#undef XIUngrabButton
+#undef XIUngrabKeycode
+#undef XIUngrabEnter
+#undef XIUngrabFocusIn
+#undef XIUngrabTouchBegin
+#undef XIListProperties
+#undef XIChangeProperty
+#undef XIDeleteProperty
+#undef XIGetProperty
+#undef XIBarrierReleasePointers
+#undef XIBarrierReleasePointer
+#undef XIFreeDeviceInfo
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define XIQueryPointer XIQueryPointer_dylibloader_wrapper_xinput2
+#define XIWarpPointer XIWarpPointer_dylibloader_wrapper_xinput2
+#define XIDefineCursor XIDefineCursor_dylibloader_wrapper_xinput2
+#define XIUndefineCursor XIUndefineCursor_dylibloader_wrapper_xinput2
+#define XIChangeHierarchy XIChangeHierarchy_dylibloader_wrapper_xinput2
+#define XISetClientPointer XISetClientPointer_dylibloader_wrapper_xinput2
+#define XIGetClientPointer XIGetClientPointer_dylibloader_wrapper_xinput2
+#define XISelectEvents XISelectEvents_dylibloader_wrapper_xinput2
+#define XIGetSelectedEvents XIGetSelectedEvents_dylibloader_wrapper_xinput2
+#define XIQueryVersion XIQueryVersion_dylibloader_wrapper_xinput2
+#define XIQueryDevice XIQueryDevice_dylibloader_wrapper_xinput2
+#define XISetFocus XISetFocus_dylibloader_wrapper_xinput2
+#define XIGetFocus XIGetFocus_dylibloader_wrapper_xinput2
+#define XIGrabDevice XIGrabDevice_dylibloader_wrapper_xinput2
+#define XIUngrabDevice XIUngrabDevice_dylibloader_wrapper_xinput2
+#define XIAllowEvents XIAllowEvents_dylibloader_wrapper_xinput2
+#define XIAllowTouchEvents XIAllowTouchEvents_dylibloader_wrapper_xinput2
+#define XIGrabButton XIGrabButton_dylibloader_wrapper_xinput2
+#define XIGrabKeycode XIGrabKeycode_dylibloader_wrapper_xinput2
+#define XIGrabEnter XIGrabEnter_dylibloader_wrapper_xinput2
+#define XIGrabFocusIn XIGrabFocusIn_dylibloader_wrapper_xinput2
+#define XIGrabTouchBegin XIGrabTouchBegin_dylibloader_wrapper_xinput2
+#define XIUngrabButton XIUngrabButton_dylibloader_wrapper_xinput2
+#define XIUngrabKeycode XIUngrabKeycode_dylibloader_wrapper_xinput2
+#define XIUngrabEnter XIUngrabEnter_dylibloader_wrapper_xinput2
+#define XIUngrabFocusIn XIUngrabFocusIn_dylibloader_wrapper_xinput2
+#define XIUngrabTouchBegin XIUngrabTouchBegin_dylibloader_wrapper_xinput2
+#define XIListProperties XIListProperties_dylibloader_wrapper_xinput2
+#define XIChangeProperty XIChangeProperty_dylibloader_wrapper_xinput2
+#define XIDeleteProperty XIDeleteProperty_dylibloader_wrapper_xinput2
+#define XIGetProperty XIGetProperty_dylibloader_wrapper_xinput2
+#define XIBarrierReleasePointers XIBarrierReleasePointers_dylibloader_wrapper_xinput2
+#define XIBarrierReleasePointer XIBarrierReleasePointer_dylibloader_wrapper_xinput2
+#define XIFreeDeviceInfo XIFreeDeviceInfo_dylibloader_wrapper_xinput2
+extern int (*XIQueryPointer_dylibloader_wrapper_xinput2)( Display*, int, Window, Window*, Window*, double*, double*, double*, double*, XIButtonState*, XIModifierState*, XIGroupState*);
+extern int (*XIWarpPointer_dylibloader_wrapper_xinput2)( Display*, int, Window, Window, double, double, unsigned int, unsigned int, double, double);
+extern int (*XIDefineCursor_dylibloader_wrapper_xinput2)( Display*, int, Window, Cursor);
+extern int (*XIUndefineCursor_dylibloader_wrapper_xinput2)( Display*, int, Window);
+extern int (*XIChangeHierarchy_dylibloader_wrapper_xinput2)( Display*, XIAnyHierarchyChangeInfo*, int);
+extern int (*XISetClientPointer_dylibloader_wrapper_xinput2)( Display*, Window, int);
+extern int (*XIGetClientPointer_dylibloader_wrapper_xinput2)( Display*, Window, int*);
+extern int (*XISelectEvents_dylibloader_wrapper_xinput2)( Display*, Window, XIEventMask*, int);
+extern XIEventMask* (*XIGetSelectedEvents_dylibloader_wrapper_xinput2)( Display*, Window, int*);
+extern int (*XIQueryVersion_dylibloader_wrapper_xinput2)( Display*, int*, int*);
+extern XIDeviceInfo* (*XIQueryDevice_dylibloader_wrapper_xinput2)( Display*, int, int*);
+extern int (*XISetFocus_dylibloader_wrapper_xinput2)( Display*, int, Window, Time);
+extern int (*XIGetFocus_dylibloader_wrapper_xinput2)( Display*, int, Window*);
+extern int (*XIGrabDevice_dylibloader_wrapper_xinput2)( Display*, int, Window, Time, Cursor, int, int, int, XIEventMask*);
+extern int (*XIUngrabDevice_dylibloader_wrapper_xinput2)( Display*, int, Time);
+extern int (*XIAllowEvents_dylibloader_wrapper_xinput2)( Display*, int, int, Time);
+extern int (*XIAllowTouchEvents_dylibloader_wrapper_xinput2)( Display*, int, unsigned int, Window, int);
+extern int (*XIGrabButton_dylibloader_wrapper_xinput2)( Display*, int, int, Window, Cursor, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+extern int (*XIGrabKeycode_dylibloader_wrapper_xinput2)( Display*, int, int, Window, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+extern int (*XIGrabEnter_dylibloader_wrapper_xinput2)( Display*, int, Window, Cursor, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+extern int (*XIGrabFocusIn_dylibloader_wrapper_xinput2)( Display*, int, Window, int, int, int, XIEventMask*, int, XIGrabModifiers*);
+extern int (*XIGrabTouchBegin_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIEventMask*, int, XIGrabModifiers*);
+extern int (*XIUngrabButton_dylibloader_wrapper_xinput2)( Display*, int, int, Window, int, XIGrabModifiers*);
+extern int (*XIUngrabKeycode_dylibloader_wrapper_xinput2)( Display*, int, int, Window, int, XIGrabModifiers*);
+extern int (*XIUngrabEnter_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIGrabModifiers*);
+extern int (*XIUngrabFocusIn_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIGrabModifiers*);
+extern int (*XIUngrabTouchBegin_dylibloader_wrapper_xinput2)( Display*, int, Window, int, XIGrabModifiers*);
+extern Atom* (*XIListProperties_dylibloader_wrapper_xinput2)( Display*, int, int*);
+extern void (*XIChangeProperty_dylibloader_wrapper_xinput2)( Display*, int, Atom, Atom, int, int, unsigned char*, int);
+extern void (*XIDeleteProperty_dylibloader_wrapper_xinput2)( Display*, int, Atom);
+extern int (*XIGetProperty_dylibloader_wrapper_xinput2)( Display*, int, Atom, long, long, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+extern void (*XIBarrierReleasePointers_dylibloader_wrapper_xinput2)( Display*, XIBarrierReleasePointerInfo*, int);
+extern void (*XIBarrierReleasePointer_dylibloader_wrapper_xinput2)( Display*, int, PointerBarrier, BarrierEventID);
+extern void (*XIFreeDeviceInfo_dylibloader_wrapper_xinput2)( XIDeviceInfo*);
+int initialize_xinput2(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.c
new file mode 100644
index 0000000000..601d4c5052
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.c
@@ -0,0 +1,859 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:14:21
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/xkbcommon/xkbcommon.h --sys-include "./thirdparty/linuxbsd_headers/xkbcommon/xkbcommon.h" --soname libxkbcommon.so.0 --init-name xkbcommon --output-header ./platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.c
+//
+#include <stdint.h>
+
+#define xkb_keysym_get_name xkb_keysym_get_name_dylibloader_orig_xkbcommon
+#define xkb_keysym_from_name xkb_keysym_from_name_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_utf8 xkb_keysym_to_utf8_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_utf32 xkb_keysym_to_utf32_dylibloader_orig_xkbcommon
+#define xkb_utf32_to_keysym xkb_utf32_to_keysym_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_upper xkb_keysym_to_upper_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_lower xkb_keysym_to_lower_dylibloader_orig_xkbcommon
+#define xkb_context_new xkb_context_new_dylibloader_orig_xkbcommon
+#define xkb_context_ref xkb_context_ref_dylibloader_orig_xkbcommon
+#define xkb_context_unref xkb_context_unref_dylibloader_orig_xkbcommon
+#define xkb_context_set_user_data xkb_context_set_user_data_dylibloader_orig_xkbcommon
+#define xkb_context_get_user_data xkb_context_get_user_data_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_append xkb_context_include_path_append_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_append_default xkb_context_include_path_append_default_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_reset_defaults xkb_context_include_path_reset_defaults_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_clear xkb_context_include_path_clear_dylibloader_orig_xkbcommon
+#define xkb_context_num_include_paths xkb_context_num_include_paths_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_get xkb_context_include_path_get_dylibloader_orig_xkbcommon
+#define xkb_context_set_log_level xkb_context_set_log_level_dylibloader_orig_xkbcommon
+#define xkb_context_get_log_level xkb_context_get_log_level_dylibloader_orig_xkbcommon
+#define xkb_context_set_log_verbosity xkb_context_set_log_verbosity_dylibloader_orig_xkbcommon
+#define xkb_context_get_log_verbosity xkb_context_get_log_verbosity_dylibloader_orig_xkbcommon
+#define xkb_context_set_log_fn xkb_context_set_log_fn_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_names xkb_keymap_new_from_names_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_file xkb_keymap_new_from_file_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_string xkb_keymap_new_from_string_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_buffer xkb_keymap_new_from_buffer_dylibloader_orig_xkbcommon
+#define xkb_keymap_ref xkb_keymap_ref_dylibloader_orig_xkbcommon
+#define xkb_keymap_unref xkb_keymap_unref_dylibloader_orig_xkbcommon
+#define xkb_keymap_get_as_string xkb_keymap_get_as_string_dylibloader_orig_xkbcommon
+#define xkb_keymap_min_keycode xkb_keymap_min_keycode_dylibloader_orig_xkbcommon
+#define xkb_keymap_max_keycode xkb_keymap_max_keycode_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_for_each xkb_keymap_key_for_each_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_get_name xkb_keymap_key_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_by_name xkb_keymap_key_by_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_mods xkb_keymap_num_mods_dylibloader_orig_xkbcommon
+#define xkb_keymap_mod_get_name xkb_keymap_mod_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_mod_get_index xkb_keymap_mod_get_index_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_layouts xkb_keymap_num_layouts_dylibloader_orig_xkbcommon
+#define xkb_keymap_layout_get_name xkb_keymap_layout_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_layout_get_index xkb_keymap_layout_get_index_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_leds xkb_keymap_num_leds_dylibloader_orig_xkbcommon
+#define xkb_keymap_led_get_name xkb_keymap_led_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_led_get_index xkb_keymap_led_get_index_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_layouts_for_key xkb_keymap_num_layouts_for_key_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_levels_for_key xkb_keymap_num_levels_for_key_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_get_mods_for_level xkb_keymap_key_get_mods_for_level_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_get_syms_by_level xkb_keymap_key_get_syms_by_level_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_repeats xkb_keymap_key_repeats_dylibloader_orig_xkbcommon
+#define xkb_state_new xkb_state_new_dylibloader_orig_xkbcommon
+#define xkb_state_ref xkb_state_ref_dylibloader_orig_xkbcommon
+#define xkb_state_unref xkb_state_unref_dylibloader_orig_xkbcommon
+#define xkb_state_get_keymap xkb_state_get_keymap_dylibloader_orig_xkbcommon
+#define xkb_state_update_key xkb_state_update_key_dylibloader_orig_xkbcommon
+#define xkb_state_update_mask xkb_state_update_mask_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_syms xkb_state_key_get_syms_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_utf8 xkb_state_key_get_utf8_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_utf32 xkb_state_key_get_utf32_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_one_sym xkb_state_key_get_one_sym_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_layout xkb_state_key_get_layout_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_level xkb_state_key_get_level_dylibloader_orig_xkbcommon
+#define xkb_state_serialize_mods xkb_state_serialize_mods_dylibloader_orig_xkbcommon
+#define xkb_state_serialize_layout xkb_state_serialize_layout_dylibloader_orig_xkbcommon
+#define xkb_state_mod_name_is_active xkb_state_mod_name_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_mod_names_are_active xkb_state_mod_names_are_active_dylibloader_orig_xkbcommon
+#define xkb_state_mod_index_is_active xkb_state_mod_index_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_mod_indices_are_active xkb_state_mod_indices_are_active_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_consumed_mods2 xkb_state_key_get_consumed_mods2_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_consumed_mods xkb_state_key_get_consumed_mods_dylibloader_orig_xkbcommon
+#define xkb_state_mod_index_is_consumed2 xkb_state_mod_index_is_consumed2_dylibloader_orig_xkbcommon
+#define xkb_state_mod_index_is_consumed xkb_state_mod_index_is_consumed_dylibloader_orig_xkbcommon
+#define xkb_state_mod_mask_remove_consumed xkb_state_mod_mask_remove_consumed_dylibloader_orig_xkbcommon
+#define xkb_state_layout_name_is_active xkb_state_layout_name_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_layout_index_is_active xkb_state_layout_index_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_led_name_is_active xkb_state_led_name_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_led_index_is_active xkb_state_led_index_is_active_dylibloader_orig_xkbcommon
+#include "./thirdparty/linuxbsd_headers/xkbcommon/xkbcommon.h"
+#undef xkb_keysym_get_name
+#undef xkb_keysym_from_name
+#undef xkb_keysym_to_utf8
+#undef xkb_keysym_to_utf32
+#undef xkb_utf32_to_keysym
+#undef xkb_keysym_to_upper
+#undef xkb_keysym_to_lower
+#undef xkb_context_new
+#undef xkb_context_ref
+#undef xkb_context_unref
+#undef xkb_context_set_user_data
+#undef xkb_context_get_user_data
+#undef xkb_context_include_path_append
+#undef xkb_context_include_path_append_default
+#undef xkb_context_include_path_reset_defaults
+#undef xkb_context_include_path_clear
+#undef xkb_context_num_include_paths
+#undef xkb_context_include_path_get
+#undef xkb_context_set_log_level
+#undef xkb_context_get_log_level
+#undef xkb_context_set_log_verbosity
+#undef xkb_context_get_log_verbosity
+#undef xkb_context_set_log_fn
+#undef xkb_keymap_new_from_names
+#undef xkb_keymap_new_from_file
+#undef xkb_keymap_new_from_string
+#undef xkb_keymap_new_from_buffer
+#undef xkb_keymap_ref
+#undef xkb_keymap_unref
+#undef xkb_keymap_get_as_string
+#undef xkb_keymap_min_keycode
+#undef xkb_keymap_max_keycode
+#undef xkb_keymap_key_for_each
+#undef xkb_keymap_key_get_name
+#undef xkb_keymap_key_by_name
+#undef xkb_keymap_num_mods
+#undef xkb_keymap_mod_get_name
+#undef xkb_keymap_mod_get_index
+#undef xkb_keymap_num_layouts
+#undef xkb_keymap_layout_get_name
+#undef xkb_keymap_layout_get_index
+#undef xkb_keymap_num_leds
+#undef xkb_keymap_led_get_name
+#undef xkb_keymap_led_get_index
+#undef xkb_keymap_num_layouts_for_key
+#undef xkb_keymap_num_levels_for_key
+#undef xkb_keymap_key_get_mods_for_level
+#undef xkb_keymap_key_get_syms_by_level
+#undef xkb_keymap_key_repeats
+#undef xkb_state_new
+#undef xkb_state_ref
+#undef xkb_state_unref
+#undef xkb_state_get_keymap
+#undef xkb_state_update_key
+#undef xkb_state_update_mask
+#undef xkb_state_key_get_syms
+#undef xkb_state_key_get_utf8
+#undef xkb_state_key_get_utf32
+#undef xkb_state_key_get_one_sym
+#undef xkb_state_key_get_layout
+#undef xkb_state_key_get_level
+#undef xkb_state_serialize_mods
+#undef xkb_state_serialize_layout
+#undef xkb_state_mod_name_is_active
+#undef xkb_state_mod_names_are_active
+#undef xkb_state_mod_index_is_active
+#undef xkb_state_mod_indices_are_active
+#undef xkb_state_key_get_consumed_mods2
+#undef xkb_state_key_get_consumed_mods
+#undef xkb_state_mod_index_is_consumed2
+#undef xkb_state_mod_index_is_consumed
+#undef xkb_state_mod_mask_remove_consumed
+#undef xkb_state_layout_name_is_active
+#undef xkb_state_layout_index_is_active
+#undef xkb_state_led_name_is_active
+#undef xkb_state_led_index_is_active
+#include <dlfcn.h>
+#include <stdio.h>
+int (*xkb_keysym_get_name_dylibloader_wrapper_xkbcommon)( xkb_keysym_t, char*, size_t);
+xkb_keysym_t (*xkb_keysym_from_name_dylibloader_wrapper_xkbcommon)(const char*,enum xkb_keysym_flags);
+int (*xkb_keysym_to_utf8_dylibloader_wrapper_xkbcommon)( xkb_keysym_t, char*, size_t);
+uint32_t (*xkb_keysym_to_utf32_dylibloader_wrapper_xkbcommon)( xkb_keysym_t);
+xkb_keysym_t (*xkb_utf32_to_keysym_dylibloader_wrapper_xkbcommon)( uint32_t);
+xkb_keysym_t (*xkb_keysym_to_upper_dylibloader_wrapper_xkbcommon)( xkb_keysym_t);
+xkb_keysym_t (*xkb_keysym_to_lower_dylibloader_wrapper_xkbcommon)( xkb_keysym_t);
+struct xkb_context* (*xkb_context_new_dylibloader_wrapper_xkbcommon)(enum xkb_context_flags);
+struct xkb_context* (*xkb_context_ref_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+void (*xkb_context_unref_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+void (*xkb_context_set_user_data_dylibloader_wrapper_xkbcommon)(struct xkb_context*, void*);
+void* (*xkb_context_get_user_data_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+int (*xkb_context_include_path_append_dylibloader_wrapper_xkbcommon)(struct xkb_context*,const char*);
+int (*xkb_context_include_path_append_default_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+int (*xkb_context_include_path_reset_defaults_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+void (*xkb_context_include_path_clear_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+unsigned int (*xkb_context_num_include_paths_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+const char* (*xkb_context_include_path_get_dylibloader_wrapper_xkbcommon)(struct xkb_context*, unsigned int);
+void (*xkb_context_set_log_level_dylibloader_wrapper_xkbcommon)(struct xkb_context*,enum xkb_log_level);
+enum xkb_log_level (*xkb_context_get_log_level_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+void (*xkb_context_set_log_verbosity_dylibloader_wrapper_xkbcommon)(struct xkb_context*, int);
+int (*xkb_context_get_log_verbosity_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+void (*xkb_context_set_log_fn_dylibloader_wrapper_xkbcommon)(struct xkb_context*, void*);
+struct xkb_keymap* (*xkb_keymap_new_from_names_dylibloader_wrapper_xkbcommon)(struct xkb_context*,struct xkb_rule_names*,enum xkb_keymap_compile_flags);
+struct xkb_keymap* (*xkb_keymap_new_from_file_dylibloader_wrapper_xkbcommon)(struct xkb_context*, FILE*,enum xkb_keymap_format,enum xkb_keymap_compile_flags);
+struct xkb_keymap* (*xkb_keymap_new_from_string_dylibloader_wrapper_xkbcommon)(struct xkb_context*,const char*,enum xkb_keymap_format,enum xkb_keymap_compile_flags);
+struct xkb_keymap* (*xkb_keymap_new_from_buffer_dylibloader_wrapper_xkbcommon)(struct xkb_context*,const char*, size_t,enum xkb_keymap_format,enum xkb_keymap_compile_flags);
+struct xkb_keymap* (*xkb_keymap_ref_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+void (*xkb_keymap_unref_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+char* (*xkb_keymap_get_as_string_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,enum xkb_keymap_format);
+xkb_keycode_t (*xkb_keymap_min_keycode_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+xkb_keycode_t (*xkb_keymap_max_keycode_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+void (*xkb_keymap_key_for_each_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keymap_key_iter_t, void*);
+const char* (*xkb_keymap_key_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t);
+xkb_keycode_t (*xkb_keymap_key_by_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+xkb_mod_index_t (*xkb_keymap_num_mods_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+const char* (*xkb_keymap_mod_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_mod_index_t);
+xkb_mod_index_t (*xkb_keymap_mod_get_index_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+xkb_layout_index_t (*xkb_keymap_num_layouts_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+const char* (*xkb_keymap_layout_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_layout_index_t);
+xkb_layout_index_t (*xkb_keymap_layout_get_index_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+xkb_led_index_t (*xkb_keymap_num_leds_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+const char* (*xkb_keymap_led_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_led_index_t);
+xkb_led_index_t (*xkb_keymap_led_get_index_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+xkb_layout_index_t (*xkb_keymap_num_layouts_for_key_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t);
+xkb_level_index_t (*xkb_keymap_num_levels_for_key_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t, xkb_layout_index_t);
+size_t (*xkb_keymap_key_get_mods_for_level_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t, xkb_layout_index_t, xkb_level_index_t, xkb_mod_mask_t*, size_t);
+int (*xkb_keymap_key_get_syms_by_level_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t, xkb_layout_index_t, xkb_level_index_t,const xkb_keysym_t**);
+int (*xkb_keymap_key_repeats_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t);
+struct xkb_state* (*xkb_state_new_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+struct xkb_state* (*xkb_state_ref_dylibloader_wrapper_xkbcommon)(struct xkb_state*);
+void (*xkb_state_unref_dylibloader_wrapper_xkbcommon)(struct xkb_state*);
+struct xkb_keymap* (*xkb_state_get_keymap_dylibloader_wrapper_xkbcommon)(struct xkb_state*);
+enum xkb_state_component (*xkb_state_update_key_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t,enum xkb_key_direction);
+enum xkb_state_component (*xkb_state_update_mask_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_mod_mask_t, xkb_mod_mask_t, xkb_mod_mask_t, xkb_layout_index_t, xkb_layout_index_t, xkb_layout_index_t);
+int (*xkb_state_key_get_syms_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t,const xkb_keysym_t**);
+int (*xkb_state_key_get_utf8_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, char*, size_t);
+uint32_t (*xkb_state_key_get_utf32_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+xkb_keysym_t (*xkb_state_key_get_one_sym_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+xkb_layout_index_t (*xkb_state_key_get_layout_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+xkb_level_index_t (*xkb_state_key_get_level_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_layout_index_t);
+xkb_mod_mask_t (*xkb_state_serialize_mods_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component);
+xkb_layout_index_t (*xkb_state_serialize_layout_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component);
+int (*xkb_state_mod_name_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,const char*,enum xkb_state_component);
+int (*xkb_state_mod_names_are_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component,enum xkb_state_match,...);
+int (*xkb_state_mod_index_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_mod_index_t,enum xkb_state_component);
+int (*xkb_state_mod_indices_are_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component,enum xkb_state_match,...);
+xkb_mod_mask_t (*xkb_state_key_get_consumed_mods2_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t,enum xkb_consumed_mode);
+xkb_mod_mask_t (*xkb_state_key_get_consumed_mods_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+int (*xkb_state_mod_index_is_consumed2_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_mod_index_t,enum xkb_consumed_mode);
+int (*xkb_state_mod_index_is_consumed_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_mod_index_t);
+xkb_mod_mask_t (*xkb_state_mod_mask_remove_consumed_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_mod_mask_t);
+int (*xkb_state_layout_name_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,const char*,enum xkb_state_component);
+int (*xkb_state_layout_index_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_layout_index_t,enum xkb_state_component);
+int (*xkb_state_led_name_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,const char*);
+int (*xkb_state_led_index_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_led_index_t);
+int initialize_xkbcommon(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libxkbcommon.so.0", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// xkb_keysym_get_name
+ *(void **) (&xkb_keysym_get_name_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keysym_get_name");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keysym_from_name
+ *(void **) (&xkb_keysym_from_name_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keysym_from_name");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keysym_to_utf8
+ *(void **) (&xkb_keysym_to_utf8_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keysym_to_utf8");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keysym_to_utf32
+ *(void **) (&xkb_keysym_to_utf32_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keysym_to_utf32");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_utf32_to_keysym
+ *(void **) (&xkb_utf32_to_keysym_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_utf32_to_keysym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keysym_to_upper
+ *(void **) (&xkb_keysym_to_upper_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keysym_to_upper");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keysym_to_lower
+ *(void **) (&xkb_keysym_to_lower_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keysym_to_lower");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_new
+ *(void **) (&xkb_context_new_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_new");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_ref
+ *(void **) (&xkb_context_ref_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_ref");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_unref
+ *(void **) (&xkb_context_unref_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_unref");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_set_user_data
+ *(void **) (&xkb_context_set_user_data_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_set_user_data");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_get_user_data
+ *(void **) (&xkb_context_get_user_data_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_get_user_data");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_include_path_append
+ *(void **) (&xkb_context_include_path_append_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_include_path_append");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_include_path_append_default
+ *(void **) (&xkb_context_include_path_append_default_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_include_path_append_default");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_include_path_reset_defaults
+ *(void **) (&xkb_context_include_path_reset_defaults_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_include_path_reset_defaults");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_include_path_clear
+ *(void **) (&xkb_context_include_path_clear_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_include_path_clear");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_num_include_paths
+ *(void **) (&xkb_context_num_include_paths_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_num_include_paths");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_include_path_get
+ *(void **) (&xkb_context_include_path_get_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_include_path_get");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_set_log_level
+ *(void **) (&xkb_context_set_log_level_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_set_log_level");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_get_log_level
+ *(void **) (&xkb_context_get_log_level_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_get_log_level");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_set_log_verbosity
+ *(void **) (&xkb_context_set_log_verbosity_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_set_log_verbosity");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_get_log_verbosity
+ *(void **) (&xkb_context_get_log_verbosity_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_get_log_verbosity");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_context_set_log_fn
+ *(void **) (&xkb_context_set_log_fn_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_context_set_log_fn");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_new_from_names
+ *(void **) (&xkb_keymap_new_from_names_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_new_from_names");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_new_from_file
+ *(void **) (&xkb_keymap_new_from_file_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_new_from_file");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_new_from_string
+ *(void **) (&xkb_keymap_new_from_string_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_new_from_string");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_new_from_buffer
+ *(void **) (&xkb_keymap_new_from_buffer_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_new_from_buffer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_ref
+ *(void **) (&xkb_keymap_ref_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_ref");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_unref
+ *(void **) (&xkb_keymap_unref_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_unref");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_get_as_string
+ *(void **) (&xkb_keymap_get_as_string_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_get_as_string");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_min_keycode
+ *(void **) (&xkb_keymap_min_keycode_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_min_keycode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_max_keycode
+ *(void **) (&xkb_keymap_max_keycode_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_max_keycode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_key_for_each
+ *(void **) (&xkb_keymap_key_for_each_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_key_for_each");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_key_get_name
+ *(void **) (&xkb_keymap_key_get_name_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_key_get_name");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_key_by_name
+ *(void **) (&xkb_keymap_key_by_name_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_key_by_name");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_num_mods
+ *(void **) (&xkb_keymap_num_mods_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_num_mods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_mod_get_name
+ *(void **) (&xkb_keymap_mod_get_name_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_mod_get_name");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_mod_get_index
+ *(void **) (&xkb_keymap_mod_get_index_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_mod_get_index");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_num_layouts
+ *(void **) (&xkb_keymap_num_layouts_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_num_layouts");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_layout_get_name
+ *(void **) (&xkb_keymap_layout_get_name_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_layout_get_name");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_layout_get_index
+ *(void **) (&xkb_keymap_layout_get_index_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_layout_get_index");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_num_leds
+ *(void **) (&xkb_keymap_num_leds_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_num_leds");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_led_get_name
+ *(void **) (&xkb_keymap_led_get_name_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_led_get_name");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_led_get_index
+ *(void **) (&xkb_keymap_led_get_index_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_led_get_index");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_num_layouts_for_key
+ *(void **) (&xkb_keymap_num_layouts_for_key_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_num_layouts_for_key");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_num_levels_for_key
+ *(void **) (&xkb_keymap_num_levels_for_key_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_num_levels_for_key");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_key_get_mods_for_level
+ *(void **) (&xkb_keymap_key_get_mods_for_level_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_key_get_mods_for_level");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_key_get_syms_by_level
+ *(void **) (&xkb_keymap_key_get_syms_by_level_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_key_get_syms_by_level");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_keymap_key_repeats
+ *(void **) (&xkb_keymap_key_repeats_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_keymap_key_repeats");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_new
+ *(void **) (&xkb_state_new_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_new");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_ref
+ *(void **) (&xkb_state_ref_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_ref");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_unref
+ *(void **) (&xkb_state_unref_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_unref");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_get_keymap
+ *(void **) (&xkb_state_get_keymap_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_get_keymap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_update_key
+ *(void **) (&xkb_state_update_key_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_update_key");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_update_mask
+ *(void **) (&xkb_state_update_mask_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_update_mask");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_syms
+ *(void **) (&xkb_state_key_get_syms_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_syms");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_utf8
+ *(void **) (&xkb_state_key_get_utf8_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_utf8");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_utf32
+ *(void **) (&xkb_state_key_get_utf32_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_utf32");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_one_sym
+ *(void **) (&xkb_state_key_get_one_sym_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_one_sym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_layout
+ *(void **) (&xkb_state_key_get_layout_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_layout");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_level
+ *(void **) (&xkb_state_key_get_level_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_level");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_serialize_mods
+ *(void **) (&xkb_state_serialize_mods_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_serialize_mods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_serialize_layout
+ *(void **) (&xkb_state_serialize_layout_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_serialize_layout");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_mod_name_is_active
+ *(void **) (&xkb_state_mod_name_is_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_mod_name_is_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_mod_names_are_active
+ *(void **) (&xkb_state_mod_names_are_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_mod_names_are_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_mod_index_is_active
+ *(void **) (&xkb_state_mod_index_is_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_mod_index_is_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_mod_indices_are_active
+ *(void **) (&xkb_state_mod_indices_are_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_mod_indices_are_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_consumed_mods2
+ *(void **) (&xkb_state_key_get_consumed_mods2_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_consumed_mods2");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_key_get_consumed_mods
+ *(void **) (&xkb_state_key_get_consumed_mods_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_key_get_consumed_mods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_mod_index_is_consumed2
+ *(void **) (&xkb_state_mod_index_is_consumed2_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_mod_index_is_consumed2");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_mod_index_is_consumed
+ *(void **) (&xkb_state_mod_index_is_consumed_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_mod_index_is_consumed");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_mod_mask_remove_consumed
+ *(void **) (&xkb_state_mod_mask_remove_consumed_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_mod_mask_remove_consumed");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_layout_name_is_active
+ *(void **) (&xkb_state_layout_name_is_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_layout_name_is_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_layout_index_is_active
+ *(void **) (&xkb_state_layout_index_is_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_layout_index_is_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_led_name_is_active
+ *(void **) (&xkb_state_led_name_is_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_led_name_is_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// xkb_state_led_index_is_active
+ *(void **) (&xkb_state_led_index_is_active_dylibloader_wrapper_xkbcommon) = dlsym(handle, "xkb_state_led_index_is_active");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.h
new file mode 100644
index 0000000000..f7e6f4c4cf
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.h
@@ -0,0 +1,322 @@
+#ifndef DYLIBLOAD_WRAPPER_XKBCOMMON
+#define DYLIBLOAD_WRAPPER_XKBCOMMON
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:14:21
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/xkbcommon/xkbcommon.h --sys-include "./thirdparty/linuxbsd_headers/xkbcommon/xkbcommon.h" --soname libxkbcommon.so.0 --init-name xkbcommon --output-header ./platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xkbcommon-so_wrap.c
+//
+#include <stdint.h>
+
+#define xkb_keysym_get_name xkb_keysym_get_name_dylibloader_orig_xkbcommon
+#define xkb_keysym_from_name xkb_keysym_from_name_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_utf8 xkb_keysym_to_utf8_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_utf32 xkb_keysym_to_utf32_dylibloader_orig_xkbcommon
+#define xkb_utf32_to_keysym xkb_utf32_to_keysym_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_upper xkb_keysym_to_upper_dylibloader_orig_xkbcommon
+#define xkb_keysym_to_lower xkb_keysym_to_lower_dylibloader_orig_xkbcommon
+#define xkb_context_new xkb_context_new_dylibloader_orig_xkbcommon
+#define xkb_context_ref xkb_context_ref_dylibloader_orig_xkbcommon
+#define xkb_context_unref xkb_context_unref_dylibloader_orig_xkbcommon
+#define xkb_context_set_user_data xkb_context_set_user_data_dylibloader_orig_xkbcommon
+#define xkb_context_get_user_data xkb_context_get_user_data_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_append xkb_context_include_path_append_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_append_default xkb_context_include_path_append_default_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_reset_defaults xkb_context_include_path_reset_defaults_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_clear xkb_context_include_path_clear_dylibloader_orig_xkbcommon
+#define xkb_context_num_include_paths xkb_context_num_include_paths_dylibloader_orig_xkbcommon
+#define xkb_context_include_path_get xkb_context_include_path_get_dylibloader_orig_xkbcommon
+#define xkb_context_set_log_level xkb_context_set_log_level_dylibloader_orig_xkbcommon
+#define xkb_context_get_log_level xkb_context_get_log_level_dylibloader_orig_xkbcommon
+#define xkb_context_set_log_verbosity xkb_context_set_log_verbosity_dylibloader_orig_xkbcommon
+#define xkb_context_get_log_verbosity xkb_context_get_log_verbosity_dylibloader_orig_xkbcommon
+#define xkb_context_set_log_fn xkb_context_set_log_fn_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_names xkb_keymap_new_from_names_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_file xkb_keymap_new_from_file_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_string xkb_keymap_new_from_string_dylibloader_orig_xkbcommon
+#define xkb_keymap_new_from_buffer xkb_keymap_new_from_buffer_dylibloader_orig_xkbcommon
+#define xkb_keymap_ref xkb_keymap_ref_dylibloader_orig_xkbcommon
+#define xkb_keymap_unref xkb_keymap_unref_dylibloader_orig_xkbcommon
+#define xkb_keymap_get_as_string xkb_keymap_get_as_string_dylibloader_orig_xkbcommon
+#define xkb_keymap_min_keycode xkb_keymap_min_keycode_dylibloader_orig_xkbcommon
+#define xkb_keymap_max_keycode xkb_keymap_max_keycode_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_for_each xkb_keymap_key_for_each_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_get_name xkb_keymap_key_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_by_name xkb_keymap_key_by_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_mods xkb_keymap_num_mods_dylibloader_orig_xkbcommon
+#define xkb_keymap_mod_get_name xkb_keymap_mod_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_mod_get_index xkb_keymap_mod_get_index_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_layouts xkb_keymap_num_layouts_dylibloader_orig_xkbcommon
+#define xkb_keymap_layout_get_name xkb_keymap_layout_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_layout_get_index xkb_keymap_layout_get_index_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_leds xkb_keymap_num_leds_dylibloader_orig_xkbcommon
+#define xkb_keymap_led_get_name xkb_keymap_led_get_name_dylibloader_orig_xkbcommon
+#define xkb_keymap_led_get_index xkb_keymap_led_get_index_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_layouts_for_key xkb_keymap_num_layouts_for_key_dylibloader_orig_xkbcommon
+#define xkb_keymap_num_levels_for_key xkb_keymap_num_levels_for_key_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_get_mods_for_level xkb_keymap_key_get_mods_for_level_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_get_syms_by_level xkb_keymap_key_get_syms_by_level_dylibloader_orig_xkbcommon
+#define xkb_keymap_key_repeats xkb_keymap_key_repeats_dylibloader_orig_xkbcommon
+#define xkb_state_new xkb_state_new_dylibloader_orig_xkbcommon
+#define xkb_state_ref xkb_state_ref_dylibloader_orig_xkbcommon
+#define xkb_state_unref xkb_state_unref_dylibloader_orig_xkbcommon
+#define xkb_state_get_keymap xkb_state_get_keymap_dylibloader_orig_xkbcommon
+#define xkb_state_update_key xkb_state_update_key_dylibloader_orig_xkbcommon
+#define xkb_state_update_mask xkb_state_update_mask_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_syms xkb_state_key_get_syms_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_utf8 xkb_state_key_get_utf8_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_utf32 xkb_state_key_get_utf32_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_one_sym xkb_state_key_get_one_sym_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_layout xkb_state_key_get_layout_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_level xkb_state_key_get_level_dylibloader_orig_xkbcommon
+#define xkb_state_serialize_mods xkb_state_serialize_mods_dylibloader_orig_xkbcommon
+#define xkb_state_serialize_layout xkb_state_serialize_layout_dylibloader_orig_xkbcommon
+#define xkb_state_mod_name_is_active xkb_state_mod_name_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_mod_names_are_active xkb_state_mod_names_are_active_dylibloader_orig_xkbcommon
+#define xkb_state_mod_index_is_active xkb_state_mod_index_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_mod_indices_are_active xkb_state_mod_indices_are_active_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_consumed_mods2 xkb_state_key_get_consumed_mods2_dylibloader_orig_xkbcommon
+#define xkb_state_key_get_consumed_mods xkb_state_key_get_consumed_mods_dylibloader_orig_xkbcommon
+#define xkb_state_mod_index_is_consumed2 xkb_state_mod_index_is_consumed2_dylibloader_orig_xkbcommon
+#define xkb_state_mod_index_is_consumed xkb_state_mod_index_is_consumed_dylibloader_orig_xkbcommon
+#define xkb_state_mod_mask_remove_consumed xkb_state_mod_mask_remove_consumed_dylibloader_orig_xkbcommon
+#define xkb_state_layout_name_is_active xkb_state_layout_name_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_layout_index_is_active xkb_state_layout_index_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_led_name_is_active xkb_state_led_name_is_active_dylibloader_orig_xkbcommon
+#define xkb_state_led_index_is_active xkb_state_led_index_is_active_dylibloader_orig_xkbcommon
+#include "./thirdparty/linuxbsd_headers/xkbcommon/xkbcommon.h"
+#undef xkb_keysym_get_name
+#undef xkb_keysym_from_name
+#undef xkb_keysym_to_utf8
+#undef xkb_keysym_to_utf32
+#undef xkb_utf32_to_keysym
+#undef xkb_keysym_to_upper
+#undef xkb_keysym_to_lower
+#undef xkb_context_new
+#undef xkb_context_ref
+#undef xkb_context_unref
+#undef xkb_context_set_user_data
+#undef xkb_context_get_user_data
+#undef xkb_context_include_path_append
+#undef xkb_context_include_path_append_default
+#undef xkb_context_include_path_reset_defaults
+#undef xkb_context_include_path_clear
+#undef xkb_context_num_include_paths
+#undef xkb_context_include_path_get
+#undef xkb_context_set_log_level
+#undef xkb_context_get_log_level
+#undef xkb_context_set_log_verbosity
+#undef xkb_context_get_log_verbosity
+#undef xkb_context_set_log_fn
+#undef xkb_keymap_new_from_names
+#undef xkb_keymap_new_from_file
+#undef xkb_keymap_new_from_string
+#undef xkb_keymap_new_from_buffer
+#undef xkb_keymap_ref
+#undef xkb_keymap_unref
+#undef xkb_keymap_get_as_string
+#undef xkb_keymap_min_keycode
+#undef xkb_keymap_max_keycode
+#undef xkb_keymap_key_for_each
+#undef xkb_keymap_key_get_name
+#undef xkb_keymap_key_by_name
+#undef xkb_keymap_num_mods
+#undef xkb_keymap_mod_get_name
+#undef xkb_keymap_mod_get_index
+#undef xkb_keymap_num_layouts
+#undef xkb_keymap_layout_get_name
+#undef xkb_keymap_layout_get_index
+#undef xkb_keymap_num_leds
+#undef xkb_keymap_led_get_name
+#undef xkb_keymap_led_get_index
+#undef xkb_keymap_num_layouts_for_key
+#undef xkb_keymap_num_levels_for_key
+#undef xkb_keymap_key_get_mods_for_level
+#undef xkb_keymap_key_get_syms_by_level
+#undef xkb_keymap_key_repeats
+#undef xkb_state_new
+#undef xkb_state_ref
+#undef xkb_state_unref
+#undef xkb_state_get_keymap
+#undef xkb_state_update_key
+#undef xkb_state_update_mask
+#undef xkb_state_key_get_syms
+#undef xkb_state_key_get_utf8
+#undef xkb_state_key_get_utf32
+#undef xkb_state_key_get_one_sym
+#undef xkb_state_key_get_layout
+#undef xkb_state_key_get_level
+#undef xkb_state_serialize_mods
+#undef xkb_state_serialize_layout
+#undef xkb_state_mod_name_is_active
+#undef xkb_state_mod_names_are_active
+#undef xkb_state_mod_index_is_active
+#undef xkb_state_mod_indices_are_active
+#undef xkb_state_key_get_consumed_mods2
+#undef xkb_state_key_get_consumed_mods
+#undef xkb_state_mod_index_is_consumed2
+#undef xkb_state_mod_index_is_consumed
+#undef xkb_state_mod_mask_remove_consumed
+#undef xkb_state_layout_name_is_active
+#undef xkb_state_layout_index_is_active
+#undef xkb_state_led_name_is_active
+#undef xkb_state_led_index_is_active
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define xkb_keysym_get_name xkb_keysym_get_name_dylibloader_wrapper_xkbcommon
+#define xkb_keysym_from_name xkb_keysym_from_name_dylibloader_wrapper_xkbcommon
+#define xkb_keysym_to_utf8 xkb_keysym_to_utf8_dylibloader_wrapper_xkbcommon
+#define xkb_keysym_to_utf32 xkb_keysym_to_utf32_dylibloader_wrapper_xkbcommon
+#define xkb_utf32_to_keysym xkb_utf32_to_keysym_dylibloader_wrapper_xkbcommon
+#define xkb_keysym_to_upper xkb_keysym_to_upper_dylibloader_wrapper_xkbcommon
+#define xkb_keysym_to_lower xkb_keysym_to_lower_dylibloader_wrapper_xkbcommon
+#define xkb_context_new xkb_context_new_dylibloader_wrapper_xkbcommon
+#define xkb_context_ref xkb_context_ref_dylibloader_wrapper_xkbcommon
+#define xkb_context_unref xkb_context_unref_dylibloader_wrapper_xkbcommon
+#define xkb_context_set_user_data xkb_context_set_user_data_dylibloader_wrapper_xkbcommon
+#define xkb_context_get_user_data xkb_context_get_user_data_dylibloader_wrapper_xkbcommon
+#define xkb_context_include_path_append xkb_context_include_path_append_dylibloader_wrapper_xkbcommon
+#define xkb_context_include_path_append_default xkb_context_include_path_append_default_dylibloader_wrapper_xkbcommon
+#define xkb_context_include_path_reset_defaults xkb_context_include_path_reset_defaults_dylibloader_wrapper_xkbcommon
+#define xkb_context_include_path_clear xkb_context_include_path_clear_dylibloader_wrapper_xkbcommon
+#define xkb_context_num_include_paths xkb_context_num_include_paths_dylibloader_wrapper_xkbcommon
+#define xkb_context_include_path_get xkb_context_include_path_get_dylibloader_wrapper_xkbcommon
+#define xkb_context_set_log_level xkb_context_set_log_level_dylibloader_wrapper_xkbcommon
+#define xkb_context_get_log_level xkb_context_get_log_level_dylibloader_wrapper_xkbcommon
+#define xkb_context_set_log_verbosity xkb_context_set_log_verbosity_dylibloader_wrapper_xkbcommon
+#define xkb_context_get_log_verbosity xkb_context_get_log_verbosity_dylibloader_wrapper_xkbcommon
+#define xkb_context_set_log_fn xkb_context_set_log_fn_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_new_from_names xkb_keymap_new_from_names_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_new_from_file xkb_keymap_new_from_file_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_new_from_string xkb_keymap_new_from_string_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_new_from_buffer xkb_keymap_new_from_buffer_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_ref xkb_keymap_ref_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_unref xkb_keymap_unref_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_get_as_string xkb_keymap_get_as_string_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_min_keycode xkb_keymap_min_keycode_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_max_keycode xkb_keymap_max_keycode_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_key_for_each xkb_keymap_key_for_each_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_key_get_name xkb_keymap_key_get_name_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_key_by_name xkb_keymap_key_by_name_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_num_mods xkb_keymap_num_mods_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_mod_get_name xkb_keymap_mod_get_name_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_mod_get_index xkb_keymap_mod_get_index_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_num_layouts xkb_keymap_num_layouts_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_layout_get_name xkb_keymap_layout_get_name_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_layout_get_index xkb_keymap_layout_get_index_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_num_leds xkb_keymap_num_leds_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_led_get_name xkb_keymap_led_get_name_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_led_get_index xkb_keymap_led_get_index_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_num_layouts_for_key xkb_keymap_num_layouts_for_key_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_num_levels_for_key xkb_keymap_num_levels_for_key_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_key_get_mods_for_level xkb_keymap_key_get_mods_for_level_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_key_get_syms_by_level xkb_keymap_key_get_syms_by_level_dylibloader_wrapper_xkbcommon
+#define xkb_keymap_key_repeats xkb_keymap_key_repeats_dylibloader_wrapper_xkbcommon
+#define xkb_state_new xkb_state_new_dylibloader_wrapper_xkbcommon
+#define xkb_state_ref xkb_state_ref_dylibloader_wrapper_xkbcommon
+#define xkb_state_unref xkb_state_unref_dylibloader_wrapper_xkbcommon
+#define xkb_state_get_keymap xkb_state_get_keymap_dylibloader_wrapper_xkbcommon
+#define xkb_state_update_key xkb_state_update_key_dylibloader_wrapper_xkbcommon
+#define xkb_state_update_mask xkb_state_update_mask_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_syms xkb_state_key_get_syms_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_utf8 xkb_state_key_get_utf8_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_utf32 xkb_state_key_get_utf32_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_one_sym xkb_state_key_get_one_sym_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_layout xkb_state_key_get_layout_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_level xkb_state_key_get_level_dylibloader_wrapper_xkbcommon
+#define xkb_state_serialize_mods xkb_state_serialize_mods_dylibloader_wrapper_xkbcommon
+#define xkb_state_serialize_layout xkb_state_serialize_layout_dylibloader_wrapper_xkbcommon
+#define xkb_state_mod_name_is_active xkb_state_mod_name_is_active_dylibloader_wrapper_xkbcommon
+#define xkb_state_mod_names_are_active xkb_state_mod_names_are_active_dylibloader_wrapper_xkbcommon
+#define xkb_state_mod_index_is_active xkb_state_mod_index_is_active_dylibloader_wrapper_xkbcommon
+#define xkb_state_mod_indices_are_active xkb_state_mod_indices_are_active_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_consumed_mods2 xkb_state_key_get_consumed_mods2_dylibloader_wrapper_xkbcommon
+#define xkb_state_key_get_consumed_mods xkb_state_key_get_consumed_mods_dylibloader_wrapper_xkbcommon
+#define xkb_state_mod_index_is_consumed2 xkb_state_mod_index_is_consumed2_dylibloader_wrapper_xkbcommon
+#define xkb_state_mod_index_is_consumed xkb_state_mod_index_is_consumed_dylibloader_wrapper_xkbcommon
+#define xkb_state_mod_mask_remove_consumed xkb_state_mod_mask_remove_consumed_dylibloader_wrapper_xkbcommon
+#define xkb_state_layout_name_is_active xkb_state_layout_name_is_active_dylibloader_wrapper_xkbcommon
+#define xkb_state_layout_index_is_active xkb_state_layout_index_is_active_dylibloader_wrapper_xkbcommon
+#define xkb_state_led_name_is_active xkb_state_led_name_is_active_dylibloader_wrapper_xkbcommon
+#define xkb_state_led_index_is_active xkb_state_led_index_is_active_dylibloader_wrapper_xkbcommon
+extern int (*xkb_keysym_get_name_dylibloader_wrapper_xkbcommon)( xkb_keysym_t, char*, size_t);
+extern xkb_keysym_t (*xkb_keysym_from_name_dylibloader_wrapper_xkbcommon)(const char*,enum xkb_keysym_flags);
+extern int (*xkb_keysym_to_utf8_dylibloader_wrapper_xkbcommon)( xkb_keysym_t, char*, size_t);
+extern uint32_t (*xkb_keysym_to_utf32_dylibloader_wrapper_xkbcommon)( xkb_keysym_t);
+extern xkb_keysym_t (*xkb_utf32_to_keysym_dylibloader_wrapper_xkbcommon)( uint32_t);
+extern xkb_keysym_t (*xkb_keysym_to_upper_dylibloader_wrapper_xkbcommon)( xkb_keysym_t);
+extern xkb_keysym_t (*xkb_keysym_to_lower_dylibloader_wrapper_xkbcommon)( xkb_keysym_t);
+extern struct xkb_context* (*xkb_context_new_dylibloader_wrapper_xkbcommon)(enum xkb_context_flags);
+extern struct xkb_context* (*xkb_context_ref_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern void (*xkb_context_unref_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern void (*xkb_context_set_user_data_dylibloader_wrapper_xkbcommon)(struct xkb_context*, void*);
+extern void* (*xkb_context_get_user_data_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern int (*xkb_context_include_path_append_dylibloader_wrapper_xkbcommon)(struct xkb_context*,const char*);
+extern int (*xkb_context_include_path_append_default_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern int (*xkb_context_include_path_reset_defaults_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern void (*xkb_context_include_path_clear_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern unsigned int (*xkb_context_num_include_paths_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern const char* (*xkb_context_include_path_get_dylibloader_wrapper_xkbcommon)(struct xkb_context*, unsigned int);
+extern void (*xkb_context_set_log_level_dylibloader_wrapper_xkbcommon)(struct xkb_context*,enum xkb_log_level);
+extern enum xkb_log_level (*xkb_context_get_log_level_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern void (*xkb_context_set_log_verbosity_dylibloader_wrapper_xkbcommon)(struct xkb_context*, int);
+extern int (*xkb_context_get_log_verbosity_dylibloader_wrapper_xkbcommon)(struct xkb_context*);
+extern void (*xkb_context_set_log_fn_dylibloader_wrapper_xkbcommon)(struct xkb_context*, void*);
+extern struct xkb_keymap* (*xkb_keymap_new_from_names_dylibloader_wrapper_xkbcommon)(struct xkb_context*,struct xkb_rule_names*,enum xkb_keymap_compile_flags);
+extern struct xkb_keymap* (*xkb_keymap_new_from_file_dylibloader_wrapper_xkbcommon)(struct xkb_context*, FILE*,enum xkb_keymap_format,enum xkb_keymap_compile_flags);
+extern struct xkb_keymap* (*xkb_keymap_new_from_string_dylibloader_wrapper_xkbcommon)(struct xkb_context*,const char*,enum xkb_keymap_format,enum xkb_keymap_compile_flags);
+extern struct xkb_keymap* (*xkb_keymap_new_from_buffer_dylibloader_wrapper_xkbcommon)(struct xkb_context*,const char*, size_t,enum xkb_keymap_format,enum xkb_keymap_compile_flags);
+extern struct xkb_keymap* (*xkb_keymap_ref_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern void (*xkb_keymap_unref_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern char* (*xkb_keymap_get_as_string_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,enum xkb_keymap_format);
+extern xkb_keycode_t (*xkb_keymap_min_keycode_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern xkb_keycode_t (*xkb_keymap_max_keycode_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern void (*xkb_keymap_key_for_each_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keymap_key_iter_t, void*);
+extern const char* (*xkb_keymap_key_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t);
+extern xkb_keycode_t (*xkb_keymap_key_by_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+extern xkb_mod_index_t (*xkb_keymap_num_mods_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern const char* (*xkb_keymap_mod_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_mod_index_t);
+extern xkb_mod_index_t (*xkb_keymap_mod_get_index_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+extern xkb_layout_index_t (*xkb_keymap_num_layouts_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern const char* (*xkb_keymap_layout_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_layout_index_t);
+extern xkb_layout_index_t (*xkb_keymap_layout_get_index_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+extern xkb_led_index_t (*xkb_keymap_num_leds_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern const char* (*xkb_keymap_led_get_name_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_led_index_t);
+extern xkb_led_index_t (*xkb_keymap_led_get_index_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*,const char*);
+extern xkb_layout_index_t (*xkb_keymap_num_layouts_for_key_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t);
+extern xkb_level_index_t (*xkb_keymap_num_levels_for_key_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t, xkb_layout_index_t);
+extern size_t (*xkb_keymap_key_get_mods_for_level_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t, xkb_layout_index_t, xkb_level_index_t, xkb_mod_mask_t*, size_t);
+extern int (*xkb_keymap_key_get_syms_by_level_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t, xkb_layout_index_t, xkb_level_index_t,const xkb_keysym_t**);
+extern int (*xkb_keymap_key_repeats_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*, xkb_keycode_t);
+extern struct xkb_state* (*xkb_state_new_dylibloader_wrapper_xkbcommon)(struct xkb_keymap*);
+extern struct xkb_state* (*xkb_state_ref_dylibloader_wrapper_xkbcommon)(struct xkb_state*);
+extern void (*xkb_state_unref_dylibloader_wrapper_xkbcommon)(struct xkb_state*);
+extern struct xkb_keymap* (*xkb_state_get_keymap_dylibloader_wrapper_xkbcommon)(struct xkb_state*);
+extern enum xkb_state_component (*xkb_state_update_key_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t,enum xkb_key_direction);
+extern enum xkb_state_component (*xkb_state_update_mask_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_mod_mask_t, xkb_mod_mask_t, xkb_mod_mask_t, xkb_layout_index_t, xkb_layout_index_t, xkb_layout_index_t);
+extern int (*xkb_state_key_get_syms_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t,const xkb_keysym_t**);
+extern int (*xkb_state_key_get_utf8_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, char*, size_t);
+extern uint32_t (*xkb_state_key_get_utf32_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+extern xkb_keysym_t (*xkb_state_key_get_one_sym_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+extern xkb_layout_index_t (*xkb_state_key_get_layout_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+extern xkb_level_index_t (*xkb_state_key_get_level_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_layout_index_t);
+extern xkb_mod_mask_t (*xkb_state_serialize_mods_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component);
+extern xkb_layout_index_t (*xkb_state_serialize_layout_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component);
+extern int (*xkb_state_mod_name_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,const char*,enum xkb_state_component);
+extern int (*xkb_state_mod_names_are_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component,enum xkb_state_match,...);
+extern int (*xkb_state_mod_index_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_mod_index_t,enum xkb_state_component);
+extern int (*xkb_state_mod_indices_are_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,enum xkb_state_component,enum xkb_state_match,...);
+extern xkb_mod_mask_t (*xkb_state_key_get_consumed_mods2_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t,enum xkb_consumed_mode);
+extern xkb_mod_mask_t (*xkb_state_key_get_consumed_mods_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t);
+extern int (*xkb_state_mod_index_is_consumed2_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_mod_index_t,enum xkb_consumed_mode);
+extern int (*xkb_state_mod_index_is_consumed_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_mod_index_t);
+extern xkb_mod_mask_t (*xkb_state_mod_mask_remove_consumed_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_keycode_t, xkb_mod_mask_t);
+extern int (*xkb_state_layout_name_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,const char*,enum xkb_state_component);
+extern int (*xkb_state_layout_index_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_layout_index_t,enum xkb_state_component);
+extern int (*xkb_state_led_name_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*,const char*);
+extern int (*xkb_state_led_index_is_active_dylibloader_wrapper_xkbcommon)(struct xkb_state*, xkb_led_index_t);
+int initialize_xkbcommon(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.c
new file mode 100644
index 0000000000..a746b6c526
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.c
@@ -0,0 +1,6664 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:13:26
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/Xlib.h --include ./thirdparty/linuxbsd_headers/X11/Xutil.h --include ./thirdparty/linuxbsd_headers/X11/XKBlib.h --sys-include "thirdparty/linuxbsd_headers/X11/Xlib.h" --sys-include "thirdparty/linuxbsd_headers/X11/Xutil.h" --sys-include "thirdparty/linuxbsd_headers/X11/XKBlib.h" --soname libX11.so.6 --init-name xlib --omit-prefix XkbGetDeviceIndicatorState --omit-prefix XkbAddSymInterpret --output-header ./platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.c~
+//
+// NOTE: Generated from Xlib 1.6.9.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, the type of the third argument of
+// XIfEvent, XPeekIfEvent and XCheckIfEvent had to be fixed as it wasn't parsed
+// fully (it's a Bool function pointer, but it was just being parsed as an int
+// pointer).
+#include <stdint.h>
+
+#define _Xmblen _Xmblen_dylibloader_orig_xlib
+#define XLoadQueryFont XLoadQueryFont_dylibloader_orig_xlib
+#define XQueryFont XQueryFont_dylibloader_orig_xlib
+#define XGetMotionEvents XGetMotionEvents_dylibloader_orig_xlib
+#define XDeleteModifiermapEntry XDeleteModifiermapEntry_dylibloader_orig_xlib
+#define XGetModifierMapping XGetModifierMapping_dylibloader_orig_xlib
+#define XInsertModifiermapEntry XInsertModifiermapEntry_dylibloader_orig_xlib
+#define XNewModifiermap XNewModifiermap_dylibloader_orig_xlib
+#define XCreateImage XCreateImage_dylibloader_orig_xlib
+#define XInitImage XInitImage_dylibloader_orig_xlib
+#define XGetImage XGetImage_dylibloader_orig_xlib
+#define XGetSubImage XGetSubImage_dylibloader_orig_xlib
+#define XOpenDisplay XOpenDisplay_dylibloader_orig_xlib
+#define XrmInitialize XrmInitialize_dylibloader_orig_xlib
+#define XFetchBytes XFetchBytes_dylibloader_orig_xlib
+#define XFetchBuffer XFetchBuffer_dylibloader_orig_xlib
+#define XGetAtomName XGetAtomName_dylibloader_orig_xlib
+#define XGetAtomNames XGetAtomNames_dylibloader_orig_xlib
+#define XGetDefault XGetDefault_dylibloader_orig_xlib
+#define XDisplayName XDisplayName_dylibloader_orig_xlib
+#define XKeysymToString XKeysymToString_dylibloader_orig_xlib
+#define XSynchronize XSynchronize_dylibloader_orig_xlib
+#define XSetAfterFunction XSetAfterFunction_dylibloader_orig_xlib
+#define XInternAtom XInternAtom_dylibloader_orig_xlib
+#define XInternAtoms XInternAtoms_dylibloader_orig_xlib
+#define XCopyColormapAndFree XCopyColormapAndFree_dylibloader_orig_xlib
+#define XCreateColormap XCreateColormap_dylibloader_orig_xlib
+#define XCreatePixmapCursor XCreatePixmapCursor_dylibloader_orig_xlib
+#define XCreateGlyphCursor XCreateGlyphCursor_dylibloader_orig_xlib
+#define XCreateFontCursor XCreateFontCursor_dylibloader_orig_xlib
+#define XLoadFont XLoadFont_dylibloader_orig_xlib
+#define XCreateGC XCreateGC_dylibloader_orig_xlib
+#define XGContextFromGC XGContextFromGC_dylibloader_orig_xlib
+#define XFlushGC XFlushGC_dylibloader_orig_xlib
+#define XCreatePixmap XCreatePixmap_dylibloader_orig_xlib
+#define XCreateBitmapFromData XCreateBitmapFromData_dylibloader_orig_xlib
+#define XCreatePixmapFromBitmapData XCreatePixmapFromBitmapData_dylibloader_orig_xlib
+#define XCreateSimpleWindow XCreateSimpleWindow_dylibloader_orig_xlib
+#define XGetSelectionOwner XGetSelectionOwner_dylibloader_orig_xlib
+#define XCreateWindow XCreateWindow_dylibloader_orig_xlib
+#define XListInstalledColormaps XListInstalledColormaps_dylibloader_orig_xlib
+#define XListFonts XListFonts_dylibloader_orig_xlib
+#define XListFontsWithInfo XListFontsWithInfo_dylibloader_orig_xlib
+#define XGetFontPath XGetFontPath_dylibloader_orig_xlib
+#define XListExtensions XListExtensions_dylibloader_orig_xlib
+#define XListProperties XListProperties_dylibloader_orig_xlib
+#define XListHosts XListHosts_dylibloader_orig_xlib
+#define XKeycodeToKeysym XKeycodeToKeysym_dylibloader_orig_xlib
+#define XLookupKeysym XLookupKeysym_dylibloader_orig_xlib
+#define XGetKeyboardMapping XGetKeyboardMapping_dylibloader_orig_xlib
+#define XStringToKeysym XStringToKeysym_dylibloader_orig_xlib
+#define XMaxRequestSize XMaxRequestSize_dylibloader_orig_xlib
+#define XExtendedMaxRequestSize XExtendedMaxRequestSize_dylibloader_orig_xlib
+#define XResourceManagerString XResourceManagerString_dylibloader_orig_xlib
+#define XScreenResourceString XScreenResourceString_dylibloader_orig_xlib
+#define XDisplayMotionBufferSize XDisplayMotionBufferSize_dylibloader_orig_xlib
+#define XVisualIDFromVisual XVisualIDFromVisual_dylibloader_orig_xlib
+#define XInitThreads XInitThreads_dylibloader_orig_xlib
+#define XLockDisplay XLockDisplay_dylibloader_orig_xlib
+#define XUnlockDisplay XUnlockDisplay_dylibloader_orig_xlib
+#define XInitExtension XInitExtension_dylibloader_orig_xlib
+#define XAddExtension XAddExtension_dylibloader_orig_xlib
+#define XFindOnExtensionList XFindOnExtensionList_dylibloader_orig_xlib
+#define XEHeadOfExtensionList XEHeadOfExtensionList_dylibloader_orig_xlib
+#define XRootWindow XRootWindow_dylibloader_orig_xlib
+#define XDefaultRootWindow XDefaultRootWindow_dylibloader_orig_xlib
+#define XRootWindowOfScreen XRootWindowOfScreen_dylibloader_orig_xlib
+#define XDefaultVisual XDefaultVisual_dylibloader_orig_xlib
+#define XDefaultVisualOfScreen XDefaultVisualOfScreen_dylibloader_orig_xlib
+#define XDefaultGC XDefaultGC_dylibloader_orig_xlib
+#define XDefaultGCOfScreen XDefaultGCOfScreen_dylibloader_orig_xlib
+#define XBlackPixel XBlackPixel_dylibloader_orig_xlib
+#define XWhitePixel XWhitePixel_dylibloader_orig_xlib
+#define XAllPlanes XAllPlanes_dylibloader_orig_xlib
+#define XBlackPixelOfScreen XBlackPixelOfScreen_dylibloader_orig_xlib
+#define XWhitePixelOfScreen XWhitePixelOfScreen_dylibloader_orig_xlib
+#define XNextRequest XNextRequest_dylibloader_orig_xlib
+#define XLastKnownRequestProcessed XLastKnownRequestProcessed_dylibloader_orig_xlib
+#define XServerVendor XServerVendor_dylibloader_orig_xlib
+#define XDisplayString XDisplayString_dylibloader_orig_xlib
+#define XDefaultColormap XDefaultColormap_dylibloader_orig_xlib
+#define XDefaultColormapOfScreen XDefaultColormapOfScreen_dylibloader_orig_xlib
+#define XDisplayOfScreen XDisplayOfScreen_dylibloader_orig_xlib
+#define XScreenOfDisplay XScreenOfDisplay_dylibloader_orig_xlib
+#define XDefaultScreenOfDisplay XDefaultScreenOfDisplay_dylibloader_orig_xlib
+#define XEventMaskOfScreen XEventMaskOfScreen_dylibloader_orig_xlib
+#define XScreenNumberOfScreen XScreenNumberOfScreen_dylibloader_orig_xlib
+#define XSetErrorHandler XSetErrorHandler_dylibloader_orig_xlib
+#define XSetIOErrorHandler XSetIOErrorHandler_dylibloader_orig_xlib
+#define XListPixmapFormats XListPixmapFormats_dylibloader_orig_xlib
+#define XListDepths XListDepths_dylibloader_orig_xlib
+#define XReconfigureWMWindow XReconfigureWMWindow_dylibloader_orig_xlib
+#define XGetWMProtocols XGetWMProtocols_dylibloader_orig_xlib
+#define XSetWMProtocols XSetWMProtocols_dylibloader_orig_xlib
+#define XIconifyWindow XIconifyWindow_dylibloader_orig_xlib
+#define XWithdrawWindow XWithdrawWindow_dylibloader_orig_xlib
+#define XGetCommand XGetCommand_dylibloader_orig_xlib
+#define XGetWMColormapWindows XGetWMColormapWindows_dylibloader_orig_xlib
+#define XSetWMColormapWindows XSetWMColormapWindows_dylibloader_orig_xlib
+#define XFreeStringList XFreeStringList_dylibloader_orig_xlib
+#define XSetTransientForHint XSetTransientForHint_dylibloader_orig_xlib
+#define XActivateScreenSaver XActivateScreenSaver_dylibloader_orig_xlib
+#define XAddHost XAddHost_dylibloader_orig_xlib
+#define XAddHosts XAddHosts_dylibloader_orig_xlib
+#define XAddToExtensionList XAddToExtensionList_dylibloader_orig_xlib
+#define XAddToSaveSet XAddToSaveSet_dylibloader_orig_xlib
+#define XAllocColor XAllocColor_dylibloader_orig_xlib
+#define XAllocColorCells XAllocColorCells_dylibloader_orig_xlib
+#define XAllocColorPlanes XAllocColorPlanes_dylibloader_orig_xlib
+#define XAllocNamedColor XAllocNamedColor_dylibloader_orig_xlib
+#define XAllowEvents XAllowEvents_dylibloader_orig_xlib
+#define XAutoRepeatOff XAutoRepeatOff_dylibloader_orig_xlib
+#define XAutoRepeatOn XAutoRepeatOn_dylibloader_orig_xlib
+#define XBell XBell_dylibloader_orig_xlib
+#define XBitmapBitOrder XBitmapBitOrder_dylibloader_orig_xlib
+#define XBitmapPad XBitmapPad_dylibloader_orig_xlib
+#define XBitmapUnit XBitmapUnit_dylibloader_orig_xlib
+#define XCellsOfScreen XCellsOfScreen_dylibloader_orig_xlib
+#define XChangeActivePointerGrab XChangeActivePointerGrab_dylibloader_orig_xlib
+#define XChangeGC XChangeGC_dylibloader_orig_xlib
+#define XChangeKeyboardControl XChangeKeyboardControl_dylibloader_orig_xlib
+#define XChangeKeyboardMapping XChangeKeyboardMapping_dylibloader_orig_xlib
+#define XChangePointerControl XChangePointerControl_dylibloader_orig_xlib
+#define XChangeProperty XChangeProperty_dylibloader_orig_xlib
+#define XChangeSaveSet XChangeSaveSet_dylibloader_orig_xlib
+#define XChangeWindowAttributes XChangeWindowAttributes_dylibloader_orig_xlib
+#define XCheckIfEvent XCheckIfEvent_dylibloader_orig_xlib
+#define XCheckMaskEvent XCheckMaskEvent_dylibloader_orig_xlib
+#define XCheckTypedEvent XCheckTypedEvent_dylibloader_orig_xlib
+#define XCheckTypedWindowEvent XCheckTypedWindowEvent_dylibloader_orig_xlib
+#define XCheckWindowEvent XCheckWindowEvent_dylibloader_orig_xlib
+#define XCirculateSubwindows XCirculateSubwindows_dylibloader_orig_xlib
+#define XCirculateSubwindowsDown XCirculateSubwindowsDown_dylibloader_orig_xlib
+#define XCirculateSubwindowsUp XCirculateSubwindowsUp_dylibloader_orig_xlib
+#define XClearArea XClearArea_dylibloader_orig_xlib
+#define XClearWindow XClearWindow_dylibloader_orig_xlib
+#define XCloseDisplay XCloseDisplay_dylibloader_orig_xlib
+#define XConfigureWindow XConfigureWindow_dylibloader_orig_xlib
+#define XConnectionNumber XConnectionNumber_dylibloader_orig_xlib
+#define XConvertSelection XConvertSelection_dylibloader_orig_xlib
+#define XCopyArea XCopyArea_dylibloader_orig_xlib
+#define XCopyGC XCopyGC_dylibloader_orig_xlib
+#define XCopyPlane XCopyPlane_dylibloader_orig_xlib
+#define XDefaultDepth XDefaultDepth_dylibloader_orig_xlib
+#define XDefaultDepthOfScreen XDefaultDepthOfScreen_dylibloader_orig_xlib
+#define XDefaultScreen XDefaultScreen_dylibloader_orig_xlib
+#define XDefineCursor XDefineCursor_dylibloader_orig_xlib
+#define XDeleteProperty XDeleteProperty_dylibloader_orig_xlib
+#define XDestroyWindow XDestroyWindow_dylibloader_orig_xlib
+#define XDestroySubwindows XDestroySubwindows_dylibloader_orig_xlib
+#define XDoesBackingStore XDoesBackingStore_dylibloader_orig_xlib
+#define XDoesSaveUnders XDoesSaveUnders_dylibloader_orig_xlib
+#define XDisableAccessControl XDisableAccessControl_dylibloader_orig_xlib
+#define XDisplayCells XDisplayCells_dylibloader_orig_xlib
+#define XDisplayHeight XDisplayHeight_dylibloader_orig_xlib
+#define XDisplayHeightMM XDisplayHeightMM_dylibloader_orig_xlib
+#define XDisplayKeycodes XDisplayKeycodes_dylibloader_orig_xlib
+#define XDisplayPlanes XDisplayPlanes_dylibloader_orig_xlib
+#define XDisplayWidth XDisplayWidth_dylibloader_orig_xlib
+#define XDisplayWidthMM XDisplayWidthMM_dylibloader_orig_xlib
+#define XDrawArc XDrawArc_dylibloader_orig_xlib
+#define XDrawArcs XDrawArcs_dylibloader_orig_xlib
+#define XDrawImageString XDrawImageString_dylibloader_orig_xlib
+#define XDrawImageString16 XDrawImageString16_dylibloader_orig_xlib
+#define XDrawLine XDrawLine_dylibloader_orig_xlib
+#define XDrawLines XDrawLines_dylibloader_orig_xlib
+#define XDrawPoint XDrawPoint_dylibloader_orig_xlib
+#define XDrawPoints XDrawPoints_dylibloader_orig_xlib
+#define XDrawRectangle XDrawRectangle_dylibloader_orig_xlib
+#define XDrawRectangles XDrawRectangles_dylibloader_orig_xlib
+#define XDrawSegments XDrawSegments_dylibloader_orig_xlib
+#define XDrawString XDrawString_dylibloader_orig_xlib
+#define XDrawString16 XDrawString16_dylibloader_orig_xlib
+#define XDrawText XDrawText_dylibloader_orig_xlib
+#define XDrawText16 XDrawText16_dylibloader_orig_xlib
+#define XEnableAccessControl XEnableAccessControl_dylibloader_orig_xlib
+#define XEventsQueued XEventsQueued_dylibloader_orig_xlib
+#define XFetchName XFetchName_dylibloader_orig_xlib
+#define XFillArc XFillArc_dylibloader_orig_xlib
+#define XFillArcs XFillArcs_dylibloader_orig_xlib
+#define XFillPolygon XFillPolygon_dylibloader_orig_xlib
+#define XFillRectangle XFillRectangle_dylibloader_orig_xlib
+#define XFillRectangles XFillRectangles_dylibloader_orig_xlib
+#define XFlush XFlush_dylibloader_orig_xlib
+#define XForceScreenSaver XForceScreenSaver_dylibloader_orig_xlib
+#define XFree XFree_dylibloader_orig_xlib
+#define XFreeColormap XFreeColormap_dylibloader_orig_xlib
+#define XFreeColors XFreeColors_dylibloader_orig_xlib
+#define XFreeCursor XFreeCursor_dylibloader_orig_xlib
+#define XFreeExtensionList XFreeExtensionList_dylibloader_orig_xlib
+#define XFreeFont XFreeFont_dylibloader_orig_xlib
+#define XFreeFontInfo XFreeFontInfo_dylibloader_orig_xlib
+#define XFreeFontNames XFreeFontNames_dylibloader_orig_xlib
+#define XFreeFontPath XFreeFontPath_dylibloader_orig_xlib
+#define XFreeGC XFreeGC_dylibloader_orig_xlib
+#define XFreeModifiermap XFreeModifiermap_dylibloader_orig_xlib
+#define XFreePixmap XFreePixmap_dylibloader_orig_xlib
+#define XGeometry XGeometry_dylibloader_orig_xlib
+#define XGetErrorDatabaseText XGetErrorDatabaseText_dylibloader_orig_xlib
+#define XGetErrorText XGetErrorText_dylibloader_orig_xlib
+#define XGetFontProperty XGetFontProperty_dylibloader_orig_xlib
+#define XGetGCValues XGetGCValues_dylibloader_orig_xlib
+#define XGetGeometry XGetGeometry_dylibloader_orig_xlib
+#define XGetIconName XGetIconName_dylibloader_orig_xlib
+#define XGetInputFocus XGetInputFocus_dylibloader_orig_xlib
+#define XGetKeyboardControl XGetKeyboardControl_dylibloader_orig_xlib
+#define XGetPointerControl XGetPointerControl_dylibloader_orig_xlib
+#define XGetPointerMapping XGetPointerMapping_dylibloader_orig_xlib
+#define XGetScreenSaver XGetScreenSaver_dylibloader_orig_xlib
+#define XGetTransientForHint XGetTransientForHint_dylibloader_orig_xlib
+#define XGetWindowProperty XGetWindowProperty_dylibloader_orig_xlib
+#define XGetWindowAttributes XGetWindowAttributes_dylibloader_orig_xlib
+#define XGrabButton XGrabButton_dylibloader_orig_xlib
+#define XGrabKey XGrabKey_dylibloader_orig_xlib
+#define XGrabKeyboard XGrabKeyboard_dylibloader_orig_xlib
+#define XGrabPointer XGrabPointer_dylibloader_orig_xlib
+#define XGrabServer XGrabServer_dylibloader_orig_xlib
+#define XHeightMMOfScreen XHeightMMOfScreen_dylibloader_orig_xlib
+#define XHeightOfScreen XHeightOfScreen_dylibloader_orig_xlib
+#define XIfEvent XIfEvent_dylibloader_orig_xlib
+#define XImageByteOrder XImageByteOrder_dylibloader_orig_xlib
+#define XInstallColormap XInstallColormap_dylibloader_orig_xlib
+#define XKeysymToKeycode XKeysymToKeycode_dylibloader_orig_xlib
+#define XKillClient XKillClient_dylibloader_orig_xlib
+#define XLookupColor XLookupColor_dylibloader_orig_xlib
+#define XLowerWindow XLowerWindow_dylibloader_orig_xlib
+#define XMapRaised XMapRaised_dylibloader_orig_xlib
+#define XMapSubwindows XMapSubwindows_dylibloader_orig_xlib
+#define XMapWindow XMapWindow_dylibloader_orig_xlib
+#define XMaskEvent XMaskEvent_dylibloader_orig_xlib
+#define XMaxCmapsOfScreen XMaxCmapsOfScreen_dylibloader_orig_xlib
+#define XMinCmapsOfScreen XMinCmapsOfScreen_dylibloader_orig_xlib
+#define XMoveResizeWindow XMoveResizeWindow_dylibloader_orig_xlib
+#define XMoveWindow XMoveWindow_dylibloader_orig_xlib
+#define XNextEvent XNextEvent_dylibloader_orig_xlib
+#define XNoOp XNoOp_dylibloader_orig_xlib
+#define XParseColor XParseColor_dylibloader_orig_xlib
+#define XParseGeometry XParseGeometry_dylibloader_orig_xlib
+#define XPeekEvent XPeekEvent_dylibloader_orig_xlib
+#define XPeekIfEvent XPeekIfEvent_dylibloader_orig_xlib
+#define XPending XPending_dylibloader_orig_xlib
+#define XPlanesOfScreen XPlanesOfScreen_dylibloader_orig_xlib
+#define XProtocolRevision XProtocolRevision_dylibloader_orig_xlib
+#define XProtocolVersion XProtocolVersion_dylibloader_orig_xlib
+#define XPutBackEvent XPutBackEvent_dylibloader_orig_xlib
+#define XPutImage XPutImage_dylibloader_orig_xlib
+#define XQLength XQLength_dylibloader_orig_xlib
+#define XQueryBestCursor XQueryBestCursor_dylibloader_orig_xlib
+#define XQueryBestSize XQueryBestSize_dylibloader_orig_xlib
+#define XQueryBestStipple XQueryBestStipple_dylibloader_orig_xlib
+#define XQueryBestTile XQueryBestTile_dylibloader_orig_xlib
+#define XQueryColor XQueryColor_dylibloader_orig_xlib
+#define XQueryColors XQueryColors_dylibloader_orig_xlib
+#define XQueryExtension XQueryExtension_dylibloader_orig_xlib
+#define XQueryKeymap XQueryKeymap_dylibloader_orig_xlib
+#define XQueryPointer XQueryPointer_dylibloader_orig_xlib
+#define XQueryTextExtents XQueryTextExtents_dylibloader_orig_xlib
+#define XQueryTextExtents16 XQueryTextExtents16_dylibloader_orig_xlib
+#define XQueryTree XQueryTree_dylibloader_orig_xlib
+#define XRaiseWindow XRaiseWindow_dylibloader_orig_xlib
+#define XReadBitmapFile XReadBitmapFile_dylibloader_orig_xlib
+#define XReadBitmapFileData XReadBitmapFileData_dylibloader_orig_xlib
+#define XRebindKeysym XRebindKeysym_dylibloader_orig_xlib
+#define XRecolorCursor XRecolorCursor_dylibloader_orig_xlib
+#define XRefreshKeyboardMapping XRefreshKeyboardMapping_dylibloader_orig_xlib
+#define XRemoveFromSaveSet XRemoveFromSaveSet_dylibloader_orig_xlib
+#define XRemoveHost XRemoveHost_dylibloader_orig_xlib
+#define XRemoveHosts XRemoveHosts_dylibloader_orig_xlib
+#define XReparentWindow XReparentWindow_dylibloader_orig_xlib
+#define XResetScreenSaver XResetScreenSaver_dylibloader_orig_xlib
+#define XResizeWindow XResizeWindow_dylibloader_orig_xlib
+#define XRestackWindows XRestackWindows_dylibloader_orig_xlib
+#define XRotateBuffers XRotateBuffers_dylibloader_orig_xlib
+#define XRotateWindowProperties XRotateWindowProperties_dylibloader_orig_xlib
+#define XScreenCount XScreenCount_dylibloader_orig_xlib
+#define XSelectInput XSelectInput_dylibloader_orig_xlib
+#define XSendEvent XSendEvent_dylibloader_orig_xlib
+#define XSetAccessControl XSetAccessControl_dylibloader_orig_xlib
+#define XSetArcMode XSetArcMode_dylibloader_orig_xlib
+#define XSetBackground XSetBackground_dylibloader_orig_xlib
+#define XSetClipMask XSetClipMask_dylibloader_orig_xlib
+#define XSetClipOrigin XSetClipOrigin_dylibloader_orig_xlib
+#define XSetClipRectangles XSetClipRectangles_dylibloader_orig_xlib
+#define XSetCloseDownMode XSetCloseDownMode_dylibloader_orig_xlib
+#define XSetCommand XSetCommand_dylibloader_orig_xlib
+#define XSetDashes XSetDashes_dylibloader_orig_xlib
+#define XSetFillRule XSetFillRule_dylibloader_orig_xlib
+#define XSetFillStyle XSetFillStyle_dylibloader_orig_xlib
+#define XSetFont XSetFont_dylibloader_orig_xlib
+#define XSetFontPath XSetFontPath_dylibloader_orig_xlib
+#define XSetForeground XSetForeground_dylibloader_orig_xlib
+#define XSetFunction XSetFunction_dylibloader_orig_xlib
+#define XSetGraphicsExposures XSetGraphicsExposures_dylibloader_orig_xlib
+#define XSetIconName XSetIconName_dylibloader_orig_xlib
+#define XSetInputFocus XSetInputFocus_dylibloader_orig_xlib
+#define XSetLineAttributes XSetLineAttributes_dylibloader_orig_xlib
+#define XSetModifierMapping XSetModifierMapping_dylibloader_orig_xlib
+#define XSetPlaneMask XSetPlaneMask_dylibloader_orig_xlib
+#define XSetPointerMapping XSetPointerMapping_dylibloader_orig_xlib
+#define XSetScreenSaver XSetScreenSaver_dylibloader_orig_xlib
+#define XSetSelectionOwner XSetSelectionOwner_dylibloader_orig_xlib
+#define XSetState XSetState_dylibloader_orig_xlib
+#define XSetStipple XSetStipple_dylibloader_orig_xlib
+#define XSetSubwindowMode XSetSubwindowMode_dylibloader_orig_xlib
+#define XSetTSOrigin XSetTSOrigin_dylibloader_orig_xlib
+#define XSetTile XSetTile_dylibloader_orig_xlib
+#define XSetWindowBackground XSetWindowBackground_dylibloader_orig_xlib
+#define XSetWindowBackgroundPixmap XSetWindowBackgroundPixmap_dylibloader_orig_xlib
+#define XSetWindowBorder XSetWindowBorder_dylibloader_orig_xlib
+#define XSetWindowBorderPixmap XSetWindowBorderPixmap_dylibloader_orig_xlib
+#define XSetWindowBorderWidth XSetWindowBorderWidth_dylibloader_orig_xlib
+#define XSetWindowColormap XSetWindowColormap_dylibloader_orig_xlib
+#define XStoreBuffer XStoreBuffer_dylibloader_orig_xlib
+#define XStoreBytes XStoreBytes_dylibloader_orig_xlib
+#define XStoreColor XStoreColor_dylibloader_orig_xlib
+#define XStoreColors XStoreColors_dylibloader_orig_xlib
+#define XStoreName XStoreName_dylibloader_orig_xlib
+#define XStoreNamedColor XStoreNamedColor_dylibloader_orig_xlib
+#define XSync XSync_dylibloader_orig_xlib
+#define XTextExtents XTextExtents_dylibloader_orig_xlib
+#define XTextExtents16 XTextExtents16_dylibloader_orig_xlib
+#define XTextWidth XTextWidth_dylibloader_orig_xlib
+#define XTextWidth16 XTextWidth16_dylibloader_orig_xlib
+#define XTranslateCoordinates XTranslateCoordinates_dylibloader_orig_xlib
+#define XUndefineCursor XUndefineCursor_dylibloader_orig_xlib
+#define XUngrabButton XUngrabButton_dylibloader_orig_xlib
+#define XUngrabKey XUngrabKey_dylibloader_orig_xlib
+#define XUngrabKeyboard XUngrabKeyboard_dylibloader_orig_xlib
+#define XUngrabPointer XUngrabPointer_dylibloader_orig_xlib
+#define XUngrabServer XUngrabServer_dylibloader_orig_xlib
+#define XUninstallColormap XUninstallColormap_dylibloader_orig_xlib
+#define XUnloadFont XUnloadFont_dylibloader_orig_xlib
+#define XUnmapSubwindows XUnmapSubwindows_dylibloader_orig_xlib
+#define XUnmapWindow XUnmapWindow_dylibloader_orig_xlib
+#define XVendorRelease XVendorRelease_dylibloader_orig_xlib
+#define XWarpPointer XWarpPointer_dylibloader_orig_xlib
+#define XWidthMMOfScreen XWidthMMOfScreen_dylibloader_orig_xlib
+#define XWidthOfScreen XWidthOfScreen_dylibloader_orig_xlib
+#define XWindowEvent XWindowEvent_dylibloader_orig_xlib
+#define XWriteBitmapFile XWriteBitmapFile_dylibloader_orig_xlib
+#define XSupportsLocale XSupportsLocale_dylibloader_orig_xlib
+#define XSetLocaleModifiers XSetLocaleModifiers_dylibloader_orig_xlib
+#define XOpenOM XOpenOM_dylibloader_orig_xlib
+#define XCloseOM XCloseOM_dylibloader_orig_xlib
+#define XSetOMValues XSetOMValues_dylibloader_orig_xlib
+#define XGetOMValues XGetOMValues_dylibloader_orig_xlib
+#define XDisplayOfOM XDisplayOfOM_dylibloader_orig_xlib
+#define XLocaleOfOM XLocaleOfOM_dylibloader_orig_xlib
+#define XCreateOC XCreateOC_dylibloader_orig_xlib
+#define XDestroyOC XDestroyOC_dylibloader_orig_xlib
+#define XOMOfOC XOMOfOC_dylibloader_orig_xlib
+#define XSetOCValues XSetOCValues_dylibloader_orig_xlib
+#define XGetOCValues XGetOCValues_dylibloader_orig_xlib
+#define XCreateFontSet XCreateFontSet_dylibloader_orig_xlib
+#define XFreeFontSet XFreeFontSet_dylibloader_orig_xlib
+#define XFontsOfFontSet XFontsOfFontSet_dylibloader_orig_xlib
+#define XBaseFontNameListOfFontSet XBaseFontNameListOfFontSet_dylibloader_orig_xlib
+#define XLocaleOfFontSet XLocaleOfFontSet_dylibloader_orig_xlib
+#define XContextDependentDrawing XContextDependentDrawing_dylibloader_orig_xlib
+#define XDirectionalDependentDrawing XDirectionalDependentDrawing_dylibloader_orig_xlib
+#define XContextualDrawing XContextualDrawing_dylibloader_orig_xlib
+#define XExtentsOfFontSet XExtentsOfFontSet_dylibloader_orig_xlib
+#define XmbTextEscapement XmbTextEscapement_dylibloader_orig_xlib
+#define XwcTextEscapement XwcTextEscapement_dylibloader_orig_xlib
+#define Xutf8TextEscapement Xutf8TextEscapement_dylibloader_orig_xlib
+#define XmbTextExtents XmbTextExtents_dylibloader_orig_xlib
+#define XwcTextExtents XwcTextExtents_dylibloader_orig_xlib
+#define Xutf8TextExtents Xutf8TextExtents_dylibloader_orig_xlib
+#define XmbTextPerCharExtents XmbTextPerCharExtents_dylibloader_orig_xlib
+#define XwcTextPerCharExtents XwcTextPerCharExtents_dylibloader_orig_xlib
+#define Xutf8TextPerCharExtents Xutf8TextPerCharExtents_dylibloader_orig_xlib
+#define XmbDrawText XmbDrawText_dylibloader_orig_xlib
+#define XwcDrawText XwcDrawText_dylibloader_orig_xlib
+#define Xutf8DrawText Xutf8DrawText_dylibloader_orig_xlib
+#define XmbDrawString XmbDrawString_dylibloader_orig_xlib
+#define XwcDrawString XwcDrawString_dylibloader_orig_xlib
+#define Xutf8DrawString Xutf8DrawString_dylibloader_orig_xlib
+#define XmbDrawImageString XmbDrawImageString_dylibloader_orig_xlib
+#define XwcDrawImageString XwcDrawImageString_dylibloader_orig_xlib
+#define Xutf8DrawImageString Xutf8DrawImageString_dylibloader_orig_xlib
+#define XOpenIM XOpenIM_dylibloader_orig_xlib
+#define XCloseIM XCloseIM_dylibloader_orig_xlib
+#define XGetIMValues XGetIMValues_dylibloader_orig_xlib
+#define XSetIMValues XSetIMValues_dylibloader_orig_xlib
+#define XDisplayOfIM XDisplayOfIM_dylibloader_orig_xlib
+#define XLocaleOfIM XLocaleOfIM_dylibloader_orig_xlib
+#define XCreateIC XCreateIC_dylibloader_orig_xlib
+#define XDestroyIC XDestroyIC_dylibloader_orig_xlib
+#define XSetICFocus XSetICFocus_dylibloader_orig_xlib
+#define XUnsetICFocus XUnsetICFocus_dylibloader_orig_xlib
+#define XwcResetIC XwcResetIC_dylibloader_orig_xlib
+#define XmbResetIC XmbResetIC_dylibloader_orig_xlib
+#define Xutf8ResetIC Xutf8ResetIC_dylibloader_orig_xlib
+#define XSetICValues XSetICValues_dylibloader_orig_xlib
+#define XGetICValues XGetICValues_dylibloader_orig_xlib
+#define XIMOfIC XIMOfIC_dylibloader_orig_xlib
+#define XFilterEvent XFilterEvent_dylibloader_orig_xlib
+#define XmbLookupString XmbLookupString_dylibloader_orig_xlib
+#define XwcLookupString XwcLookupString_dylibloader_orig_xlib
+#define Xutf8LookupString Xutf8LookupString_dylibloader_orig_xlib
+#define XVaCreateNestedList XVaCreateNestedList_dylibloader_orig_xlib
+#define XRegisterIMInstantiateCallback XRegisterIMInstantiateCallback_dylibloader_orig_xlib
+#define XUnregisterIMInstantiateCallback XUnregisterIMInstantiateCallback_dylibloader_orig_xlib
+#define XInternalConnectionNumbers XInternalConnectionNumbers_dylibloader_orig_xlib
+#define XProcessInternalConnection XProcessInternalConnection_dylibloader_orig_xlib
+#define XAddConnectionWatch XAddConnectionWatch_dylibloader_orig_xlib
+#define XRemoveConnectionWatch XRemoveConnectionWatch_dylibloader_orig_xlib
+#define XSetAuthorization XSetAuthorization_dylibloader_orig_xlib
+#define _Xmbtowc _Xmbtowc_dylibloader_orig_xlib
+#define _Xwctomb _Xwctomb_dylibloader_orig_xlib
+#define XGetEventData XGetEventData_dylibloader_orig_xlib
+#define XFreeEventData XFreeEventData_dylibloader_orig_xlib
+#define XAllocClassHint XAllocClassHint_dylibloader_orig_xlib
+#define XAllocIconSize XAllocIconSize_dylibloader_orig_xlib
+#define XAllocSizeHints XAllocSizeHints_dylibloader_orig_xlib
+#define XAllocStandardColormap XAllocStandardColormap_dylibloader_orig_xlib
+#define XAllocWMHints XAllocWMHints_dylibloader_orig_xlib
+#define XClipBox XClipBox_dylibloader_orig_xlib
+#define XCreateRegion XCreateRegion_dylibloader_orig_xlib
+#define XDefaultString XDefaultString_dylibloader_orig_xlib
+#define XDeleteContext XDeleteContext_dylibloader_orig_xlib
+#define XDestroyRegion XDestroyRegion_dylibloader_orig_xlib
+#define XEmptyRegion XEmptyRegion_dylibloader_orig_xlib
+#define XEqualRegion XEqualRegion_dylibloader_orig_xlib
+#define XFindContext XFindContext_dylibloader_orig_xlib
+#define XGetClassHint XGetClassHint_dylibloader_orig_xlib
+#define XGetIconSizes XGetIconSizes_dylibloader_orig_xlib
+#define XGetNormalHints XGetNormalHints_dylibloader_orig_xlib
+#define XGetRGBColormaps XGetRGBColormaps_dylibloader_orig_xlib
+#define XGetSizeHints XGetSizeHints_dylibloader_orig_xlib
+#define XGetStandardColormap XGetStandardColormap_dylibloader_orig_xlib
+#define XGetTextProperty XGetTextProperty_dylibloader_orig_xlib
+#define XGetVisualInfo XGetVisualInfo_dylibloader_orig_xlib
+#define XGetWMClientMachine XGetWMClientMachine_dylibloader_orig_xlib
+#define XGetWMHints XGetWMHints_dylibloader_orig_xlib
+#define XGetWMIconName XGetWMIconName_dylibloader_orig_xlib
+#define XGetWMName XGetWMName_dylibloader_orig_xlib
+#define XGetWMNormalHints XGetWMNormalHints_dylibloader_orig_xlib
+#define XGetWMSizeHints XGetWMSizeHints_dylibloader_orig_xlib
+#define XGetZoomHints XGetZoomHints_dylibloader_orig_xlib
+#define XIntersectRegion XIntersectRegion_dylibloader_orig_xlib
+#define XConvertCase XConvertCase_dylibloader_orig_xlib
+#define XLookupString XLookupString_dylibloader_orig_xlib
+#define XMatchVisualInfo XMatchVisualInfo_dylibloader_orig_xlib
+#define XOffsetRegion XOffsetRegion_dylibloader_orig_xlib
+#define XPointInRegion XPointInRegion_dylibloader_orig_xlib
+#define XPolygonRegion XPolygonRegion_dylibloader_orig_xlib
+#define XRectInRegion XRectInRegion_dylibloader_orig_xlib
+#define XSaveContext XSaveContext_dylibloader_orig_xlib
+#define XSetClassHint XSetClassHint_dylibloader_orig_xlib
+#define XSetIconSizes XSetIconSizes_dylibloader_orig_xlib
+#define XSetNormalHints XSetNormalHints_dylibloader_orig_xlib
+#define XSetRGBColormaps XSetRGBColormaps_dylibloader_orig_xlib
+#define XSetSizeHints XSetSizeHints_dylibloader_orig_xlib
+#define XSetStandardProperties XSetStandardProperties_dylibloader_orig_xlib
+#define XSetTextProperty XSetTextProperty_dylibloader_orig_xlib
+#define XSetWMClientMachine XSetWMClientMachine_dylibloader_orig_xlib
+#define XSetWMHints XSetWMHints_dylibloader_orig_xlib
+#define XSetWMIconName XSetWMIconName_dylibloader_orig_xlib
+#define XSetWMName XSetWMName_dylibloader_orig_xlib
+#define XSetWMNormalHints XSetWMNormalHints_dylibloader_orig_xlib
+#define XSetWMProperties XSetWMProperties_dylibloader_orig_xlib
+#define XmbSetWMProperties XmbSetWMProperties_dylibloader_orig_xlib
+#define Xutf8SetWMProperties Xutf8SetWMProperties_dylibloader_orig_xlib
+#define XSetWMSizeHints XSetWMSizeHints_dylibloader_orig_xlib
+#define XSetRegion XSetRegion_dylibloader_orig_xlib
+#define XSetStandardColormap XSetStandardColormap_dylibloader_orig_xlib
+#define XSetZoomHints XSetZoomHints_dylibloader_orig_xlib
+#define XShrinkRegion XShrinkRegion_dylibloader_orig_xlib
+#define XStringListToTextProperty XStringListToTextProperty_dylibloader_orig_xlib
+#define XSubtractRegion XSubtractRegion_dylibloader_orig_xlib
+#define XmbTextListToTextProperty XmbTextListToTextProperty_dylibloader_orig_xlib
+#define XwcTextListToTextProperty XwcTextListToTextProperty_dylibloader_orig_xlib
+#define Xutf8TextListToTextProperty Xutf8TextListToTextProperty_dylibloader_orig_xlib
+#define XwcFreeStringList XwcFreeStringList_dylibloader_orig_xlib
+#define XTextPropertyToStringList XTextPropertyToStringList_dylibloader_orig_xlib
+#define XmbTextPropertyToTextList XmbTextPropertyToTextList_dylibloader_orig_xlib
+#define XwcTextPropertyToTextList XwcTextPropertyToTextList_dylibloader_orig_xlib
+#define Xutf8TextPropertyToTextList Xutf8TextPropertyToTextList_dylibloader_orig_xlib
+#define XUnionRectWithRegion XUnionRectWithRegion_dylibloader_orig_xlib
+#define XUnionRegion XUnionRegion_dylibloader_orig_xlib
+#define XWMGeometry XWMGeometry_dylibloader_orig_xlib
+#define XXorRegion XXorRegion_dylibloader_orig_xlib
+#define XkbIgnoreExtension XkbIgnoreExtension_dylibloader_orig_xlib
+#define XkbOpenDisplay XkbOpenDisplay_dylibloader_orig_xlib
+#define XkbQueryExtension XkbQueryExtension_dylibloader_orig_xlib
+#define XkbUseExtension XkbUseExtension_dylibloader_orig_xlib
+#define XkbLibraryVersion XkbLibraryVersion_dylibloader_orig_xlib
+#define XkbSetXlibControls XkbSetXlibControls_dylibloader_orig_xlib
+#define XkbGetXlibControls XkbGetXlibControls_dylibloader_orig_xlib
+#define XkbXlibControlsImplemented XkbXlibControlsImplemented_dylibloader_orig_xlib
+#define XkbSetAtomFuncs XkbSetAtomFuncs_dylibloader_orig_xlib
+#define XkbKeycodeToKeysym XkbKeycodeToKeysym_dylibloader_orig_xlib
+#define XkbKeysymToModifiers XkbKeysymToModifiers_dylibloader_orig_xlib
+#define XkbLookupKeySym XkbLookupKeySym_dylibloader_orig_xlib
+#define XkbLookupKeyBinding XkbLookupKeyBinding_dylibloader_orig_xlib
+#define XkbTranslateKeyCode XkbTranslateKeyCode_dylibloader_orig_xlib
+#define XkbTranslateKeySym XkbTranslateKeySym_dylibloader_orig_xlib
+#define XkbSetAutoRepeatRate XkbSetAutoRepeatRate_dylibloader_orig_xlib
+#define XkbGetAutoRepeatRate XkbGetAutoRepeatRate_dylibloader_orig_xlib
+#define XkbChangeEnabledControls XkbChangeEnabledControls_dylibloader_orig_xlib
+#define XkbDeviceBell XkbDeviceBell_dylibloader_orig_xlib
+#define XkbForceDeviceBell XkbForceDeviceBell_dylibloader_orig_xlib
+#define XkbDeviceBellEvent XkbDeviceBellEvent_dylibloader_orig_xlib
+#define XkbBell XkbBell_dylibloader_orig_xlib
+#define XkbForceBell XkbForceBell_dylibloader_orig_xlib
+#define XkbBellEvent XkbBellEvent_dylibloader_orig_xlib
+#define XkbSelectEvents XkbSelectEvents_dylibloader_orig_xlib
+#define XkbSelectEventDetails XkbSelectEventDetails_dylibloader_orig_xlib
+#define XkbNoteMapChanges XkbNoteMapChanges_dylibloader_orig_xlib
+#define XkbNoteNameChanges XkbNoteNameChanges_dylibloader_orig_xlib
+#define XkbGetIndicatorState XkbGetIndicatorState_dylibloader_orig_xlib
+#define XkbGetIndicatorMap XkbGetIndicatorMap_dylibloader_orig_xlib
+#define XkbSetIndicatorMap XkbSetIndicatorMap_dylibloader_orig_xlib
+#define XkbGetNamedIndicator XkbGetNamedIndicator_dylibloader_orig_xlib
+#define XkbGetNamedDeviceIndicator XkbGetNamedDeviceIndicator_dylibloader_orig_xlib
+#define XkbSetNamedIndicator XkbSetNamedIndicator_dylibloader_orig_xlib
+#define XkbSetNamedDeviceIndicator XkbSetNamedDeviceIndicator_dylibloader_orig_xlib
+#define XkbLockModifiers XkbLockModifiers_dylibloader_orig_xlib
+#define XkbLatchModifiers XkbLatchModifiers_dylibloader_orig_xlib
+#define XkbLockGroup XkbLockGroup_dylibloader_orig_xlib
+#define XkbLatchGroup XkbLatchGroup_dylibloader_orig_xlib
+#define XkbSetServerInternalMods XkbSetServerInternalMods_dylibloader_orig_xlib
+#define XkbSetIgnoreLockMods XkbSetIgnoreLockMods_dylibloader_orig_xlib
+#define XkbVirtualModsToReal XkbVirtualModsToReal_dylibloader_orig_xlib
+#define XkbComputeEffectiveMap XkbComputeEffectiveMap_dylibloader_orig_xlib
+#define XkbInitCanonicalKeyTypes XkbInitCanonicalKeyTypes_dylibloader_orig_xlib
+#define XkbAllocKeyboard XkbAllocKeyboard_dylibloader_orig_xlib
+#define XkbFreeKeyboard XkbFreeKeyboard_dylibloader_orig_xlib
+#define XkbAllocClientMap XkbAllocClientMap_dylibloader_orig_xlib
+#define XkbAllocServerMap XkbAllocServerMap_dylibloader_orig_xlib
+#define XkbFreeClientMap XkbFreeClientMap_dylibloader_orig_xlib
+#define XkbFreeServerMap XkbFreeServerMap_dylibloader_orig_xlib
+#define XkbAddKeyType XkbAddKeyType_dylibloader_orig_xlib
+#define XkbAllocIndicatorMaps XkbAllocIndicatorMaps_dylibloader_orig_xlib
+#define XkbFreeIndicatorMaps XkbFreeIndicatorMaps_dylibloader_orig_xlib
+#define XkbGetMap XkbGetMap_dylibloader_orig_xlib
+#define XkbGetUpdatedMap XkbGetUpdatedMap_dylibloader_orig_xlib
+#define XkbGetMapChanges XkbGetMapChanges_dylibloader_orig_xlib
+#define XkbRefreshKeyboardMapping XkbRefreshKeyboardMapping_dylibloader_orig_xlib
+#define XkbGetKeyTypes XkbGetKeyTypes_dylibloader_orig_xlib
+#define XkbGetKeySyms XkbGetKeySyms_dylibloader_orig_xlib
+#define XkbGetKeyActions XkbGetKeyActions_dylibloader_orig_xlib
+#define XkbGetKeyBehaviors XkbGetKeyBehaviors_dylibloader_orig_xlib
+#define XkbGetVirtualMods XkbGetVirtualMods_dylibloader_orig_xlib
+#define XkbGetKeyExplicitComponents XkbGetKeyExplicitComponents_dylibloader_orig_xlib
+#define XkbGetKeyModifierMap XkbGetKeyModifierMap_dylibloader_orig_xlib
+#define XkbGetKeyVirtualModMap XkbGetKeyVirtualModMap_dylibloader_orig_xlib
+#define XkbAllocControls XkbAllocControls_dylibloader_orig_xlib
+#define XkbFreeControls XkbFreeControls_dylibloader_orig_xlib
+#define XkbGetControls XkbGetControls_dylibloader_orig_xlib
+#define XkbSetControls XkbSetControls_dylibloader_orig_xlib
+#define XkbNoteControlsChanges XkbNoteControlsChanges_dylibloader_orig_xlib
+#define XkbAllocCompatMap XkbAllocCompatMap_dylibloader_orig_xlib
+#define XkbFreeCompatMap XkbFreeCompatMap_dylibloader_orig_xlib
+#define XkbGetCompatMap XkbGetCompatMap_dylibloader_orig_xlib
+#define XkbSetCompatMap XkbSetCompatMap_dylibloader_orig_xlib
+#define XkbAllocNames XkbAllocNames_dylibloader_orig_xlib
+#define XkbGetNames XkbGetNames_dylibloader_orig_xlib
+#define XkbSetNames XkbSetNames_dylibloader_orig_xlib
+#define XkbChangeNames XkbChangeNames_dylibloader_orig_xlib
+#define XkbFreeNames XkbFreeNames_dylibloader_orig_xlib
+#define XkbGetState XkbGetState_dylibloader_orig_xlib
+#define XkbSetMap XkbSetMap_dylibloader_orig_xlib
+#define XkbChangeMap XkbChangeMap_dylibloader_orig_xlib
+#define XkbSetDetectableAutoRepeat XkbSetDetectableAutoRepeat_dylibloader_orig_xlib
+#define XkbGetDetectableAutoRepeat XkbGetDetectableAutoRepeat_dylibloader_orig_xlib
+#define XkbSetAutoResetControls XkbSetAutoResetControls_dylibloader_orig_xlib
+#define XkbGetAutoResetControls XkbGetAutoResetControls_dylibloader_orig_xlib
+#define XkbSetPerClientControls XkbSetPerClientControls_dylibloader_orig_xlib
+#define XkbGetPerClientControls XkbGetPerClientControls_dylibloader_orig_xlib
+#define XkbCopyKeyType XkbCopyKeyType_dylibloader_orig_xlib
+#define XkbCopyKeyTypes XkbCopyKeyTypes_dylibloader_orig_xlib
+#define XkbResizeKeyType XkbResizeKeyType_dylibloader_orig_xlib
+#define XkbResizeKeySyms XkbResizeKeySyms_dylibloader_orig_xlib
+#define XkbResizeKeyActions XkbResizeKeyActions_dylibloader_orig_xlib
+#define XkbChangeTypesOfKey XkbChangeTypesOfKey_dylibloader_orig_xlib
+#define XkbChangeKeycodeRange XkbChangeKeycodeRange_dylibloader_orig_xlib
+#define XkbListComponents XkbListComponents_dylibloader_orig_xlib
+#define XkbFreeComponentList XkbFreeComponentList_dylibloader_orig_xlib
+#define XkbGetKeyboard XkbGetKeyboard_dylibloader_orig_xlib
+#define XkbGetKeyboardByName XkbGetKeyboardByName_dylibloader_orig_xlib
+#define XkbKeyTypesForCoreSymbols XkbKeyTypesForCoreSymbols_dylibloader_orig_xlib
+#define XkbApplyCompatMapToKey XkbApplyCompatMapToKey_dylibloader_orig_xlib
+#define XkbUpdateMapFromCore XkbUpdateMapFromCore_dylibloader_orig_xlib
+#define XkbAddDeviceLedInfo XkbAddDeviceLedInfo_dylibloader_orig_xlib
+#define XkbResizeDeviceButtonActions XkbResizeDeviceButtonActions_dylibloader_orig_xlib
+#define XkbAllocDeviceInfo XkbAllocDeviceInfo_dylibloader_orig_xlib
+#define XkbFreeDeviceInfo XkbFreeDeviceInfo_dylibloader_orig_xlib
+#define XkbNoteDeviceChanges XkbNoteDeviceChanges_dylibloader_orig_xlib
+#define XkbGetDeviceInfo XkbGetDeviceInfo_dylibloader_orig_xlib
+#define XkbGetDeviceInfoChanges XkbGetDeviceInfoChanges_dylibloader_orig_xlib
+#define XkbGetDeviceButtonActions XkbGetDeviceButtonActions_dylibloader_orig_xlib
+#define XkbGetDeviceLedInfo XkbGetDeviceLedInfo_dylibloader_orig_xlib
+#define XkbSetDeviceInfo XkbSetDeviceInfo_dylibloader_orig_xlib
+#define XkbChangeDeviceInfo XkbChangeDeviceInfo_dylibloader_orig_xlib
+#define XkbSetDeviceLedInfo XkbSetDeviceLedInfo_dylibloader_orig_xlib
+#define XkbSetDeviceButtonActions XkbSetDeviceButtonActions_dylibloader_orig_xlib
+#define XkbToControl XkbToControl_dylibloader_orig_xlib
+#define XkbSetDebuggingFlags XkbSetDebuggingFlags_dylibloader_orig_xlib
+#define XkbApplyVirtualModChanges XkbApplyVirtualModChanges_dylibloader_orig_xlib
+#define XkbUpdateActionVirtualMods XkbUpdateActionVirtualMods_dylibloader_orig_xlib
+#define XkbUpdateKeyTypeVirtualMods XkbUpdateKeyTypeVirtualMods_dylibloader_orig_xlib
+#include "thirdparty/linuxbsd_headers/X11/Xlib.h"
+#include "thirdparty/linuxbsd_headers/X11/Xutil.h"
+#include "thirdparty/linuxbsd_headers/X11/XKBlib.h"
+#undef _Xmblen
+#undef XLoadQueryFont
+#undef XQueryFont
+#undef XGetMotionEvents
+#undef XDeleteModifiermapEntry
+#undef XGetModifierMapping
+#undef XInsertModifiermapEntry
+#undef XNewModifiermap
+#undef XCreateImage
+#undef XInitImage
+#undef XGetImage
+#undef XGetSubImage
+#undef XOpenDisplay
+#undef XrmInitialize
+#undef XFetchBytes
+#undef XFetchBuffer
+#undef XGetAtomName
+#undef XGetAtomNames
+#undef XGetDefault
+#undef XDisplayName
+#undef XKeysymToString
+#undef XSynchronize
+#undef XSetAfterFunction
+#undef XInternAtom
+#undef XInternAtoms
+#undef XCopyColormapAndFree
+#undef XCreateColormap
+#undef XCreatePixmapCursor
+#undef XCreateGlyphCursor
+#undef XCreateFontCursor
+#undef XLoadFont
+#undef XCreateGC
+#undef XGContextFromGC
+#undef XFlushGC
+#undef XCreatePixmap
+#undef XCreateBitmapFromData
+#undef XCreatePixmapFromBitmapData
+#undef XCreateSimpleWindow
+#undef XGetSelectionOwner
+#undef XCreateWindow
+#undef XListInstalledColormaps
+#undef XListFonts
+#undef XListFontsWithInfo
+#undef XGetFontPath
+#undef XListExtensions
+#undef XListProperties
+#undef XListHosts
+#undef XKeycodeToKeysym
+#undef XLookupKeysym
+#undef XGetKeyboardMapping
+#undef XStringToKeysym
+#undef XMaxRequestSize
+#undef XExtendedMaxRequestSize
+#undef XResourceManagerString
+#undef XScreenResourceString
+#undef XDisplayMotionBufferSize
+#undef XVisualIDFromVisual
+#undef XInitThreads
+#undef XLockDisplay
+#undef XUnlockDisplay
+#undef XInitExtension
+#undef XAddExtension
+#undef XFindOnExtensionList
+#undef XEHeadOfExtensionList
+#undef XRootWindow
+#undef XDefaultRootWindow
+#undef XRootWindowOfScreen
+#undef XDefaultVisual
+#undef XDefaultVisualOfScreen
+#undef XDefaultGC
+#undef XDefaultGCOfScreen
+#undef XBlackPixel
+#undef XWhitePixel
+#undef XAllPlanes
+#undef XBlackPixelOfScreen
+#undef XWhitePixelOfScreen
+#undef XNextRequest
+#undef XLastKnownRequestProcessed
+#undef XServerVendor
+#undef XDisplayString
+#undef XDefaultColormap
+#undef XDefaultColormapOfScreen
+#undef XDisplayOfScreen
+#undef XScreenOfDisplay
+#undef XDefaultScreenOfDisplay
+#undef XEventMaskOfScreen
+#undef XScreenNumberOfScreen
+#undef XSetErrorHandler
+#undef XSetIOErrorHandler
+#undef XListPixmapFormats
+#undef XListDepths
+#undef XReconfigureWMWindow
+#undef XGetWMProtocols
+#undef XSetWMProtocols
+#undef XIconifyWindow
+#undef XWithdrawWindow
+#undef XGetCommand
+#undef XGetWMColormapWindows
+#undef XSetWMColormapWindows
+#undef XFreeStringList
+#undef XSetTransientForHint
+#undef XActivateScreenSaver
+#undef XAddHost
+#undef XAddHosts
+#undef XAddToExtensionList
+#undef XAddToSaveSet
+#undef XAllocColor
+#undef XAllocColorCells
+#undef XAllocColorPlanes
+#undef XAllocNamedColor
+#undef XAllowEvents
+#undef XAutoRepeatOff
+#undef XAutoRepeatOn
+#undef XBell
+#undef XBitmapBitOrder
+#undef XBitmapPad
+#undef XBitmapUnit
+#undef XCellsOfScreen
+#undef XChangeActivePointerGrab
+#undef XChangeGC
+#undef XChangeKeyboardControl
+#undef XChangeKeyboardMapping
+#undef XChangePointerControl
+#undef XChangeProperty
+#undef XChangeSaveSet
+#undef XChangeWindowAttributes
+#undef XCheckIfEvent
+#undef XCheckMaskEvent
+#undef XCheckTypedEvent
+#undef XCheckTypedWindowEvent
+#undef XCheckWindowEvent
+#undef XCirculateSubwindows
+#undef XCirculateSubwindowsDown
+#undef XCirculateSubwindowsUp
+#undef XClearArea
+#undef XClearWindow
+#undef XCloseDisplay
+#undef XConfigureWindow
+#undef XConnectionNumber
+#undef XConvertSelection
+#undef XCopyArea
+#undef XCopyGC
+#undef XCopyPlane
+#undef XDefaultDepth
+#undef XDefaultDepthOfScreen
+#undef XDefaultScreen
+#undef XDefineCursor
+#undef XDeleteProperty
+#undef XDestroyWindow
+#undef XDestroySubwindows
+#undef XDoesBackingStore
+#undef XDoesSaveUnders
+#undef XDisableAccessControl
+#undef XDisplayCells
+#undef XDisplayHeight
+#undef XDisplayHeightMM
+#undef XDisplayKeycodes
+#undef XDisplayPlanes
+#undef XDisplayWidth
+#undef XDisplayWidthMM
+#undef XDrawArc
+#undef XDrawArcs
+#undef XDrawImageString
+#undef XDrawImageString16
+#undef XDrawLine
+#undef XDrawLines
+#undef XDrawPoint
+#undef XDrawPoints
+#undef XDrawRectangle
+#undef XDrawRectangles
+#undef XDrawSegments
+#undef XDrawString
+#undef XDrawString16
+#undef XDrawText
+#undef XDrawText16
+#undef XEnableAccessControl
+#undef XEventsQueued
+#undef XFetchName
+#undef XFillArc
+#undef XFillArcs
+#undef XFillPolygon
+#undef XFillRectangle
+#undef XFillRectangles
+#undef XFlush
+#undef XForceScreenSaver
+#undef XFree
+#undef XFreeColormap
+#undef XFreeColors
+#undef XFreeCursor
+#undef XFreeExtensionList
+#undef XFreeFont
+#undef XFreeFontInfo
+#undef XFreeFontNames
+#undef XFreeFontPath
+#undef XFreeGC
+#undef XFreeModifiermap
+#undef XFreePixmap
+#undef XGeometry
+#undef XGetErrorDatabaseText
+#undef XGetErrorText
+#undef XGetFontProperty
+#undef XGetGCValues
+#undef XGetGeometry
+#undef XGetIconName
+#undef XGetInputFocus
+#undef XGetKeyboardControl
+#undef XGetPointerControl
+#undef XGetPointerMapping
+#undef XGetScreenSaver
+#undef XGetTransientForHint
+#undef XGetWindowProperty
+#undef XGetWindowAttributes
+#undef XGrabButton
+#undef XGrabKey
+#undef XGrabKeyboard
+#undef XGrabPointer
+#undef XGrabServer
+#undef XHeightMMOfScreen
+#undef XHeightOfScreen
+#undef XIfEvent
+#undef XImageByteOrder
+#undef XInstallColormap
+#undef XKeysymToKeycode
+#undef XKillClient
+#undef XLookupColor
+#undef XLowerWindow
+#undef XMapRaised
+#undef XMapSubwindows
+#undef XMapWindow
+#undef XMaskEvent
+#undef XMaxCmapsOfScreen
+#undef XMinCmapsOfScreen
+#undef XMoveResizeWindow
+#undef XMoveWindow
+#undef XNextEvent
+#undef XNoOp
+#undef XParseColor
+#undef XParseGeometry
+#undef XPeekEvent
+#undef XPeekIfEvent
+#undef XPending
+#undef XPlanesOfScreen
+#undef XProtocolRevision
+#undef XProtocolVersion
+#undef XPutBackEvent
+#undef XPutImage
+#undef XQLength
+#undef XQueryBestCursor
+#undef XQueryBestSize
+#undef XQueryBestStipple
+#undef XQueryBestTile
+#undef XQueryColor
+#undef XQueryColors
+#undef XQueryExtension
+#undef XQueryKeymap
+#undef XQueryPointer
+#undef XQueryTextExtents
+#undef XQueryTextExtents16
+#undef XQueryTree
+#undef XRaiseWindow
+#undef XReadBitmapFile
+#undef XReadBitmapFileData
+#undef XRebindKeysym
+#undef XRecolorCursor
+#undef XRefreshKeyboardMapping
+#undef XRemoveFromSaveSet
+#undef XRemoveHost
+#undef XRemoveHosts
+#undef XReparentWindow
+#undef XResetScreenSaver
+#undef XResizeWindow
+#undef XRestackWindows
+#undef XRotateBuffers
+#undef XRotateWindowProperties
+#undef XScreenCount
+#undef XSelectInput
+#undef XSendEvent
+#undef XSetAccessControl
+#undef XSetArcMode
+#undef XSetBackground
+#undef XSetClipMask
+#undef XSetClipOrigin
+#undef XSetClipRectangles
+#undef XSetCloseDownMode
+#undef XSetCommand
+#undef XSetDashes
+#undef XSetFillRule
+#undef XSetFillStyle
+#undef XSetFont
+#undef XSetFontPath
+#undef XSetForeground
+#undef XSetFunction
+#undef XSetGraphicsExposures
+#undef XSetIconName
+#undef XSetInputFocus
+#undef XSetLineAttributes
+#undef XSetModifierMapping
+#undef XSetPlaneMask
+#undef XSetPointerMapping
+#undef XSetScreenSaver
+#undef XSetSelectionOwner
+#undef XSetState
+#undef XSetStipple
+#undef XSetSubwindowMode
+#undef XSetTSOrigin
+#undef XSetTile
+#undef XSetWindowBackground
+#undef XSetWindowBackgroundPixmap
+#undef XSetWindowBorder
+#undef XSetWindowBorderPixmap
+#undef XSetWindowBorderWidth
+#undef XSetWindowColormap
+#undef XStoreBuffer
+#undef XStoreBytes
+#undef XStoreColor
+#undef XStoreColors
+#undef XStoreName
+#undef XStoreNamedColor
+#undef XSync
+#undef XTextExtents
+#undef XTextExtents16
+#undef XTextWidth
+#undef XTextWidth16
+#undef XTranslateCoordinates
+#undef XUndefineCursor
+#undef XUngrabButton
+#undef XUngrabKey
+#undef XUngrabKeyboard
+#undef XUngrabPointer
+#undef XUngrabServer
+#undef XUninstallColormap
+#undef XUnloadFont
+#undef XUnmapSubwindows
+#undef XUnmapWindow
+#undef XVendorRelease
+#undef XWarpPointer
+#undef XWidthMMOfScreen
+#undef XWidthOfScreen
+#undef XWindowEvent
+#undef XWriteBitmapFile
+#undef XSupportsLocale
+#undef XSetLocaleModifiers
+#undef XOpenOM
+#undef XCloseOM
+#undef XSetOMValues
+#undef XGetOMValues
+#undef XDisplayOfOM
+#undef XLocaleOfOM
+#undef XCreateOC
+#undef XDestroyOC
+#undef XOMOfOC
+#undef XSetOCValues
+#undef XGetOCValues
+#undef XCreateFontSet
+#undef XFreeFontSet
+#undef XFontsOfFontSet
+#undef XBaseFontNameListOfFontSet
+#undef XLocaleOfFontSet
+#undef XContextDependentDrawing
+#undef XDirectionalDependentDrawing
+#undef XContextualDrawing
+#undef XExtentsOfFontSet
+#undef XmbTextEscapement
+#undef XwcTextEscapement
+#undef Xutf8TextEscapement
+#undef XmbTextExtents
+#undef XwcTextExtents
+#undef Xutf8TextExtents
+#undef XmbTextPerCharExtents
+#undef XwcTextPerCharExtents
+#undef Xutf8TextPerCharExtents
+#undef XmbDrawText
+#undef XwcDrawText
+#undef Xutf8DrawText
+#undef XmbDrawString
+#undef XwcDrawString
+#undef Xutf8DrawString
+#undef XmbDrawImageString
+#undef XwcDrawImageString
+#undef Xutf8DrawImageString
+#undef XOpenIM
+#undef XCloseIM
+#undef XGetIMValues
+#undef XSetIMValues
+#undef XDisplayOfIM
+#undef XLocaleOfIM
+#undef XCreateIC
+#undef XDestroyIC
+#undef XSetICFocus
+#undef XUnsetICFocus
+#undef XwcResetIC
+#undef XmbResetIC
+#undef Xutf8ResetIC
+#undef XSetICValues
+#undef XGetICValues
+#undef XIMOfIC
+#undef XFilterEvent
+#undef XmbLookupString
+#undef XwcLookupString
+#undef Xutf8LookupString
+#undef XVaCreateNestedList
+#undef XRegisterIMInstantiateCallback
+#undef XUnregisterIMInstantiateCallback
+#undef XInternalConnectionNumbers
+#undef XProcessInternalConnection
+#undef XAddConnectionWatch
+#undef XRemoveConnectionWatch
+#undef XSetAuthorization
+#undef _Xmbtowc
+#undef _Xwctomb
+#undef XGetEventData
+#undef XFreeEventData
+#undef XAllocClassHint
+#undef XAllocIconSize
+#undef XAllocSizeHints
+#undef XAllocStandardColormap
+#undef XAllocWMHints
+#undef XClipBox
+#undef XCreateRegion
+#undef XDefaultString
+#undef XDeleteContext
+#undef XDestroyRegion
+#undef XEmptyRegion
+#undef XEqualRegion
+#undef XFindContext
+#undef XGetClassHint
+#undef XGetIconSizes
+#undef XGetNormalHints
+#undef XGetRGBColormaps
+#undef XGetSizeHints
+#undef XGetStandardColormap
+#undef XGetTextProperty
+#undef XGetVisualInfo
+#undef XGetWMClientMachine
+#undef XGetWMHints
+#undef XGetWMIconName
+#undef XGetWMName
+#undef XGetWMNormalHints
+#undef XGetWMSizeHints
+#undef XGetZoomHints
+#undef XIntersectRegion
+#undef XConvertCase
+#undef XLookupString
+#undef XMatchVisualInfo
+#undef XOffsetRegion
+#undef XPointInRegion
+#undef XPolygonRegion
+#undef XRectInRegion
+#undef XSaveContext
+#undef XSetClassHint
+#undef XSetIconSizes
+#undef XSetNormalHints
+#undef XSetRGBColormaps
+#undef XSetSizeHints
+#undef XSetStandardProperties
+#undef XSetTextProperty
+#undef XSetWMClientMachine
+#undef XSetWMHints
+#undef XSetWMIconName
+#undef XSetWMName
+#undef XSetWMNormalHints
+#undef XSetWMProperties
+#undef XmbSetWMProperties
+#undef Xutf8SetWMProperties
+#undef XSetWMSizeHints
+#undef XSetRegion
+#undef XSetStandardColormap
+#undef XSetZoomHints
+#undef XShrinkRegion
+#undef XStringListToTextProperty
+#undef XSubtractRegion
+#undef XmbTextListToTextProperty
+#undef XwcTextListToTextProperty
+#undef Xutf8TextListToTextProperty
+#undef XwcFreeStringList
+#undef XTextPropertyToStringList
+#undef XmbTextPropertyToTextList
+#undef XwcTextPropertyToTextList
+#undef Xutf8TextPropertyToTextList
+#undef XUnionRectWithRegion
+#undef XUnionRegion
+#undef XWMGeometry
+#undef XXorRegion
+#undef XkbIgnoreExtension
+#undef XkbOpenDisplay
+#undef XkbQueryExtension
+#undef XkbUseExtension
+#undef XkbLibraryVersion
+#undef XkbSetXlibControls
+#undef XkbGetXlibControls
+#undef XkbXlibControlsImplemented
+#undef XkbSetAtomFuncs
+#undef XkbKeycodeToKeysym
+#undef XkbKeysymToModifiers
+#undef XkbLookupKeySym
+#undef XkbLookupKeyBinding
+#undef XkbTranslateKeyCode
+#undef XkbTranslateKeySym
+#undef XkbSetAutoRepeatRate
+#undef XkbGetAutoRepeatRate
+#undef XkbChangeEnabledControls
+#undef XkbDeviceBell
+#undef XkbForceDeviceBell
+#undef XkbDeviceBellEvent
+#undef XkbBell
+#undef XkbForceBell
+#undef XkbBellEvent
+#undef XkbSelectEvents
+#undef XkbSelectEventDetails
+#undef XkbNoteMapChanges
+#undef XkbNoteNameChanges
+#undef XkbGetIndicatorState
+#undef XkbGetIndicatorMap
+#undef XkbSetIndicatorMap
+#undef XkbGetNamedIndicator
+#undef XkbGetNamedDeviceIndicator
+#undef XkbSetNamedIndicator
+#undef XkbSetNamedDeviceIndicator
+#undef XkbLockModifiers
+#undef XkbLatchModifiers
+#undef XkbLockGroup
+#undef XkbLatchGroup
+#undef XkbSetServerInternalMods
+#undef XkbSetIgnoreLockMods
+#undef XkbVirtualModsToReal
+#undef XkbComputeEffectiveMap
+#undef XkbInitCanonicalKeyTypes
+#undef XkbAllocKeyboard
+#undef XkbFreeKeyboard
+#undef XkbAllocClientMap
+#undef XkbAllocServerMap
+#undef XkbFreeClientMap
+#undef XkbFreeServerMap
+#undef XkbAddKeyType
+#undef XkbAllocIndicatorMaps
+#undef XkbFreeIndicatorMaps
+#undef XkbGetMap
+#undef XkbGetUpdatedMap
+#undef XkbGetMapChanges
+#undef XkbRefreshKeyboardMapping
+#undef XkbGetKeyTypes
+#undef XkbGetKeySyms
+#undef XkbGetKeyActions
+#undef XkbGetKeyBehaviors
+#undef XkbGetVirtualMods
+#undef XkbGetKeyExplicitComponents
+#undef XkbGetKeyModifierMap
+#undef XkbGetKeyVirtualModMap
+#undef XkbAllocControls
+#undef XkbFreeControls
+#undef XkbGetControls
+#undef XkbSetControls
+#undef XkbNoteControlsChanges
+#undef XkbAllocCompatMap
+#undef XkbFreeCompatMap
+#undef XkbGetCompatMap
+#undef XkbSetCompatMap
+#undef XkbAllocNames
+#undef XkbGetNames
+#undef XkbSetNames
+#undef XkbChangeNames
+#undef XkbFreeNames
+#undef XkbGetState
+#undef XkbSetMap
+#undef XkbChangeMap
+#undef XkbSetDetectableAutoRepeat
+#undef XkbGetDetectableAutoRepeat
+#undef XkbSetAutoResetControls
+#undef XkbGetAutoResetControls
+#undef XkbSetPerClientControls
+#undef XkbGetPerClientControls
+#undef XkbCopyKeyType
+#undef XkbCopyKeyTypes
+#undef XkbResizeKeyType
+#undef XkbResizeKeySyms
+#undef XkbResizeKeyActions
+#undef XkbChangeTypesOfKey
+#undef XkbChangeKeycodeRange
+#undef XkbListComponents
+#undef XkbFreeComponentList
+#undef XkbGetKeyboard
+#undef XkbGetKeyboardByName
+#undef XkbKeyTypesForCoreSymbols
+#undef XkbApplyCompatMapToKey
+#undef XkbUpdateMapFromCore
+#undef XkbAddDeviceLedInfo
+#undef XkbResizeDeviceButtonActions
+#undef XkbAllocDeviceInfo
+#undef XkbFreeDeviceInfo
+#undef XkbNoteDeviceChanges
+#undef XkbGetDeviceInfo
+#undef XkbGetDeviceInfoChanges
+#undef XkbGetDeviceButtonActions
+#undef XkbGetDeviceLedInfo
+#undef XkbSetDeviceInfo
+#undef XkbChangeDeviceInfo
+#undef XkbSetDeviceLedInfo
+#undef XkbSetDeviceButtonActions
+#undef XkbToControl
+#undef XkbSetDebuggingFlags
+#undef XkbApplyVirtualModChanges
+#undef XkbUpdateActionVirtualMods
+#undef XkbUpdateKeyTypeVirtualMods
+#include <dlfcn.h>
+#include <stdio.h>
+int (*_Xmblen_dylibloader_wrapper_xlib)( char*, int);
+XFontStruct* (*XLoadQueryFont_dylibloader_wrapper_xlib)( Display*,const char*);
+XFontStruct* (*XQueryFont_dylibloader_wrapper_xlib)( Display*, XID);
+XTimeCoord* (*XGetMotionEvents_dylibloader_wrapper_xlib)( Display*, Window, Time, Time, int*);
+XModifierKeymap* (*XDeleteModifiermapEntry_dylibloader_wrapper_xlib)( XModifierKeymap*, KeyCode, int);
+XModifierKeymap* (*XGetModifierMapping_dylibloader_wrapper_xlib)( Display*);
+XModifierKeymap* (*XInsertModifiermapEntry_dylibloader_wrapper_xlib)( XModifierKeymap*, KeyCode, int);
+XModifierKeymap* (*XNewModifiermap_dylibloader_wrapper_xlib)( int);
+XImage* (*XCreateImage_dylibloader_wrapper_xlib)( Display*, Visual*, unsigned int, int, int, char*, unsigned int, unsigned int, int, int);
+int (*XInitImage_dylibloader_wrapper_xlib)( XImage*);
+XImage* (*XGetImage_dylibloader_wrapper_xlib)( Display*, Drawable, int, int, unsigned int, unsigned int, unsigned long, int);
+XImage* (*XGetSubImage_dylibloader_wrapper_xlib)( Display*, Drawable, int, int, unsigned int, unsigned int, unsigned long, int, XImage*, int, int);
+Display* (*XOpenDisplay_dylibloader_wrapper_xlib)(const char*);
+void (*XrmInitialize_dylibloader_wrapper_xlib)( void);
+char* (*XFetchBytes_dylibloader_wrapper_xlib)( Display*, int*);
+char* (*XFetchBuffer_dylibloader_wrapper_xlib)( Display*, int*, int);
+char* (*XGetAtomName_dylibloader_wrapper_xlib)( Display*, Atom);
+int (*XGetAtomNames_dylibloader_wrapper_xlib)( Display*, Atom*, int, char**);
+char* (*XGetDefault_dylibloader_wrapper_xlib)( Display*,const char*,const char*);
+char* (*XDisplayName_dylibloader_wrapper_xlib)(const char*);
+char* (*XKeysymToString_dylibloader_wrapper_xlib)( KeySym);
+int* (*XSynchronize_dylibloader_wrapper_xlib)( Display*, int);
+int* (*XSetAfterFunction_dylibloader_wrapper_xlib)( Display*, int*);
+Atom (*XInternAtom_dylibloader_wrapper_xlib)( Display*,const char*, int);
+int (*XInternAtoms_dylibloader_wrapper_xlib)( Display*, char**, int, int, Atom*);
+Colormap (*XCopyColormapAndFree_dylibloader_wrapper_xlib)( Display*, Colormap);
+Colormap (*XCreateColormap_dylibloader_wrapper_xlib)( Display*, Window, Visual*, int);
+Cursor (*XCreatePixmapCursor_dylibloader_wrapper_xlib)( Display*, Pixmap, Pixmap, XColor*, XColor*, unsigned int, unsigned int);
+Cursor (*XCreateGlyphCursor_dylibloader_wrapper_xlib)( Display*, Font, Font, unsigned int, unsigned int,const XColor*,const XColor*);
+Cursor (*XCreateFontCursor_dylibloader_wrapper_xlib)( Display*, unsigned int);
+Font (*XLoadFont_dylibloader_wrapper_xlib)( Display*,const char*);
+GC (*XCreateGC_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned long, XGCValues*);
+GContext (*XGContextFromGC_dylibloader_wrapper_xlib)( GC);
+void (*XFlushGC_dylibloader_wrapper_xlib)( Display*, GC);
+Pixmap (*XCreatePixmap_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int);
+Pixmap (*XCreateBitmapFromData_dylibloader_wrapper_xlib)( Display*, Drawable,const char*, unsigned int, unsigned int);
+Pixmap (*XCreatePixmapFromBitmapData_dylibloader_wrapper_xlib)( Display*, Drawable, char*, unsigned int, unsigned int, unsigned long, unsigned long, unsigned int);
+Window (*XCreateSimpleWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int, unsigned int, unsigned long, unsigned long);
+Window (*XGetSelectionOwner_dylibloader_wrapper_xlib)( Display*, Atom);
+Window (*XCreateWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int, unsigned int, int, unsigned int, Visual*, unsigned long, XSetWindowAttributes*);
+Colormap* (*XListInstalledColormaps_dylibloader_wrapper_xlib)( Display*, Window, int*);
+char** (*XListFonts_dylibloader_wrapper_xlib)( Display*,const char*, int, int*);
+char** (*XListFontsWithInfo_dylibloader_wrapper_xlib)( Display*,const char*, int, int*, XFontStruct**);
+char** (*XGetFontPath_dylibloader_wrapper_xlib)( Display*, int*);
+char** (*XListExtensions_dylibloader_wrapper_xlib)( Display*, int*);
+Atom* (*XListProperties_dylibloader_wrapper_xlib)( Display*, Window, int*);
+XHostAddress* (*XListHosts_dylibloader_wrapper_xlib)( Display*, int*, int*);
+KeySym (*XKeycodeToKeysym_dylibloader_wrapper_xlib)( Display*, KeyCode, int);
+KeySym (*XLookupKeysym_dylibloader_wrapper_xlib)( XKeyEvent*, int);
+KeySym* (*XGetKeyboardMapping_dylibloader_wrapper_xlib)( Display*, KeyCode, int, int*);
+KeySym (*XStringToKeysym_dylibloader_wrapper_xlib)(const char*);
+long (*XMaxRequestSize_dylibloader_wrapper_xlib)( Display*);
+long (*XExtendedMaxRequestSize_dylibloader_wrapper_xlib)( Display*);
+char* (*XResourceManagerString_dylibloader_wrapper_xlib)( Display*);
+char* (*XScreenResourceString_dylibloader_wrapper_xlib)( Screen*);
+unsigned long (*XDisplayMotionBufferSize_dylibloader_wrapper_xlib)( Display*);
+VisualID (*XVisualIDFromVisual_dylibloader_wrapper_xlib)( Visual*);
+int (*XInitThreads_dylibloader_wrapper_xlib)( void);
+void (*XLockDisplay_dylibloader_wrapper_xlib)( Display*);
+void (*XUnlockDisplay_dylibloader_wrapper_xlib)( Display*);
+XExtCodes* (*XInitExtension_dylibloader_wrapper_xlib)( Display*,const char*);
+XExtCodes* (*XAddExtension_dylibloader_wrapper_xlib)( Display*);
+XExtData* (*XFindOnExtensionList_dylibloader_wrapper_xlib)( XExtData**, int);
+XExtData** (*XEHeadOfExtensionList_dylibloader_wrapper_xlib)( XEDataObject);
+Window (*XRootWindow_dylibloader_wrapper_xlib)( Display*, int);
+Window (*XDefaultRootWindow_dylibloader_wrapper_xlib)( Display*);
+Window (*XRootWindowOfScreen_dylibloader_wrapper_xlib)( Screen*);
+Visual* (*XDefaultVisual_dylibloader_wrapper_xlib)( Display*, int);
+Visual* (*XDefaultVisualOfScreen_dylibloader_wrapper_xlib)( Screen*);
+GC (*XDefaultGC_dylibloader_wrapper_xlib)( Display*, int);
+GC (*XDefaultGCOfScreen_dylibloader_wrapper_xlib)( Screen*);
+unsigned long (*XBlackPixel_dylibloader_wrapper_xlib)( Display*, int);
+unsigned long (*XWhitePixel_dylibloader_wrapper_xlib)( Display*, int);
+unsigned long (*XAllPlanes_dylibloader_wrapper_xlib)( void);
+unsigned long (*XBlackPixelOfScreen_dylibloader_wrapper_xlib)( Screen*);
+unsigned long (*XWhitePixelOfScreen_dylibloader_wrapper_xlib)( Screen*);
+unsigned long (*XNextRequest_dylibloader_wrapper_xlib)( Display*);
+unsigned long (*XLastKnownRequestProcessed_dylibloader_wrapper_xlib)( Display*);
+char* (*XServerVendor_dylibloader_wrapper_xlib)( Display*);
+char* (*XDisplayString_dylibloader_wrapper_xlib)( Display*);
+Colormap (*XDefaultColormap_dylibloader_wrapper_xlib)( Display*, int);
+Colormap (*XDefaultColormapOfScreen_dylibloader_wrapper_xlib)( Screen*);
+Display* (*XDisplayOfScreen_dylibloader_wrapper_xlib)( Screen*);
+Screen* (*XScreenOfDisplay_dylibloader_wrapper_xlib)( Display*, int);
+Screen* (*XDefaultScreenOfDisplay_dylibloader_wrapper_xlib)( Display*);
+long (*XEventMaskOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XScreenNumberOfScreen_dylibloader_wrapper_xlib)( Screen*);
+XErrorHandler (*XSetErrorHandler_dylibloader_wrapper_xlib)( XErrorHandler);
+XIOErrorHandler (*XSetIOErrorHandler_dylibloader_wrapper_xlib)( XIOErrorHandler);
+XPixmapFormatValues* (*XListPixmapFormats_dylibloader_wrapper_xlib)( Display*, int*);
+int* (*XListDepths_dylibloader_wrapper_xlib)( Display*, int, int*);
+int (*XReconfigureWMWindow_dylibloader_wrapper_xlib)( Display*, Window, int, unsigned int, XWindowChanges*);
+int (*XGetWMProtocols_dylibloader_wrapper_xlib)( Display*, Window, Atom**, int*);
+int (*XSetWMProtocols_dylibloader_wrapper_xlib)( Display*, Window, Atom*, int);
+int (*XIconifyWindow_dylibloader_wrapper_xlib)( Display*, Window, int);
+int (*XWithdrawWindow_dylibloader_wrapper_xlib)( Display*, Window, int);
+int (*XGetCommand_dylibloader_wrapper_xlib)( Display*, Window, char***, int*);
+int (*XGetWMColormapWindows_dylibloader_wrapper_xlib)( Display*, Window, Window**, int*);
+int (*XSetWMColormapWindows_dylibloader_wrapper_xlib)( Display*, Window, Window*, int);
+void (*XFreeStringList_dylibloader_wrapper_xlib)( char**);
+int (*XSetTransientForHint_dylibloader_wrapper_xlib)( Display*, Window, Window);
+int (*XActivateScreenSaver_dylibloader_wrapper_xlib)( Display*);
+int (*XAddHost_dylibloader_wrapper_xlib)( Display*, XHostAddress*);
+int (*XAddHosts_dylibloader_wrapper_xlib)( Display*, XHostAddress*, int);
+int (*XAddToExtensionList_dylibloader_wrapper_xlib)(struct _XExtData**, XExtData*);
+int (*XAddToSaveSet_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XAllocColor_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*);
+int (*XAllocColorCells_dylibloader_wrapper_xlib)( Display*, Colormap, int, unsigned long*, unsigned int, unsigned long*, unsigned int);
+int (*XAllocColorPlanes_dylibloader_wrapper_xlib)( Display*, Colormap, int, unsigned long*, int, int, int, int, unsigned long*, unsigned long*, unsigned long*);
+int (*XAllocNamedColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, XColor*, XColor*);
+int (*XAllowEvents_dylibloader_wrapper_xlib)( Display*, int, Time);
+int (*XAutoRepeatOff_dylibloader_wrapper_xlib)( Display*);
+int (*XAutoRepeatOn_dylibloader_wrapper_xlib)( Display*);
+int (*XBell_dylibloader_wrapper_xlib)( Display*, int);
+int (*XBitmapBitOrder_dylibloader_wrapper_xlib)( Display*);
+int (*XBitmapPad_dylibloader_wrapper_xlib)( Display*);
+int (*XBitmapUnit_dylibloader_wrapper_xlib)( Display*);
+int (*XCellsOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XChangeActivePointerGrab_dylibloader_wrapper_xlib)( Display*, unsigned int, Cursor, Time);
+int (*XChangeGC_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, XGCValues*);
+int (*XChangeKeyboardControl_dylibloader_wrapper_xlib)( Display*, unsigned long, XKeyboardControl*);
+int (*XChangeKeyboardMapping_dylibloader_wrapper_xlib)( Display*, int, int, KeySym*, int);
+int (*XChangePointerControl_dylibloader_wrapper_xlib)( Display*, int, int, int, int, int);
+int (*XChangeProperty_dylibloader_wrapper_xlib)( Display*, Window, Atom, Atom, int, int,const unsigned char*, int);
+int (*XChangeSaveSet_dylibloader_wrapper_xlib)( Display*, Window, int);
+int (*XChangeWindowAttributes_dylibloader_wrapper_xlib)( Display*, Window, unsigned long, XSetWindowAttributes*);
+int (*XCheckIfEvent_dylibloader_wrapper_xlib)( Display*, XEvent*, Bool (*) (Display*, XEvent*, XPointer), XPointer);
+int (*XCheckMaskEvent_dylibloader_wrapper_xlib)( Display*, long, XEvent*);
+int (*XCheckTypedEvent_dylibloader_wrapper_xlib)( Display*, int, XEvent*);
+int (*XCheckTypedWindowEvent_dylibloader_wrapper_xlib)( Display*, Window, int, XEvent*);
+int (*XCheckWindowEvent_dylibloader_wrapper_xlib)( Display*, Window, long, XEvent*);
+int (*XCirculateSubwindows_dylibloader_wrapper_xlib)( Display*, Window, int);
+int (*XCirculateSubwindowsDown_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XCirculateSubwindowsUp_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XClearArea_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int, int);
+int (*XClearWindow_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XCloseDisplay_dylibloader_wrapper_xlib)( Display*);
+int (*XConfigureWindow_dylibloader_wrapper_xlib)( Display*, Window, unsigned int, XWindowChanges*);
+int (*XConnectionNumber_dylibloader_wrapper_xlib)( Display*);
+int (*XConvertSelection_dylibloader_wrapper_xlib)( Display*, Atom, Atom, Atom, Window, Time);
+int (*XCopyArea_dylibloader_wrapper_xlib)( Display*, Drawable, Drawable, GC, int, int, unsigned int, unsigned int, int, int);
+int (*XCopyGC_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, GC);
+int (*XCopyPlane_dylibloader_wrapper_xlib)( Display*, Drawable, Drawable, GC, int, int, unsigned int, unsigned int, int, int, unsigned long);
+int (*XDefaultDepth_dylibloader_wrapper_xlib)( Display*, int);
+int (*XDefaultDepthOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XDefaultScreen_dylibloader_wrapper_xlib)( Display*);
+int (*XDefineCursor_dylibloader_wrapper_xlib)( Display*, Window, Cursor);
+int (*XDeleteProperty_dylibloader_wrapper_xlib)( Display*, Window, Atom);
+int (*XDestroyWindow_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XDestroySubwindows_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XDoesBackingStore_dylibloader_wrapper_xlib)( Screen*);
+int (*XDoesSaveUnders_dylibloader_wrapper_xlib)( Screen*);
+int (*XDisableAccessControl_dylibloader_wrapper_xlib)( Display*);
+int (*XDisplayCells_dylibloader_wrapper_xlib)( Display*, int);
+int (*XDisplayHeight_dylibloader_wrapper_xlib)( Display*, int);
+int (*XDisplayHeightMM_dylibloader_wrapper_xlib)( Display*, int);
+int (*XDisplayKeycodes_dylibloader_wrapper_xlib)( Display*, int*, int*);
+int (*XDisplayPlanes_dylibloader_wrapper_xlib)( Display*, int);
+int (*XDisplayWidth_dylibloader_wrapper_xlib)( Display*, int);
+int (*XDisplayWidthMM_dylibloader_wrapper_xlib)( Display*, int);
+int (*XDrawArc_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int, int, int);
+int (*XDrawArcs_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XArc*, int);
+int (*XDrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const char*, int);
+int (*XDrawImageString16_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const XChar2b*, int);
+int (*XDrawLine_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, int, int);
+int (*XDrawLines_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XPoint*, int, int);
+int (*XDrawPoint_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int);
+int (*XDrawPoints_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XPoint*, int, int);
+int (*XDrawRectangle_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int);
+int (*XDrawRectangles_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XRectangle*, int);
+int (*XDrawSegments_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XSegment*, int);
+int (*XDrawString_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const char*, int);
+int (*XDrawString16_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const XChar2b*, int);
+int (*XDrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XTextItem*, int);
+int (*XDrawText16_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XTextItem16*, int);
+int (*XEnableAccessControl_dylibloader_wrapper_xlib)( Display*);
+int (*XEventsQueued_dylibloader_wrapper_xlib)( Display*, int);
+int (*XFetchName_dylibloader_wrapper_xlib)( Display*, Window, char**);
+int (*XFillArc_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int, int, int);
+int (*XFillArcs_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XArc*, int);
+int (*XFillPolygon_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XPoint*, int, int, int);
+int (*XFillRectangle_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int);
+int (*XFillRectangles_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XRectangle*, int);
+int (*XFlush_dylibloader_wrapper_xlib)( Display*);
+int (*XForceScreenSaver_dylibloader_wrapper_xlib)( Display*, int);
+int (*XFree_dylibloader_wrapper_xlib)( void*);
+int (*XFreeColormap_dylibloader_wrapper_xlib)( Display*, Colormap);
+int (*XFreeColors_dylibloader_wrapper_xlib)( Display*, Colormap, unsigned long*, int, unsigned long);
+int (*XFreeCursor_dylibloader_wrapper_xlib)( Display*, Cursor);
+int (*XFreeExtensionList_dylibloader_wrapper_xlib)( char**);
+int (*XFreeFont_dylibloader_wrapper_xlib)( Display*, XFontStruct*);
+int (*XFreeFontInfo_dylibloader_wrapper_xlib)( char**, XFontStruct*, int);
+int (*XFreeFontNames_dylibloader_wrapper_xlib)( char**);
+int (*XFreeFontPath_dylibloader_wrapper_xlib)( char**);
+int (*XFreeGC_dylibloader_wrapper_xlib)( Display*, GC);
+int (*XFreeModifiermap_dylibloader_wrapper_xlib)( XModifierKeymap*);
+int (*XFreePixmap_dylibloader_wrapper_xlib)( Display*, Pixmap);
+int (*XGeometry_dylibloader_wrapper_xlib)( Display*, int,const char*,const char*, unsigned int, unsigned int, unsigned int, int, int, int*, int*, int*, int*);
+int (*XGetErrorDatabaseText_dylibloader_wrapper_xlib)( Display*,const char*,const char*,const char*, char*, int);
+int (*XGetErrorText_dylibloader_wrapper_xlib)( Display*, int, char*, int);
+int (*XGetFontProperty_dylibloader_wrapper_xlib)( XFontStruct*, Atom, unsigned long*);
+int (*XGetGCValues_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, XGCValues*);
+int (*XGetGeometry_dylibloader_wrapper_xlib)( Display*, Drawable, Window*, int*, int*, unsigned int*, unsigned int*, unsigned int*, unsigned int*);
+int (*XGetIconName_dylibloader_wrapper_xlib)( Display*, Window, char**);
+int (*XGetInputFocus_dylibloader_wrapper_xlib)( Display*, Window*, int*);
+int (*XGetKeyboardControl_dylibloader_wrapper_xlib)( Display*, XKeyboardState*);
+int (*XGetPointerControl_dylibloader_wrapper_xlib)( Display*, int*, int*, int*);
+int (*XGetPointerMapping_dylibloader_wrapper_xlib)( Display*, unsigned char*, int);
+int (*XGetScreenSaver_dylibloader_wrapper_xlib)( Display*, int*, int*, int*, int*);
+int (*XGetTransientForHint_dylibloader_wrapper_xlib)( Display*, Window, Window*);
+int (*XGetWindowProperty_dylibloader_wrapper_xlib)( Display*, Window, Atom, long, long, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+int (*XGetWindowAttributes_dylibloader_wrapper_xlib)( Display*, Window, XWindowAttributes*);
+int (*XGrabButton_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, Window, int, unsigned int, int, int, Window, Cursor);
+int (*XGrabKey_dylibloader_wrapper_xlib)( Display*, int, unsigned int, Window, int, int, int);
+int (*XGrabKeyboard_dylibloader_wrapper_xlib)( Display*, Window, int, int, int, Time);
+int (*XGrabPointer_dylibloader_wrapper_xlib)( Display*, Window, int, unsigned int, int, int, Window, Cursor, Time);
+int (*XGrabServer_dylibloader_wrapper_xlib)( Display*);
+int (*XHeightMMOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XHeightOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XIfEvent_dylibloader_wrapper_xlib)( Display*, XEvent*, Bool (*) (Display*, XEvent*, XPointer), XPointer);
+int (*XImageByteOrder_dylibloader_wrapper_xlib)( Display*);
+int (*XInstallColormap_dylibloader_wrapper_xlib)( Display*, Colormap);
+KeyCode (*XKeysymToKeycode_dylibloader_wrapper_xlib)( Display*, KeySym);
+int (*XKillClient_dylibloader_wrapper_xlib)( Display*, XID);
+int (*XLookupColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, XColor*, XColor*);
+int (*XLowerWindow_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XMapRaised_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XMapSubwindows_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XMapWindow_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XMaskEvent_dylibloader_wrapper_xlib)( Display*, long, XEvent*);
+int (*XMaxCmapsOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XMinCmapsOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XMoveResizeWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int);
+int (*XMoveWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int);
+int (*XNextEvent_dylibloader_wrapper_xlib)( Display*, XEvent*);
+int (*XNoOp_dylibloader_wrapper_xlib)( Display*);
+int (*XParseColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, XColor*);
+int (*XParseGeometry_dylibloader_wrapper_xlib)(const char*, int*, int*, unsigned int*, unsigned int*);
+int (*XPeekEvent_dylibloader_wrapper_xlib)( Display*, XEvent*);
+int (*XPeekIfEvent_dylibloader_wrapper_xlib)( Display*, XEvent*, Bool (*) (Display*, XEvent*, XPointer), XPointer);
+int (*XPending_dylibloader_wrapper_xlib)( Display*);
+int (*XPlanesOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XProtocolRevision_dylibloader_wrapper_xlib)( Display*);
+int (*XProtocolVersion_dylibloader_wrapper_xlib)( Display*);
+int (*XPutBackEvent_dylibloader_wrapper_xlib)( Display*, XEvent*);
+int (*XPutImage_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XImage*, int, int, int, int, unsigned int, unsigned int);
+int (*XQLength_dylibloader_wrapper_xlib)( Display*);
+int (*XQueryBestCursor_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+int (*XQueryBestSize_dylibloader_wrapper_xlib)( Display*, int, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+int (*XQueryBestStipple_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+int (*XQueryBestTile_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+int (*XQueryColor_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*);
+int (*XQueryColors_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*, int);
+int (*XQueryExtension_dylibloader_wrapper_xlib)( Display*,const char*, int*, int*, int*);
+int (*XQueryKeymap_dylibloader_wrapper_xlib)( Display*, char [32]);
+int (*XQueryPointer_dylibloader_wrapper_xlib)( Display*, Window, Window*, Window*, int*, int*, int*, int*, unsigned int*);
+int (*XQueryTextExtents_dylibloader_wrapper_xlib)( Display*, XID,const char*, int, int*, int*, int*, XCharStruct*);
+int (*XQueryTextExtents16_dylibloader_wrapper_xlib)( Display*, XID,const XChar2b*, int, int*, int*, int*, XCharStruct*);
+int (*XQueryTree_dylibloader_wrapper_xlib)( Display*, Window, Window*, Window*, Window**, unsigned int*);
+int (*XRaiseWindow_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XReadBitmapFile_dylibloader_wrapper_xlib)( Display*, Drawable,const char*, unsigned int*, unsigned int*, Pixmap*, int*, int*);
+int (*XReadBitmapFileData_dylibloader_wrapper_xlib)(const char*, unsigned int*, unsigned int*, unsigned char**, int*, int*);
+int (*XRebindKeysym_dylibloader_wrapper_xlib)( Display*, KeySym, KeySym*, int,const unsigned char*, int);
+int (*XRecolorCursor_dylibloader_wrapper_xlib)( Display*, Cursor, XColor*, XColor*);
+int (*XRefreshKeyboardMapping_dylibloader_wrapper_xlib)( XMappingEvent*);
+int (*XRemoveFromSaveSet_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XRemoveHost_dylibloader_wrapper_xlib)( Display*, XHostAddress*);
+int (*XRemoveHosts_dylibloader_wrapper_xlib)( Display*, XHostAddress*, int);
+int (*XReparentWindow_dylibloader_wrapper_xlib)( Display*, Window, Window, int, int);
+int (*XResetScreenSaver_dylibloader_wrapper_xlib)( Display*);
+int (*XResizeWindow_dylibloader_wrapper_xlib)( Display*, Window, unsigned int, unsigned int);
+int (*XRestackWindows_dylibloader_wrapper_xlib)( Display*, Window*, int);
+int (*XRotateBuffers_dylibloader_wrapper_xlib)( Display*, int);
+int (*XRotateWindowProperties_dylibloader_wrapper_xlib)( Display*, Window, Atom*, int, int);
+int (*XScreenCount_dylibloader_wrapper_xlib)( Display*);
+int (*XSelectInput_dylibloader_wrapper_xlib)( Display*, Window, long);
+int (*XSendEvent_dylibloader_wrapper_xlib)( Display*, Window, int, long, XEvent*);
+int (*XSetAccessControl_dylibloader_wrapper_xlib)( Display*, int);
+int (*XSetArcMode_dylibloader_wrapper_xlib)( Display*, GC, int);
+int (*XSetBackground_dylibloader_wrapper_xlib)( Display*, GC, unsigned long);
+int (*XSetClipMask_dylibloader_wrapper_xlib)( Display*, GC, Pixmap);
+int (*XSetClipOrigin_dylibloader_wrapper_xlib)( Display*, GC, int, int);
+int (*XSetClipRectangles_dylibloader_wrapper_xlib)( Display*, GC, int, int, XRectangle*, int, int);
+int (*XSetCloseDownMode_dylibloader_wrapper_xlib)( Display*, int);
+int (*XSetCommand_dylibloader_wrapper_xlib)( Display*, Window, char**, int);
+int (*XSetDashes_dylibloader_wrapper_xlib)( Display*, GC, int,const char*, int);
+int (*XSetFillRule_dylibloader_wrapper_xlib)( Display*, GC, int);
+int (*XSetFillStyle_dylibloader_wrapper_xlib)( Display*, GC, int);
+int (*XSetFont_dylibloader_wrapper_xlib)( Display*, GC, Font);
+int (*XSetFontPath_dylibloader_wrapper_xlib)( Display*, char**, int);
+int (*XSetForeground_dylibloader_wrapper_xlib)( Display*, GC, unsigned long);
+int (*XSetFunction_dylibloader_wrapper_xlib)( Display*, GC, int);
+int (*XSetGraphicsExposures_dylibloader_wrapper_xlib)( Display*, GC, int);
+int (*XSetIconName_dylibloader_wrapper_xlib)( Display*, Window,const char*);
+int (*XSetInputFocus_dylibloader_wrapper_xlib)( Display*, Window, int, Time);
+int (*XSetLineAttributes_dylibloader_wrapper_xlib)( Display*, GC, unsigned int, int, int, int);
+int (*XSetModifierMapping_dylibloader_wrapper_xlib)( Display*, XModifierKeymap*);
+int (*XSetPlaneMask_dylibloader_wrapper_xlib)( Display*, GC, unsigned long);
+int (*XSetPointerMapping_dylibloader_wrapper_xlib)( Display*,const unsigned char*, int);
+int (*XSetScreenSaver_dylibloader_wrapper_xlib)( Display*, int, int, int, int);
+int (*XSetSelectionOwner_dylibloader_wrapper_xlib)( Display*, Atom, Window, Time);
+int (*XSetState_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, unsigned long, int, unsigned long);
+int (*XSetStipple_dylibloader_wrapper_xlib)( Display*, GC, Pixmap);
+int (*XSetSubwindowMode_dylibloader_wrapper_xlib)( Display*, GC, int);
+int (*XSetTSOrigin_dylibloader_wrapper_xlib)( Display*, GC, int, int);
+int (*XSetTile_dylibloader_wrapper_xlib)( Display*, GC, Pixmap);
+int (*XSetWindowBackground_dylibloader_wrapper_xlib)( Display*, Window, unsigned long);
+int (*XSetWindowBackgroundPixmap_dylibloader_wrapper_xlib)( Display*, Window, Pixmap);
+int (*XSetWindowBorder_dylibloader_wrapper_xlib)( Display*, Window, unsigned long);
+int (*XSetWindowBorderPixmap_dylibloader_wrapper_xlib)( Display*, Window, Pixmap);
+int (*XSetWindowBorderWidth_dylibloader_wrapper_xlib)( Display*, Window, unsigned int);
+int (*XSetWindowColormap_dylibloader_wrapper_xlib)( Display*, Window, Colormap);
+int (*XStoreBuffer_dylibloader_wrapper_xlib)( Display*,const char*, int, int);
+int (*XStoreBytes_dylibloader_wrapper_xlib)( Display*,const char*, int);
+int (*XStoreColor_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*);
+int (*XStoreColors_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*, int);
+int (*XStoreName_dylibloader_wrapper_xlib)( Display*, Window,const char*);
+int (*XStoreNamedColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, unsigned long, int);
+int (*XSync_dylibloader_wrapper_xlib)( Display*, int);
+int (*XTextExtents_dylibloader_wrapper_xlib)( XFontStruct*,const char*, int, int*, int*, int*, XCharStruct*);
+int (*XTextExtents16_dylibloader_wrapper_xlib)( XFontStruct*,const XChar2b*, int, int*, int*, int*, XCharStruct*);
+int (*XTextWidth_dylibloader_wrapper_xlib)( XFontStruct*,const char*, int);
+int (*XTextWidth16_dylibloader_wrapper_xlib)( XFontStruct*,const XChar2b*, int);
+int (*XTranslateCoordinates_dylibloader_wrapper_xlib)( Display*, Window, Window, int, int, int*, int*, Window*);
+int (*XUndefineCursor_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XUngrabButton_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, Window);
+int (*XUngrabKey_dylibloader_wrapper_xlib)( Display*, int, unsigned int, Window);
+int (*XUngrabKeyboard_dylibloader_wrapper_xlib)( Display*, Time);
+int (*XUngrabPointer_dylibloader_wrapper_xlib)( Display*, Time);
+int (*XUngrabServer_dylibloader_wrapper_xlib)( Display*);
+int (*XUninstallColormap_dylibloader_wrapper_xlib)( Display*, Colormap);
+int (*XUnloadFont_dylibloader_wrapper_xlib)( Display*, Font);
+int (*XUnmapSubwindows_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XUnmapWindow_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XVendorRelease_dylibloader_wrapper_xlib)( Display*);
+int (*XWarpPointer_dylibloader_wrapper_xlib)( Display*, Window, Window, int, int, unsigned int, unsigned int, int, int);
+int (*XWidthMMOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XWidthOfScreen_dylibloader_wrapper_xlib)( Screen*);
+int (*XWindowEvent_dylibloader_wrapper_xlib)( Display*, Window, long, XEvent*);
+int (*XWriteBitmapFile_dylibloader_wrapper_xlib)( Display*,const char*, Pixmap, unsigned int, unsigned int, int, int);
+int (*XSupportsLocale_dylibloader_wrapper_xlib)( void);
+char* (*XSetLocaleModifiers_dylibloader_wrapper_xlib)(const char*);
+XOM (*XOpenOM_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*,const char*,const char*);
+int (*XCloseOM_dylibloader_wrapper_xlib)( XOM);
+char* (*XSetOMValues_dylibloader_wrapper_xlib)( XOM,...);
+char* (*XGetOMValues_dylibloader_wrapper_xlib)( XOM,...);
+Display* (*XDisplayOfOM_dylibloader_wrapper_xlib)( XOM);
+char* (*XLocaleOfOM_dylibloader_wrapper_xlib)( XOM);
+XOC (*XCreateOC_dylibloader_wrapper_xlib)( XOM,...);
+void (*XDestroyOC_dylibloader_wrapper_xlib)( XOC);
+XOM (*XOMOfOC_dylibloader_wrapper_xlib)( XOC);
+char* (*XSetOCValues_dylibloader_wrapper_xlib)( XOC,...);
+char* (*XGetOCValues_dylibloader_wrapper_xlib)( XOC,...);
+XFontSet (*XCreateFontSet_dylibloader_wrapper_xlib)( Display*,const char*, char***, int*, char**);
+void (*XFreeFontSet_dylibloader_wrapper_xlib)( Display*, XFontSet);
+int (*XFontsOfFontSet_dylibloader_wrapper_xlib)( XFontSet, XFontStruct***, char***);
+char* (*XBaseFontNameListOfFontSet_dylibloader_wrapper_xlib)( XFontSet);
+char* (*XLocaleOfFontSet_dylibloader_wrapper_xlib)( XFontSet);
+int (*XContextDependentDrawing_dylibloader_wrapper_xlib)( XFontSet);
+int (*XDirectionalDependentDrawing_dylibloader_wrapper_xlib)( XFontSet);
+int (*XContextualDrawing_dylibloader_wrapper_xlib)( XFontSet);
+XFontSetExtents* (*XExtentsOfFontSet_dylibloader_wrapper_xlib)( XFontSet);
+int (*XmbTextEscapement_dylibloader_wrapper_xlib)( XFontSet,const char*, int);
+int (*XwcTextEscapement_dylibloader_wrapper_xlib)( XFontSet,const wchar_t*, int);
+int (*Xutf8TextEscapement_dylibloader_wrapper_xlib)( XFontSet,const char*, int);
+int (*XmbTextExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*);
+int (*XwcTextExtents_dylibloader_wrapper_xlib)( XFontSet,const wchar_t*, int, XRectangle*, XRectangle*);
+int (*Xutf8TextExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*);
+int (*XmbTextPerCharExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*, int, int*, XRectangle*, XRectangle*);
+int (*XwcTextPerCharExtents_dylibloader_wrapper_xlib)( XFontSet,const wchar_t*, int, XRectangle*, XRectangle*, int, int*, XRectangle*, XRectangle*);
+int (*Xutf8TextPerCharExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*, int, int*, XRectangle*, XRectangle*);
+void (*XmbDrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XmbTextItem*, int);
+void (*XwcDrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XwcTextItem*, int);
+void (*Xutf8DrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XmbTextItem*, int);
+void (*XmbDrawString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+void (*XwcDrawString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const wchar_t*, int);
+void (*Xutf8DrawString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+void (*XmbDrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+void (*XwcDrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const wchar_t*, int);
+void (*Xutf8DrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+XIM (*XOpenIM_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*, char*, char*);
+int (*XCloseIM_dylibloader_wrapper_xlib)( XIM);
+char* (*XGetIMValues_dylibloader_wrapper_xlib)( XIM,...);
+char* (*XSetIMValues_dylibloader_wrapper_xlib)( XIM,...);
+Display* (*XDisplayOfIM_dylibloader_wrapper_xlib)( XIM);
+char* (*XLocaleOfIM_dylibloader_wrapper_xlib)( XIM);
+XIC (*XCreateIC_dylibloader_wrapper_xlib)( XIM,...);
+void (*XDestroyIC_dylibloader_wrapper_xlib)( XIC);
+void (*XSetICFocus_dylibloader_wrapper_xlib)( XIC);
+void (*XUnsetICFocus_dylibloader_wrapper_xlib)( XIC);
+wchar_t* (*XwcResetIC_dylibloader_wrapper_xlib)( XIC);
+char* (*XmbResetIC_dylibloader_wrapper_xlib)( XIC);
+char* (*Xutf8ResetIC_dylibloader_wrapper_xlib)( XIC);
+char* (*XSetICValues_dylibloader_wrapper_xlib)( XIC,...);
+char* (*XGetICValues_dylibloader_wrapper_xlib)( XIC,...);
+XIM (*XIMOfIC_dylibloader_wrapper_xlib)( XIC);
+int (*XFilterEvent_dylibloader_wrapper_xlib)( XEvent*, Window);
+int (*XmbLookupString_dylibloader_wrapper_xlib)( XIC, XKeyPressedEvent*, char*, int, KeySym*, int*);
+int (*XwcLookupString_dylibloader_wrapper_xlib)( XIC, XKeyPressedEvent*, wchar_t*, int, KeySym*, int*);
+int (*Xutf8LookupString_dylibloader_wrapper_xlib)( XIC, XKeyPressedEvent*, char*, int, KeySym*, int*);
+XVaNestedList (*XVaCreateNestedList_dylibloader_wrapper_xlib)( int,...);
+int (*XRegisterIMInstantiateCallback_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*, char*, char*, XIDProc, XPointer);
+int (*XUnregisterIMInstantiateCallback_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*, char*, char*, XIDProc, XPointer);
+int (*XInternalConnectionNumbers_dylibloader_wrapper_xlib)( Display*, int**, int*);
+void (*XProcessInternalConnection_dylibloader_wrapper_xlib)( Display*, int);
+int (*XAddConnectionWatch_dylibloader_wrapper_xlib)( Display*, XConnectionWatchProc, XPointer);
+void (*XRemoveConnectionWatch_dylibloader_wrapper_xlib)( Display*, XConnectionWatchProc, XPointer);
+void (*XSetAuthorization_dylibloader_wrapper_xlib)( char*, int, char*, int);
+int (*_Xmbtowc_dylibloader_wrapper_xlib)( wchar_t*, char*, int);
+int (*_Xwctomb_dylibloader_wrapper_xlib)( char*, wchar_t);
+int (*XGetEventData_dylibloader_wrapper_xlib)( Display*, XGenericEventCookie*);
+void (*XFreeEventData_dylibloader_wrapper_xlib)( Display*, XGenericEventCookie*);
+XClassHint* (*XAllocClassHint_dylibloader_wrapper_xlib)( void);
+XIconSize* (*XAllocIconSize_dylibloader_wrapper_xlib)( void);
+XSizeHints* (*XAllocSizeHints_dylibloader_wrapper_xlib)( void);
+XStandardColormap* (*XAllocStandardColormap_dylibloader_wrapper_xlib)( void);
+XWMHints* (*XAllocWMHints_dylibloader_wrapper_xlib)( void);
+int (*XClipBox_dylibloader_wrapper_xlib)( Region, XRectangle*);
+Region (*XCreateRegion_dylibloader_wrapper_xlib)( void);
+const char* (*XDefaultString_dylibloader_wrapper_xlib)( void);
+int (*XDeleteContext_dylibloader_wrapper_xlib)( Display*, XID, XContext);
+int (*XDestroyRegion_dylibloader_wrapper_xlib)( Region);
+int (*XEmptyRegion_dylibloader_wrapper_xlib)( Region);
+int (*XEqualRegion_dylibloader_wrapper_xlib)( Region, Region);
+int (*XFindContext_dylibloader_wrapper_xlib)( Display*, XID, XContext, XPointer*);
+int (*XGetClassHint_dylibloader_wrapper_xlib)( Display*, Window, XClassHint*);
+int (*XGetIconSizes_dylibloader_wrapper_xlib)( Display*, Window, XIconSize**, int*);
+int (*XGetNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+int (*XGetRGBColormaps_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap**, int*, Atom);
+int (*XGetSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, Atom);
+int (*XGetStandardColormap_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap*, Atom);
+int (*XGetTextProperty_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*, Atom);
+XVisualInfo* (*XGetVisualInfo_dylibloader_wrapper_xlib)( Display*, long, XVisualInfo*, int*);
+int (*XGetWMClientMachine_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+XWMHints* (*XGetWMHints_dylibloader_wrapper_xlib)( Display*, Window);
+int (*XGetWMIconName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+int (*XGetWMName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+int (*XGetWMNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, long*);
+int (*XGetWMSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, long*, Atom);
+int (*XGetZoomHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+int (*XIntersectRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+void (*XConvertCase_dylibloader_wrapper_xlib)( KeySym, KeySym*, KeySym*);
+int (*XLookupString_dylibloader_wrapper_xlib)( XKeyEvent*, char*, int, KeySym*, XComposeStatus*);
+int (*XMatchVisualInfo_dylibloader_wrapper_xlib)( Display*, int, int, int, XVisualInfo*);
+int (*XOffsetRegion_dylibloader_wrapper_xlib)( Region, int, int);
+int (*XPointInRegion_dylibloader_wrapper_xlib)( Region, int, int);
+Region (*XPolygonRegion_dylibloader_wrapper_xlib)( XPoint*, int, int);
+int (*XRectInRegion_dylibloader_wrapper_xlib)( Region, int, int, unsigned int, unsigned int);
+int (*XSaveContext_dylibloader_wrapper_xlib)( Display*, XID, XContext,const char*);
+int (*XSetClassHint_dylibloader_wrapper_xlib)( Display*, Window, XClassHint*);
+int (*XSetIconSizes_dylibloader_wrapper_xlib)( Display*, Window, XIconSize*, int);
+int (*XSetNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+void (*XSetRGBColormaps_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap*, int, Atom);
+int (*XSetSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, Atom);
+int (*XSetStandardProperties_dylibloader_wrapper_xlib)( Display*, Window,const char*,const char*, Pixmap, char**, int, XSizeHints*);
+void (*XSetTextProperty_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*, Atom);
+void (*XSetWMClientMachine_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+int (*XSetWMHints_dylibloader_wrapper_xlib)( Display*, Window, XWMHints*);
+void (*XSetWMIconName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+void (*XSetWMName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+void (*XSetWMNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+void (*XSetWMProperties_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*, XTextProperty*, char**, int, XSizeHints*, XWMHints*, XClassHint*);
+void (*XmbSetWMProperties_dylibloader_wrapper_xlib)( Display*, Window,const char*,const char*, char**, int, XSizeHints*, XWMHints*, XClassHint*);
+void (*Xutf8SetWMProperties_dylibloader_wrapper_xlib)( Display*, Window,const char*,const char*, char**, int, XSizeHints*, XWMHints*, XClassHint*);
+void (*XSetWMSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, Atom);
+int (*XSetRegion_dylibloader_wrapper_xlib)( Display*, GC, Region);
+void (*XSetStandardColormap_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap*, Atom);
+int (*XSetZoomHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+int (*XShrinkRegion_dylibloader_wrapper_xlib)( Region, int, int);
+int (*XStringListToTextProperty_dylibloader_wrapper_xlib)( char**, int, XTextProperty*);
+int (*XSubtractRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+int (*XmbTextListToTextProperty_dylibloader_wrapper_xlib)( Display*, char**, int, XICCEncodingStyle, XTextProperty*);
+int (*XwcTextListToTextProperty_dylibloader_wrapper_xlib)( Display*, wchar_t**, int, XICCEncodingStyle, XTextProperty*);
+int (*Xutf8TextListToTextProperty_dylibloader_wrapper_xlib)( Display*, char**, int, XICCEncodingStyle, XTextProperty*);
+void (*XwcFreeStringList_dylibloader_wrapper_xlib)( wchar_t**);
+int (*XTextPropertyToStringList_dylibloader_wrapper_xlib)( XTextProperty*, char***, int*);
+int (*XmbTextPropertyToTextList_dylibloader_wrapper_xlib)( Display*,const XTextProperty*, char***, int*);
+int (*XwcTextPropertyToTextList_dylibloader_wrapper_xlib)( Display*,const XTextProperty*, wchar_t***, int*);
+int (*Xutf8TextPropertyToTextList_dylibloader_wrapper_xlib)( Display*,const XTextProperty*, char***, int*);
+int (*XUnionRectWithRegion_dylibloader_wrapper_xlib)( XRectangle*, Region, Region);
+int (*XUnionRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+int (*XWMGeometry_dylibloader_wrapper_xlib)( Display*, int,const char*,const char*, unsigned int, XSizeHints*, int*, int*, int*, int*, int*);
+int (*XXorRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+int (*XkbIgnoreExtension_dylibloader_wrapper_xlib)( int);
+Display* (*XkbOpenDisplay_dylibloader_wrapper_xlib)( char*, int*, int*, int*, int*, int*);
+int (*XkbQueryExtension_dylibloader_wrapper_xlib)( Display*, int*, int*, int*, int*, int*);
+int (*XkbUseExtension_dylibloader_wrapper_xlib)( Display*, int*, int*);
+int (*XkbLibraryVersion_dylibloader_wrapper_xlib)( int*, int*);
+unsigned int (*XkbSetXlibControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+unsigned int (*XkbGetXlibControls_dylibloader_wrapper_xlib)( Display*);
+unsigned int (*XkbXlibControlsImplemented_dylibloader_wrapper_xlib)( void);
+void (*XkbSetAtomFuncs_dylibloader_wrapper_xlib)( XkbInternAtomFunc, XkbGetAtomNameFunc);
+KeySym (*XkbKeycodeToKeysym_dylibloader_wrapper_xlib)( Display*, KeyCode, int, int);
+unsigned int (*XkbKeysymToModifiers_dylibloader_wrapper_xlib)( Display*, KeySym);
+int (*XkbLookupKeySym_dylibloader_wrapper_xlib)( Display*, KeyCode, unsigned int, unsigned int*, KeySym*);
+int (*XkbLookupKeyBinding_dylibloader_wrapper_xlib)( Display*, KeySym, unsigned int, char*, int, int*);
+int (*XkbTranslateKeyCode_dylibloader_wrapper_xlib)( XkbDescPtr, KeyCode, unsigned int, unsigned int*, KeySym*);
+int (*XkbTranslateKeySym_dylibloader_wrapper_xlib)( Display*, KeySym*, unsigned int, char*, int, int*);
+int (*XkbSetAutoRepeatRate_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+int (*XkbGetAutoRepeatRate_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*, unsigned int*);
+int (*XkbChangeEnabledControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+int (*XkbDeviceBell_dylibloader_wrapper_xlib)( Display*, Window, int, int, int, int, Atom);
+int (*XkbForceDeviceBell_dylibloader_wrapper_xlib)( Display*, int, int, int, int);
+int (*XkbDeviceBellEvent_dylibloader_wrapper_xlib)( Display*, Window, int, int, int, int, Atom);
+int (*XkbBell_dylibloader_wrapper_xlib)( Display*, Window, int, Atom);
+int (*XkbForceBell_dylibloader_wrapper_xlib)( Display*, int);
+int (*XkbBellEvent_dylibloader_wrapper_xlib)( Display*, Window, int, Atom);
+int (*XkbSelectEvents_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+int (*XkbSelectEventDetails_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned long, unsigned long);
+void (*XkbNoteMapChanges_dylibloader_wrapper_xlib)( XkbMapChangesPtr, XkbMapNotifyEvent*, unsigned int);
+void (*XkbNoteNameChanges_dylibloader_wrapper_xlib)( XkbNameChangesPtr, XkbNamesNotifyEvent*, unsigned int);
+int (*XkbGetIndicatorState_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*);
+int (*XkbGetIndicatorMap_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+int (*XkbSetIndicatorMap_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+int (*XkbGetNamedIndicator_dylibloader_wrapper_xlib)( Display*, Atom, int*, int*, XkbIndicatorMapPtr, int*);
+int (*XkbGetNamedDeviceIndicator_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, Atom, int*, int*, XkbIndicatorMapPtr, int*);
+int (*XkbSetNamedIndicator_dylibloader_wrapper_xlib)( Display*, Atom, int, int, int, XkbIndicatorMapPtr);
+int (*XkbSetNamedDeviceIndicator_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, Atom, int, int, int, XkbIndicatorMapPtr);
+int (*XkbLockModifiers_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+int (*XkbLatchModifiers_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+int (*XkbLockGroup_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+int (*XkbLatchGroup_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+int (*XkbSetServerInternalMods_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int);
+int (*XkbSetIgnoreLockMods_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int);
+int (*XkbVirtualModsToReal_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int*);
+int (*XkbComputeEffectiveMap_dylibloader_wrapper_xlib)( XkbDescPtr, XkbKeyTypePtr, unsigned char*);
+int (*XkbInitCanonicalKeyTypes_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+XkbDescPtr (*XkbAllocKeyboard_dylibloader_wrapper_xlib)( void);
+void (*XkbFreeKeyboard_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+int (*XkbAllocClientMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int);
+int (*XkbAllocServerMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int);
+void (*XkbFreeClientMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+void (*XkbFreeServerMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+XkbKeyTypePtr (*XkbAddKeyType_dylibloader_wrapper_xlib)( XkbDescPtr, Atom, int, int, int);
+int (*XkbAllocIndicatorMaps_dylibloader_wrapper_xlib)( XkbDescPtr);
+void (*XkbFreeIndicatorMaps_dylibloader_wrapper_xlib)( XkbDescPtr);
+XkbDescPtr (*XkbGetMap_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+int (*XkbGetUpdatedMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+int (*XkbGetMapChanges_dylibloader_wrapper_xlib)( Display*, XkbDescPtr, XkbMapChangesPtr);
+int (*XkbRefreshKeyboardMapping_dylibloader_wrapper_xlib)( XkbMapNotifyEvent*);
+int (*XkbGetKeyTypes_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbGetKeySyms_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbGetKeyActions_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbGetKeyBehaviors_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbGetVirtualMods_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+int (*XkbGetKeyExplicitComponents_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbGetKeyModifierMap_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbGetKeyVirtualModMap_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbAllocControls_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int);
+void (*XkbFreeControls_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+int (*XkbGetControls_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+int (*XkbSetControls_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+void (*XkbNoteControlsChanges_dylibloader_wrapper_xlib)( XkbControlsChangesPtr, XkbControlsNotifyEvent*, unsigned int);
+int (*XkbAllocCompatMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int);
+void (*XkbFreeCompatMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+int (*XkbGetCompatMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+int (*XkbSetCompatMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr, int);
+int (*XkbAllocNames_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int, int);
+int (*XkbGetNames_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+int (*XkbSetNames_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, XkbDescPtr);
+int (*XkbChangeNames_dylibloader_wrapper_xlib)( Display*, XkbDescPtr, XkbNameChangesPtr);
+void (*XkbFreeNames_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+int (*XkbGetState_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbStatePtr);
+int (*XkbSetMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+int (*XkbChangeMap_dylibloader_wrapper_xlib)( Display*, XkbDescPtr, XkbMapChangesPtr);
+int (*XkbSetDetectableAutoRepeat_dylibloader_wrapper_xlib)( Display*, int, int*);
+int (*XkbGetDetectableAutoRepeat_dylibloader_wrapper_xlib)( Display*, int*);
+int (*XkbSetAutoResetControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*, unsigned int*);
+int (*XkbGetAutoResetControls_dylibloader_wrapper_xlib)( Display*, unsigned int*, unsigned int*);
+int (*XkbSetPerClientControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*);
+int (*XkbGetPerClientControls_dylibloader_wrapper_xlib)( Display*, unsigned int*);
+int (*XkbCopyKeyType_dylibloader_wrapper_xlib)( XkbKeyTypePtr, XkbKeyTypePtr);
+int (*XkbCopyKeyTypes_dylibloader_wrapper_xlib)( XkbKeyTypePtr, XkbKeyTypePtr, int);
+int (*XkbResizeKeyType_dylibloader_wrapper_xlib)( XkbDescPtr, int, int, int, int);
+KeySym* (*XkbResizeKeySyms_dylibloader_wrapper_xlib)( XkbDescPtr, int, int);
+XkbAction* (*XkbResizeKeyActions_dylibloader_wrapper_xlib)( XkbDescPtr, int, int);
+int (*XkbChangeTypesOfKey_dylibloader_wrapper_xlib)( XkbDescPtr, int, int, unsigned int, int*, XkbMapChangesPtr);
+int (*XkbChangeKeycodeRange_dylibloader_wrapper_xlib)( XkbDescPtr, int, int, XkbChangesPtr);
+XkbComponentListPtr (*XkbListComponents_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbComponentNamesPtr, int*);
+void (*XkbFreeComponentList_dylibloader_wrapper_xlib)( XkbComponentListPtr);
+XkbDescPtr (*XkbGetKeyboard_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+XkbDescPtr (*XkbGetKeyboardByName_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbComponentNamesPtr, unsigned int, unsigned int, int);
+int (*XkbKeyTypesForCoreSymbols_dylibloader_wrapper_xlib)( XkbDescPtr, int, KeySym*, unsigned int, int*, KeySym*);
+int (*XkbApplyCompatMapToKey_dylibloader_wrapper_xlib)( XkbDescPtr, KeyCode, XkbChangesPtr);
+int (*XkbUpdateMapFromCore_dylibloader_wrapper_xlib)( XkbDescPtr, KeyCode, int, int, KeySym*, XkbChangesPtr);
+XkbDeviceLedInfoPtr (*XkbAddDeviceLedInfo_dylibloader_wrapper_xlib)( XkbDeviceInfoPtr, unsigned int, unsigned int);
+int (*XkbResizeDeviceButtonActions_dylibloader_wrapper_xlib)( XkbDeviceInfoPtr, unsigned int);
+XkbDeviceInfoPtr (*XkbAllocDeviceInfo_dylibloader_wrapper_xlib)( unsigned int, unsigned int, unsigned int);
+void (*XkbFreeDeviceInfo_dylibloader_wrapper_xlib)( XkbDeviceInfoPtr, unsigned int, int);
+void (*XkbNoteDeviceChanges_dylibloader_wrapper_xlib)( XkbDeviceChangesPtr, XkbExtensionDeviceNotifyEvent*, unsigned int);
+XkbDeviceInfoPtr (*XkbGetDeviceInfo_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, unsigned int);
+int (*XkbGetDeviceInfoChanges_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, XkbDeviceChangesPtr);
+int (*XkbGetDeviceButtonActions_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, int, unsigned int, unsigned int);
+int (*XkbGetDeviceLedInfo_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, unsigned int, unsigned int, unsigned int);
+int (*XkbSetDeviceInfo_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDeviceInfoPtr);
+int (*XkbChangeDeviceInfo_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, XkbDeviceChangesPtr);
+int (*XkbSetDeviceLedInfo_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, unsigned int, unsigned int, unsigned int);
+int (*XkbSetDeviceButtonActions_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, unsigned int, unsigned int);
+char (*XkbToControl_dylibloader_wrapper_xlib)( char);
+int (*XkbSetDebuggingFlags_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, char*, unsigned int, unsigned int, unsigned int*, unsigned int*);
+int (*XkbApplyVirtualModChanges_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, XkbChangesPtr);
+int (*XkbUpdateActionVirtualMods_dylibloader_wrapper_xlib)( XkbDescPtr, XkbAction*, unsigned int);
+void (*XkbUpdateKeyTypeVirtualMods_dylibloader_wrapper_xlib)( XkbDescPtr, XkbKeyTypePtr, unsigned int, XkbChangesPtr);
+int initialize_xlib(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libX11.so.6", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// _Xmblen
+ *(void **) (&_Xmblen_dylibloader_wrapper_xlib) = dlsym(handle, "_Xmblen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLoadQueryFont
+ *(void **) (&XLoadQueryFont_dylibloader_wrapper_xlib) = dlsym(handle, "XLoadQueryFont");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryFont
+ *(void **) (&XQueryFont_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryFont");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetMotionEvents
+ *(void **) (&XGetMotionEvents_dylibloader_wrapper_xlib) = dlsym(handle, "XGetMotionEvents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDeleteModifiermapEntry
+ *(void **) (&XDeleteModifiermapEntry_dylibloader_wrapper_xlib) = dlsym(handle, "XDeleteModifiermapEntry");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetModifierMapping
+ *(void **) (&XGetModifierMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XGetModifierMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInsertModifiermapEntry
+ *(void **) (&XInsertModifiermapEntry_dylibloader_wrapper_xlib) = dlsym(handle, "XInsertModifiermapEntry");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XNewModifiermap
+ *(void **) (&XNewModifiermap_dylibloader_wrapper_xlib) = dlsym(handle, "XNewModifiermap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateImage
+ *(void **) (&XCreateImage_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInitImage
+ *(void **) (&XInitImage_dylibloader_wrapper_xlib) = dlsym(handle, "XInitImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetImage
+ *(void **) (&XGetImage_dylibloader_wrapper_xlib) = dlsym(handle, "XGetImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetSubImage
+ *(void **) (&XGetSubImage_dylibloader_wrapper_xlib) = dlsym(handle, "XGetSubImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XOpenDisplay
+ *(void **) (&XOpenDisplay_dylibloader_wrapper_xlib) = dlsym(handle, "XOpenDisplay");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XrmInitialize
+ *(void **) (&XrmInitialize_dylibloader_wrapper_xlib) = dlsym(handle, "XrmInitialize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFetchBytes
+ *(void **) (&XFetchBytes_dylibloader_wrapper_xlib) = dlsym(handle, "XFetchBytes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFetchBuffer
+ *(void **) (&XFetchBuffer_dylibloader_wrapper_xlib) = dlsym(handle, "XFetchBuffer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetAtomName
+ *(void **) (&XGetAtomName_dylibloader_wrapper_xlib) = dlsym(handle, "XGetAtomName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetAtomNames
+ *(void **) (&XGetAtomNames_dylibloader_wrapper_xlib) = dlsym(handle, "XGetAtomNames");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetDefault
+ *(void **) (&XGetDefault_dylibloader_wrapper_xlib) = dlsym(handle, "XGetDefault");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayName
+ *(void **) (&XDisplayName_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XKeysymToString
+ *(void **) (&XKeysymToString_dylibloader_wrapper_xlib) = dlsym(handle, "XKeysymToString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSynchronize
+ *(void **) (&XSynchronize_dylibloader_wrapper_xlib) = dlsym(handle, "XSynchronize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetAfterFunction
+ *(void **) (&XSetAfterFunction_dylibloader_wrapper_xlib) = dlsym(handle, "XSetAfterFunction");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInternAtom
+ *(void **) (&XInternAtom_dylibloader_wrapper_xlib) = dlsym(handle, "XInternAtom");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInternAtoms
+ *(void **) (&XInternAtoms_dylibloader_wrapper_xlib) = dlsym(handle, "XInternAtoms");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCopyColormapAndFree
+ *(void **) (&XCopyColormapAndFree_dylibloader_wrapper_xlib) = dlsym(handle, "XCopyColormapAndFree");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateColormap
+ *(void **) (&XCreateColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreatePixmapCursor
+ *(void **) (&XCreatePixmapCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XCreatePixmapCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateGlyphCursor
+ *(void **) (&XCreateGlyphCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateGlyphCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateFontCursor
+ *(void **) (&XCreateFontCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateFontCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLoadFont
+ *(void **) (&XLoadFont_dylibloader_wrapper_xlib) = dlsym(handle, "XLoadFont");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateGC
+ *(void **) (&XCreateGC_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateGC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGContextFromGC
+ *(void **) (&XGContextFromGC_dylibloader_wrapper_xlib) = dlsym(handle, "XGContextFromGC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFlushGC
+ *(void **) (&XFlushGC_dylibloader_wrapper_xlib) = dlsym(handle, "XFlushGC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreatePixmap
+ *(void **) (&XCreatePixmap_dylibloader_wrapper_xlib) = dlsym(handle, "XCreatePixmap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateBitmapFromData
+ *(void **) (&XCreateBitmapFromData_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateBitmapFromData");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreatePixmapFromBitmapData
+ *(void **) (&XCreatePixmapFromBitmapData_dylibloader_wrapper_xlib) = dlsym(handle, "XCreatePixmapFromBitmapData");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateSimpleWindow
+ *(void **) (&XCreateSimpleWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateSimpleWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetSelectionOwner
+ *(void **) (&XGetSelectionOwner_dylibloader_wrapper_xlib) = dlsym(handle, "XGetSelectionOwner");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateWindow
+ *(void **) (&XCreateWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListInstalledColormaps
+ *(void **) (&XListInstalledColormaps_dylibloader_wrapper_xlib) = dlsym(handle, "XListInstalledColormaps");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListFonts
+ *(void **) (&XListFonts_dylibloader_wrapper_xlib) = dlsym(handle, "XListFonts");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListFontsWithInfo
+ *(void **) (&XListFontsWithInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XListFontsWithInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetFontPath
+ *(void **) (&XGetFontPath_dylibloader_wrapper_xlib) = dlsym(handle, "XGetFontPath");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListExtensions
+ *(void **) (&XListExtensions_dylibloader_wrapper_xlib) = dlsym(handle, "XListExtensions");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListProperties
+ *(void **) (&XListProperties_dylibloader_wrapper_xlib) = dlsym(handle, "XListProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListHosts
+ *(void **) (&XListHosts_dylibloader_wrapper_xlib) = dlsym(handle, "XListHosts");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XKeycodeToKeysym
+ *(void **) (&XKeycodeToKeysym_dylibloader_wrapper_xlib) = dlsym(handle, "XKeycodeToKeysym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLookupKeysym
+ *(void **) (&XLookupKeysym_dylibloader_wrapper_xlib) = dlsym(handle, "XLookupKeysym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetKeyboardMapping
+ *(void **) (&XGetKeyboardMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XGetKeyboardMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStringToKeysym
+ *(void **) (&XStringToKeysym_dylibloader_wrapper_xlib) = dlsym(handle, "XStringToKeysym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMaxRequestSize
+ *(void **) (&XMaxRequestSize_dylibloader_wrapper_xlib) = dlsym(handle, "XMaxRequestSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XExtendedMaxRequestSize
+ *(void **) (&XExtendedMaxRequestSize_dylibloader_wrapper_xlib) = dlsym(handle, "XExtendedMaxRequestSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XResourceManagerString
+ *(void **) (&XResourceManagerString_dylibloader_wrapper_xlib) = dlsym(handle, "XResourceManagerString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XScreenResourceString
+ *(void **) (&XScreenResourceString_dylibloader_wrapper_xlib) = dlsym(handle, "XScreenResourceString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayMotionBufferSize
+ *(void **) (&XDisplayMotionBufferSize_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayMotionBufferSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XVisualIDFromVisual
+ *(void **) (&XVisualIDFromVisual_dylibloader_wrapper_xlib) = dlsym(handle, "XVisualIDFromVisual");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInitThreads
+ *(void **) (&XInitThreads_dylibloader_wrapper_xlib) = dlsym(handle, "XInitThreads");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLockDisplay
+ *(void **) (&XLockDisplay_dylibloader_wrapper_xlib) = dlsym(handle, "XLockDisplay");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnlockDisplay
+ *(void **) (&XUnlockDisplay_dylibloader_wrapper_xlib) = dlsym(handle, "XUnlockDisplay");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInitExtension
+ *(void **) (&XInitExtension_dylibloader_wrapper_xlib) = dlsym(handle, "XInitExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAddExtension
+ *(void **) (&XAddExtension_dylibloader_wrapper_xlib) = dlsym(handle, "XAddExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFindOnExtensionList
+ *(void **) (&XFindOnExtensionList_dylibloader_wrapper_xlib) = dlsym(handle, "XFindOnExtensionList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XEHeadOfExtensionList
+ *(void **) (&XEHeadOfExtensionList_dylibloader_wrapper_xlib) = dlsym(handle, "XEHeadOfExtensionList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRootWindow
+ *(void **) (&XRootWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XRootWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultRootWindow
+ *(void **) (&XDefaultRootWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultRootWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRootWindowOfScreen
+ *(void **) (&XRootWindowOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XRootWindowOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultVisual
+ *(void **) (&XDefaultVisual_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultVisual");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultVisualOfScreen
+ *(void **) (&XDefaultVisualOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultVisualOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultGC
+ *(void **) (&XDefaultGC_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultGC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultGCOfScreen
+ *(void **) (&XDefaultGCOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultGCOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XBlackPixel
+ *(void **) (&XBlackPixel_dylibloader_wrapper_xlib) = dlsym(handle, "XBlackPixel");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWhitePixel
+ *(void **) (&XWhitePixel_dylibloader_wrapper_xlib) = dlsym(handle, "XWhitePixel");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllPlanes
+ *(void **) (&XAllPlanes_dylibloader_wrapper_xlib) = dlsym(handle, "XAllPlanes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XBlackPixelOfScreen
+ *(void **) (&XBlackPixelOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XBlackPixelOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWhitePixelOfScreen
+ *(void **) (&XWhitePixelOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XWhitePixelOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XNextRequest
+ *(void **) (&XNextRequest_dylibloader_wrapper_xlib) = dlsym(handle, "XNextRequest");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLastKnownRequestProcessed
+ *(void **) (&XLastKnownRequestProcessed_dylibloader_wrapper_xlib) = dlsym(handle, "XLastKnownRequestProcessed");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XServerVendor
+ *(void **) (&XServerVendor_dylibloader_wrapper_xlib) = dlsym(handle, "XServerVendor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayString
+ *(void **) (&XDisplayString_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultColormap
+ *(void **) (&XDefaultColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultColormapOfScreen
+ *(void **) (&XDefaultColormapOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultColormapOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayOfScreen
+ *(void **) (&XDisplayOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XScreenOfDisplay
+ *(void **) (&XScreenOfDisplay_dylibloader_wrapper_xlib) = dlsym(handle, "XScreenOfDisplay");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultScreenOfDisplay
+ *(void **) (&XDefaultScreenOfDisplay_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultScreenOfDisplay");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XEventMaskOfScreen
+ *(void **) (&XEventMaskOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XEventMaskOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XScreenNumberOfScreen
+ *(void **) (&XScreenNumberOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XScreenNumberOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetErrorHandler
+ *(void **) (&XSetErrorHandler_dylibloader_wrapper_xlib) = dlsym(handle, "XSetErrorHandler");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetIOErrorHandler
+ *(void **) (&XSetIOErrorHandler_dylibloader_wrapper_xlib) = dlsym(handle, "XSetIOErrorHandler");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListPixmapFormats
+ *(void **) (&XListPixmapFormats_dylibloader_wrapper_xlib) = dlsym(handle, "XListPixmapFormats");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XListDepths
+ *(void **) (&XListDepths_dylibloader_wrapper_xlib) = dlsym(handle, "XListDepths");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XReconfigureWMWindow
+ *(void **) (&XReconfigureWMWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XReconfigureWMWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMProtocols
+ *(void **) (&XGetWMProtocols_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMProtocols");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMProtocols
+ *(void **) (&XSetWMProtocols_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMProtocols");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIconifyWindow
+ *(void **) (&XIconifyWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XIconifyWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWithdrawWindow
+ *(void **) (&XWithdrawWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XWithdrawWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetCommand
+ *(void **) (&XGetCommand_dylibloader_wrapper_xlib) = dlsym(handle, "XGetCommand");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMColormapWindows
+ *(void **) (&XGetWMColormapWindows_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMColormapWindows");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMColormapWindows
+ *(void **) (&XSetWMColormapWindows_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMColormapWindows");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeStringList
+ *(void **) (&XFreeStringList_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeStringList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetTransientForHint
+ *(void **) (&XSetTransientForHint_dylibloader_wrapper_xlib) = dlsym(handle, "XSetTransientForHint");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XActivateScreenSaver
+ *(void **) (&XActivateScreenSaver_dylibloader_wrapper_xlib) = dlsym(handle, "XActivateScreenSaver");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAddHost
+ *(void **) (&XAddHost_dylibloader_wrapper_xlib) = dlsym(handle, "XAddHost");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAddHosts
+ *(void **) (&XAddHosts_dylibloader_wrapper_xlib) = dlsym(handle, "XAddHosts");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAddToExtensionList
+ *(void **) (&XAddToExtensionList_dylibloader_wrapper_xlib) = dlsym(handle, "XAddToExtensionList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAddToSaveSet
+ *(void **) (&XAddToSaveSet_dylibloader_wrapper_xlib) = dlsym(handle, "XAddToSaveSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocColor
+ *(void **) (&XAllocColor_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocColorCells
+ *(void **) (&XAllocColorCells_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocColorCells");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocColorPlanes
+ *(void **) (&XAllocColorPlanes_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocColorPlanes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocNamedColor
+ *(void **) (&XAllocNamedColor_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocNamedColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllowEvents
+ *(void **) (&XAllowEvents_dylibloader_wrapper_xlib) = dlsym(handle, "XAllowEvents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAutoRepeatOff
+ *(void **) (&XAutoRepeatOff_dylibloader_wrapper_xlib) = dlsym(handle, "XAutoRepeatOff");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAutoRepeatOn
+ *(void **) (&XAutoRepeatOn_dylibloader_wrapper_xlib) = dlsym(handle, "XAutoRepeatOn");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XBell
+ *(void **) (&XBell_dylibloader_wrapper_xlib) = dlsym(handle, "XBell");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XBitmapBitOrder
+ *(void **) (&XBitmapBitOrder_dylibloader_wrapper_xlib) = dlsym(handle, "XBitmapBitOrder");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XBitmapPad
+ *(void **) (&XBitmapPad_dylibloader_wrapper_xlib) = dlsym(handle, "XBitmapPad");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XBitmapUnit
+ *(void **) (&XBitmapUnit_dylibloader_wrapper_xlib) = dlsym(handle, "XBitmapUnit");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCellsOfScreen
+ *(void **) (&XCellsOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XCellsOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangeActivePointerGrab
+ *(void **) (&XChangeActivePointerGrab_dylibloader_wrapper_xlib) = dlsym(handle, "XChangeActivePointerGrab");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangeGC
+ *(void **) (&XChangeGC_dylibloader_wrapper_xlib) = dlsym(handle, "XChangeGC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangeKeyboardControl
+ *(void **) (&XChangeKeyboardControl_dylibloader_wrapper_xlib) = dlsym(handle, "XChangeKeyboardControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangeKeyboardMapping
+ *(void **) (&XChangeKeyboardMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XChangeKeyboardMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangePointerControl
+ *(void **) (&XChangePointerControl_dylibloader_wrapper_xlib) = dlsym(handle, "XChangePointerControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangeProperty
+ *(void **) (&XChangeProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XChangeProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangeSaveSet
+ *(void **) (&XChangeSaveSet_dylibloader_wrapper_xlib) = dlsym(handle, "XChangeSaveSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XChangeWindowAttributes
+ *(void **) (&XChangeWindowAttributes_dylibloader_wrapper_xlib) = dlsym(handle, "XChangeWindowAttributes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCheckIfEvent
+ *(void **) (&XCheckIfEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XCheckIfEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCheckMaskEvent
+ *(void **) (&XCheckMaskEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XCheckMaskEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCheckTypedEvent
+ *(void **) (&XCheckTypedEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XCheckTypedEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCheckTypedWindowEvent
+ *(void **) (&XCheckTypedWindowEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XCheckTypedWindowEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCheckWindowEvent
+ *(void **) (&XCheckWindowEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XCheckWindowEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCirculateSubwindows
+ *(void **) (&XCirculateSubwindows_dylibloader_wrapper_xlib) = dlsym(handle, "XCirculateSubwindows");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCirculateSubwindowsDown
+ *(void **) (&XCirculateSubwindowsDown_dylibloader_wrapper_xlib) = dlsym(handle, "XCirculateSubwindowsDown");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCirculateSubwindowsUp
+ *(void **) (&XCirculateSubwindowsUp_dylibloader_wrapper_xlib) = dlsym(handle, "XCirculateSubwindowsUp");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XClearArea
+ *(void **) (&XClearArea_dylibloader_wrapper_xlib) = dlsym(handle, "XClearArea");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XClearWindow
+ *(void **) (&XClearWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XClearWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCloseDisplay
+ *(void **) (&XCloseDisplay_dylibloader_wrapper_xlib) = dlsym(handle, "XCloseDisplay");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XConfigureWindow
+ *(void **) (&XConfigureWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XConfigureWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XConnectionNumber
+ *(void **) (&XConnectionNumber_dylibloader_wrapper_xlib) = dlsym(handle, "XConnectionNumber");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XConvertSelection
+ *(void **) (&XConvertSelection_dylibloader_wrapper_xlib) = dlsym(handle, "XConvertSelection");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCopyArea
+ *(void **) (&XCopyArea_dylibloader_wrapper_xlib) = dlsym(handle, "XCopyArea");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCopyGC
+ *(void **) (&XCopyGC_dylibloader_wrapper_xlib) = dlsym(handle, "XCopyGC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCopyPlane
+ *(void **) (&XCopyPlane_dylibloader_wrapper_xlib) = dlsym(handle, "XCopyPlane");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultDepth
+ *(void **) (&XDefaultDepth_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultDepth");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultDepthOfScreen
+ *(void **) (&XDefaultDepthOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultDepthOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultScreen
+ *(void **) (&XDefaultScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefineCursor
+ *(void **) (&XDefineCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XDefineCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDeleteProperty
+ *(void **) (&XDeleteProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XDeleteProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDestroyWindow
+ *(void **) (&XDestroyWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XDestroyWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDestroySubwindows
+ *(void **) (&XDestroySubwindows_dylibloader_wrapper_xlib) = dlsym(handle, "XDestroySubwindows");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDoesBackingStore
+ *(void **) (&XDoesBackingStore_dylibloader_wrapper_xlib) = dlsym(handle, "XDoesBackingStore");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDoesSaveUnders
+ *(void **) (&XDoesSaveUnders_dylibloader_wrapper_xlib) = dlsym(handle, "XDoesSaveUnders");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisableAccessControl
+ *(void **) (&XDisableAccessControl_dylibloader_wrapper_xlib) = dlsym(handle, "XDisableAccessControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayCells
+ *(void **) (&XDisplayCells_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayCells");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayHeight
+ *(void **) (&XDisplayHeight_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayHeight");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayHeightMM
+ *(void **) (&XDisplayHeightMM_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayHeightMM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayKeycodes
+ *(void **) (&XDisplayKeycodes_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayKeycodes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayPlanes
+ *(void **) (&XDisplayPlanes_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayPlanes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayWidth
+ *(void **) (&XDisplayWidth_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayWidth");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayWidthMM
+ *(void **) (&XDisplayWidthMM_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayWidthMM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawArc
+ *(void **) (&XDrawArc_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawArc");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawArcs
+ *(void **) (&XDrawArcs_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawArcs");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawImageString
+ *(void **) (&XDrawImageString_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawImageString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawImageString16
+ *(void **) (&XDrawImageString16_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawImageString16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawLine
+ *(void **) (&XDrawLine_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawLine");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawLines
+ *(void **) (&XDrawLines_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawLines");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawPoint
+ *(void **) (&XDrawPoint_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawPoint");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawPoints
+ *(void **) (&XDrawPoints_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawPoints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawRectangle
+ *(void **) (&XDrawRectangle_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawRectangle");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawRectangles
+ *(void **) (&XDrawRectangles_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawRectangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawSegments
+ *(void **) (&XDrawSegments_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawSegments");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawString
+ *(void **) (&XDrawString_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawString16
+ *(void **) (&XDrawString16_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawString16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawText
+ *(void **) (&XDrawText_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawText");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDrawText16
+ *(void **) (&XDrawText16_dylibloader_wrapper_xlib) = dlsym(handle, "XDrawText16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XEnableAccessControl
+ *(void **) (&XEnableAccessControl_dylibloader_wrapper_xlib) = dlsym(handle, "XEnableAccessControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XEventsQueued
+ *(void **) (&XEventsQueued_dylibloader_wrapper_xlib) = dlsym(handle, "XEventsQueued");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFetchName
+ *(void **) (&XFetchName_dylibloader_wrapper_xlib) = dlsym(handle, "XFetchName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFillArc
+ *(void **) (&XFillArc_dylibloader_wrapper_xlib) = dlsym(handle, "XFillArc");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFillArcs
+ *(void **) (&XFillArcs_dylibloader_wrapper_xlib) = dlsym(handle, "XFillArcs");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFillPolygon
+ *(void **) (&XFillPolygon_dylibloader_wrapper_xlib) = dlsym(handle, "XFillPolygon");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFillRectangle
+ *(void **) (&XFillRectangle_dylibloader_wrapper_xlib) = dlsym(handle, "XFillRectangle");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFillRectangles
+ *(void **) (&XFillRectangles_dylibloader_wrapper_xlib) = dlsym(handle, "XFillRectangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFlush
+ *(void **) (&XFlush_dylibloader_wrapper_xlib) = dlsym(handle, "XFlush");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XForceScreenSaver
+ *(void **) (&XForceScreenSaver_dylibloader_wrapper_xlib) = dlsym(handle, "XForceScreenSaver");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFree
+ *(void **) (&XFree_dylibloader_wrapper_xlib) = dlsym(handle, "XFree");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeColormap
+ *(void **) (&XFreeColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeColors
+ *(void **) (&XFreeColors_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeColors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeCursor
+ *(void **) (&XFreeCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeExtensionList
+ *(void **) (&XFreeExtensionList_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeExtensionList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeFont
+ *(void **) (&XFreeFont_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeFont");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeFontInfo
+ *(void **) (&XFreeFontInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeFontInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeFontNames
+ *(void **) (&XFreeFontNames_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeFontNames");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeFontPath
+ *(void **) (&XFreeFontPath_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeFontPath");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeGC
+ *(void **) (&XFreeGC_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeGC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeModifiermap
+ *(void **) (&XFreeModifiermap_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeModifiermap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreePixmap
+ *(void **) (&XFreePixmap_dylibloader_wrapper_xlib) = dlsym(handle, "XFreePixmap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGeometry
+ *(void **) (&XGeometry_dylibloader_wrapper_xlib) = dlsym(handle, "XGeometry");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetErrorDatabaseText
+ *(void **) (&XGetErrorDatabaseText_dylibloader_wrapper_xlib) = dlsym(handle, "XGetErrorDatabaseText");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetErrorText
+ *(void **) (&XGetErrorText_dylibloader_wrapper_xlib) = dlsym(handle, "XGetErrorText");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetFontProperty
+ *(void **) (&XGetFontProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XGetFontProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetGCValues
+ *(void **) (&XGetGCValues_dylibloader_wrapper_xlib) = dlsym(handle, "XGetGCValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetGeometry
+ *(void **) (&XGetGeometry_dylibloader_wrapper_xlib) = dlsym(handle, "XGetGeometry");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetIconName
+ *(void **) (&XGetIconName_dylibloader_wrapper_xlib) = dlsym(handle, "XGetIconName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetInputFocus
+ *(void **) (&XGetInputFocus_dylibloader_wrapper_xlib) = dlsym(handle, "XGetInputFocus");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetKeyboardControl
+ *(void **) (&XGetKeyboardControl_dylibloader_wrapper_xlib) = dlsym(handle, "XGetKeyboardControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetPointerControl
+ *(void **) (&XGetPointerControl_dylibloader_wrapper_xlib) = dlsym(handle, "XGetPointerControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetPointerMapping
+ *(void **) (&XGetPointerMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XGetPointerMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetScreenSaver
+ *(void **) (&XGetScreenSaver_dylibloader_wrapper_xlib) = dlsym(handle, "XGetScreenSaver");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetTransientForHint
+ *(void **) (&XGetTransientForHint_dylibloader_wrapper_xlib) = dlsym(handle, "XGetTransientForHint");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWindowProperty
+ *(void **) (&XGetWindowProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWindowProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWindowAttributes
+ *(void **) (&XGetWindowAttributes_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWindowAttributes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGrabButton
+ *(void **) (&XGrabButton_dylibloader_wrapper_xlib) = dlsym(handle, "XGrabButton");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGrabKey
+ *(void **) (&XGrabKey_dylibloader_wrapper_xlib) = dlsym(handle, "XGrabKey");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGrabKeyboard
+ *(void **) (&XGrabKeyboard_dylibloader_wrapper_xlib) = dlsym(handle, "XGrabKeyboard");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGrabPointer
+ *(void **) (&XGrabPointer_dylibloader_wrapper_xlib) = dlsym(handle, "XGrabPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGrabServer
+ *(void **) (&XGrabServer_dylibloader_wrapper_xlib) = dlsym(handle, "XGrabServer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XHeightMMOfScreen
+ *(void **) (&XHeightMMOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XHeightMMOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XHeightOfScreen
+ *(void **) (&XHeightOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XHeightOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIfEvent
+ *(void **) (&XIfEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XIfEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XImageByteOrder
+ *(void **) (&XImageByteOrder_dylibloader_wrapper_xlib) = dlsym(handle, "XImageByteOrder");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInstallColormap
+ *(void **) (&XInstallColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XInstallColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XKeysymToKeycode
+ *(void **) (&XKeysymToKeycode_dylibloader_wrapper_xlib) = dlsym(handle, "XKeysymToKeycode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XKillClient
+ *(void **) (&XKillClient_dylibloader_wrapper_xlib) = dlsym(handle, "XKillClient");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLookupColor
+ *(void **) (&XLookupColor_dylibloader_wrapper_xlib) = dlsym(handle, "XLookupColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLowerWindow
+ *(void **) (&XLowerWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XLowerWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMapRaised
+ *(void **) (&XMapRaised_dylibloader_wrapper_xlib) = dlsym(handle, "XMapRaised");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMapSubwindows
+ *(void **) (&XMapSubwindows_dylibloader_wrapper_xlib) = dlsym(handle, "XMapSubwindows");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMapWindow
+ *(void **) (&XMapWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XMapWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMaskEvent
+ *(void **) (&XMaskEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XMaskEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMaxCmapsOfScreen
+ *(void **) (&XMaxCmapsOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XMaxCmapsOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMinCmapsOfScreen
+ *(void **) (&XMinCmapsOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XMinCmapsOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMoveResizeWindow
+ *(void **) (&XMoveResizeWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XMoveResizeWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMoveWindow
+ *(void **) (&XMoveWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XMoveWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XNextEvent
+ *(void **) (&XNextEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XNextEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XNoOp
+ *(void **) (&XNoOp_dylibloader_wrapper_xlib) = dlsym(handle, "XNoOp");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XParseColor
+ *(void **) (&XParseColor_dylibloader_wrapper_xlib) = dlsym(handle, "XParseColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XParseGeometry
+ *(void **) (&XParseGeometry_dylibloader_wrapper_xlib) = dlsym(handle, "XParseGeometry");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPeekEvent
+ *(void **) (&XPeekEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XPeekEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPeekIfEvent
+ *(void **) (&XPeekIfEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XPeekIfEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPending
+ *(void **) (&XPending_dylibloader_wrapper_xlib) = dlsym(handle, "XPending");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPlanesOfScreen
+ *(void **) (&XPlanesOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XPlanesOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XProtocolRevision
+ *(void **) (&XProtocolRevision_dylibloader_wrapper_xlib) = dlsym(handle, "XProtocolRevision");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XProtocolVersion
+ *(void **) (&XProtocolVersion_dylibloader_wrapper_xlib) = dlsym(handle, "XProtocolVersion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPutBackEvent
+ *(void **) (&XPutBackEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XPutBackEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPutImage
+ *(void **) (&XPutImage_dylibloader_wrapper_xlib) = dlsym(handle, "XPutImage");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQLength
+ *(void **) (&XQLength_dylibloader_wrapper_xlib) = dlsym(handle, "XQLength");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryBestCursor
+ *(void **) (&XQueryBestCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryBestCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryBestSize
+ *(void **) (&XQueryBestSize_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryBestSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryBestStipple
+ *(void **) (&XQueryBestStipple_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryBestStipple");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryBestTile
+ *(void **) (&XQueryBestTile_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryBestTile");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryColor
+ *(void **) (&XQueryColor_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryColors
+ *(void **) (&XQueryColors_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryColors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryExtension
+ *(void **) (&XQueryExtension_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryKeymap
+ *(void **) (&XQueryKeymap_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryKeymap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryPointer
+ *(void **) (&XQueryPointer_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryTextExtents
+ *(void **) (&XQueryTextExtents_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryTextExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryTextExtents16
+ *(void **) (&XQueryTextExtents16_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryTextExtents16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XQueryTree
+ *(void **) (&XQueryTree_dylibloader_wrapper_xlib) = dlsym(handle, "XQueryTree");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRaiseWindow
+ *(void **) (&XRaiseWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XRaiseWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XReadBitmapFile
+ *(void **) (&XReadBitmapFile_dylibloader_wrapper_xlib) = dlsym(handle, "XReadBitmapFile");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XReadBitmapFileData
+ *(void **) (&XReadBitmapFileData_dylibloader_wrapper_xlib) = dlsym(handle, "XReadBitmapFileData");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRebindKeysym
+ *(void **) (&XRebindKeysym_dylibloader_wrapper_xlib) = dlsym(handle, "XRebindKeysym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRecolorCursor
+ *(void **) (&XRecolorCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XRecolorCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRefreshKeyboardMapping
+ *(void **) (&XRefreshKeyboardMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XRefreshKeyboardMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRemoveFromSaveSet
+ *(void **) (&XRemoveFromSaveSet_dylibloader_wrapper_xlib) = dlsym(handle, "XRemoveFromSaveSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRemoveHost
+ *(void **) (&XRemoveHost_dylibloader_wrapper_xlib) = dlsym(handle, "XRemoveHost");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRemoveHosts
+ *(void **) (&XRemoveHosts_dylibloader_wrapper_xlib) = dlsym(handle, "XRemoveHosts");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XReparentWindow
+ *(void **) (&XReparentWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XReparentWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XResetScreenSaver
+ *(void **) (&XResetScreenSaver_dylibloader_wrapper_xlib) = dlsym(handle, "XResetScreenSaver");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XResizeWindow
+ *(void **) (&XResizeWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XResizeWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRestackWindows
+ *(void **) (&XRestackWindows_dylibloader_wrapper_xlib) = dlsym(handle, "XRestackWindows");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRotateBuffers
+ *(void **) (&XRotateBuffers_dylibloader_wrapper_xlib) = dlsym(handle, "XRotateBuffers");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRotateWindowProperties
+ *(void **) (&XRotateWindowProperties_dylibloader_wrapper_xlib) = dlsym(handle, "XRotateWindowProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XScreenCount
+ *(void **) (&XScreenCount_dylibloader_wrapper_xlib) = dlsym(handle, "XScreenCount");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSelectInput
+ *(void **) (&XSelectInput_dylibloader_wrapper_xlib) = dlsym(handle, "XSelectInput");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSendEvent
+ *(void **) (&XSendEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XSendEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetAccessControl
+ *(void **) (&XSetAccessControl_dylibloader_wrapper_xlib) = dlsym(handle, "XSetAccessControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetArcMode
+ *(void **) (&XSetArcMode_dylibloader_wrapper_xlib) = dlsym(handle, "XSetArcMode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetBackground
+ *(void **) (&XSetBackground_dylibloader_wrapper_xlib) = dlsym(handle, "XSetBackground");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetClipMask
+ *(void **) (&XSetClipMask_dylibloader_wrapper_xlib) = dlsym(handle, "XSetClipMask");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetClipOrigin
+ *(void **) (&XSetClipOrigin_dylibloader_wrapper_xlib) = dlsym(handle, "XSetClipOrigin");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetClipRectangles
+ *(void **) (&XSetClipRectangles_dylibloader_wrapper_xlib) = dlsym(handle, "XSetClipRectangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetCloseDownMode
+ *(void **) (&XSetCloseDownMode_dylibloader_wrapper_xlib) = dlsym(handle, "XSetCloseDownMode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetCommand
+ *(void **) (&XSetCommand_dylibloader_wrapper_xlib) = dlsym(handle, "XSetCommand");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetDashes
+ *(void **) (&XSetDashes_dylibloader_wrapper_xlib) = dlsym(handle, "XSetDashes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetFillRule
+ *(void **) (&XSetFillRule_dylibloader_wrapper_xlib) = dlsym(handle, "XSetFillRule");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetFillStyle
+ *(void **) (&XSetFillStyle_dylibloader_wrapper_xlib) = dlsym(handle, "XSetFillStyle");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetFont
+ *(void **) (&XSetFont_dylibloader_wrapper_xlib) = dlsym(handle, "XSetFont");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetFontPath
+ *(void **) (&XSetFontPath_dylibloader_wrapper_xlib) = dlsym(handle, "XSetFontPath");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetForeground
+ *(void **) (&XSetForeground_dylibloader_wrapper_xlib) = dlsym(handle, "XSetForeground");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetFunction
+ *(void **) (&XSetFunction_dylibloader_wrapper_xlib) = dlsym(handle, "XSetFunction");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetGraphicsExposures
+ *(void **) (&XSetGraphicsExposures_dylibloader_wrapper_xlib) = dlsym(handle, "XSetGraphicsExposures");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetIconName
+ *(void **) (&XSetIconName_dylibloader_wrapper_xlib) = dlsym(handle, "XSetIconName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetInputFocus
+ *(void **) (&XSetInputFocus_dylibloader_wrapper_xlib) = dlsym(handle, "XSetInputFocus");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetLineAttributes
+ *(void **) (&XSetLineAttributes_dylibloader_wrapper_xlib) = dlsym(handle, "XSetLineAttributes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetModifierMapping
+ *(void **) (&XSetModifierMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XSetModifierMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetPlaneMask
+ *(void **) (&XSetPlaneMask_dylibloader_wrapper_xlib) = dlsym(handle, "XSetPlaneMask");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetPointerMapping
+ *(void **) (&XSetPointerMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XSetPointerMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetScreenSaver
+ *(void **) (&XSetScreenSaver_dylibloader_wrapper_xlib) = dlsym(handle, "XSetScreenSaver");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetSelectionOwner
+ *(void **) (&XSetSelectionOwner_dylibloader_wrapper_xlib) = dlsym(handle, "XSetSelectionOwner");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetState
+ *(void **) (&XSetState_dylibloader_wrapper_xlib) = dlsym(handle, "XSetState");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetStipple
+ *(void **) (&XSetStipple_dylibloader_wrapper_xlib) = dlsym(handle, "XSetStipple");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetSubwindowMode
+ *(void **) (&XSetSubwindowMode_dylibloader_wrapper_xlib) = dlsym(handle, "XSetSubwindowMode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetTSOrigin
+ *(void **) (&XSetTSOrigin_dylibloader_wrapper_xlib) = dlsym(handle, "XSetTSOrigin");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetTile
+ *(void **) (&XSetTile_dylibloader_wrapper_xlib) = dlsym(handle, "XSetTile");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWindowBackground
+ *(void **) (&XSetWindowBackground_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWindowBackground");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWindowBackgroundPixmap
+ *(void **) (&XSetWindowBackgroundPixmap_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWindowBackgroundPixmap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWindowBorder
+ *(void **) (&XSetWindowBorder_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWindowBorder");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWindowBorderPixmap
+ *(void **) (&XSetWindowBorderPixmap_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWindowBorderPixmap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWindowBorderWidth
+ *(void **) (&XSetWindowBorderWidth_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWindowBorderWidth");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWindowColormap
+ *(void **) (&XSetWindowColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWindowColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStoreBuffer
+ *(void **) (&XStoreBuffer_dylibloader_wrapper_xlib) = dlsym(handle, "XStoreBuffer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStoreBytes
+ *(void **) (&XStoreBytes_dylibloader_wrapper_xlib) = dlsym(handle, "XStoreBytes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStoreColor
+ *(void **) (&XStoreColor_dylibloader_wrapper_xlib) = dlsym(handle, "XStoreColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStoreColors
+ *(void **) (&XStoreColors_dylibloader_wrapper_xlib) = dlsym(handle, "XStoreColors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStoreName
+ *(void **) (&XStoreName_dylibloader_wrapper_xlib) = dlsym(handle, "XStoreName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStoreNamedColor
+ *(void **) (&XStoreNamedColor_dylibloader_wrapper_xlib) = dlsym(handle, "XStoreNamedColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSync
+ *(void **) (&XSync_dylibloader_wrapper_xlib) = dlsym(handle, "XSync");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XTextExtents
+ *(void **) (&XTextExtents_dylibloader_wrapper_xlib) = dlsym(handle, "XTextExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XTextExtents16
+ *(void **) (&XTextExtents16_dylibloader_wrapper_xlib) = dlsym(handle, "XTextExtents16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XTextWidth
+ *(void **) (&XTextWidth_dylibloader_wrapper_xlib) = dlsym(handle, "XTextWidth");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XTextWidth16
+ *(void **) (&XTextWidth16_dylibloader_wrapper_xlib) = dlsym(handle, "XTextWidth16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XTranslateCoordinates
+ *(void **) (&XTranslateCoordinates_dylibloader_wrapper_xlib) = dlsym(handle, "XTranslateCoordinates");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUndefineCursor
+ *(void **) (&XUndefineCursor_dylibloader_wrapper_xlib) = dlsym(handle, "XUndefineCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUngrabButton
+ *(void **) (&XUngrabButton_dylibloader_wrapper_xlib) = dlsym(handle, "XUngrabButton");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUngrabKey
+ *(void **) (&XUngrabKey_dylibloader_wrapper_xlib) = dlsym(handle, "XUngrabKey");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUngrabKeyboard
+ *(void **) (&XUngrabKeyboard_dylibloader_wrapper_xlib) = dlsym(handle, "XUngrabKeyboard");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUngrabPointer
+ *(void **) (&XUngrabPointer_dylibloader_wrapper_xlib) = dlsym(handle, "XUngrabPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUngrabServer
+ *(void **) (&XUngrabServer_dylibloader_wrapper_xlib) = dlsym(handle, "XUngrabServer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUninstallColormap
+ *(void **) (&XUninstallColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XUninstallColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnloadFont
+ *(void **) (&XUnloadFont_dylibloader_wrapper_xlib) = dlsym(handle, "XUnloadFont");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnmapSubwindows
+ *(void **) (&XUnmapSubwindows_dylibloader_wrapper_xlib) = dlsym(handle, "XUnmapSubwindows");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnmapWindow
+ *(void **) (&XUnmapWindow_dylibloader_wrapper_xlib) = dlsym(handle, "XUnmapWindow");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XVendorRelease
+ *(void **) (&XVendorRelease_dylibloader_wrapper_xlib) = dlsym(handle, "XVendorRelease");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWarpPointer
+ *(void **) (&XWarpPointer_dylibloader_wrapper_xlib) = dlsym(handle, "XWarpPointer");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWidthMMOfScreen
+ *(void **) (&XWidthMMOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XWidthMMOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWidthOfScreen
+ *(void **) (&XWidthOfScreen_dylibloader_wrapper_xlib) = dlsym(handle, "XWidthOfScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWindowEvent
+ *(void **) (&XWindowEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XWindowEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWriteBitmapFile
+ *(void **) (&XWriteBitmapFile_dylibloader_wrapper_xlib) = dlsym(handle, "XWriteBitmapFile");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSupportsLocale
+ *(void **) (&XSupportsLocale_dylibloader_wrapper_xlib) = dlsym(handle, "XSupportsLocale");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetLocaleModifiers
+ *(void **) (&XSetLocaleModifiers_dylibloader_wrapper_xlib) = dlsym(handle, "XSetLocaleModifiers");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XOpenOM
+ *(void **) (&XOpenOM_dylibloader_wrapper_xlib) = dlsym(handle, "XOpenOM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCloseOM
+ *(void **) (&XCloseOM_dylibloader_wrapper_xlib) = dlsym(handle, "XCloseOM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetOMValues
+ *(void **) (&XSetOMValues_dylibloader_wrapper_xlib) = dlsym(handle, "XSetOMValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetOMValues
+ *(void **) (&XGetOMValues_dylibloader_wrapper_xlib) = dlsym(handle, "XGetOMValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayOfOM
+ *(void **) (&XDisplayOfOM_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayOfOM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLocaleOfOM
+ *(void **) (&XLocaleOfOM_dylibloader_wrapper_xlib) = dlsym(handle, "XLocaleOfOM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateOC
+ *(void **) (&XCreateOC_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateOC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDestroyOC
+ *(void **) (&XDestroyOC_dylibloader_wrapper_xlib) = dlsym(handle, "XDestroyOC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XOMOfOC
+ *(void **) (&XOMOfOC_dylibloader_wrapper_xlib) = dlsym(handle, "XOMOfOC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetOCValues
+ *(void **) (&XSetOCValues_dylibloader_wrapper_xlib) = dlsym(handle, "XSetOCValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetOCValues
+ *(void **) (&XGetOCValues_dylibloader_wrapper_xlib) = dlsym(handle, "XGetOCValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateFontSet
+ *(void **) (&XCreateFontSet_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateFontSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeFontSet
+ *(void **) (&XFreeFontSet_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeFontSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFontsOfFontSet
+ *(void **) (&XFontsOfFontSet_dylibloader_wrapper_xlib) = dlsym(handle, "XFontsOfFontSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XBaseFontNameListOfFontSet
+ *(void **) (&XBaseFontNameListOfFontSet_dylibloader_wrapper_xlib) = dlsym(handle, "XBaseFontNameListOfFontSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLocaleOfFontSet
+ *(void **) (&XLocaleOfFontSet_dylibloader_wrapper_xlib) = dlsym(handle, "XLocaleOfFontSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XContextDependentDrawing
+ *(void **) (&XContextDependentDrawing_dylibloader_wrapper_xlib) = dlsym(handle, "XContextDependentDrawing");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDirectionalDependentDrawing
+ *(void **) (&XDirectionalDependentDrawing_dylibloader_wrapper_xlib) = dlsym(handle, "XDirectionalDependentDrawing");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XContextualDrawing
+ *(void **) (&XContextualDrawing_dylibloader_wrapper_xlib) = dlsym(handle, "XContextualDrawing");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XExtentsOfFontSet
+ *(void **) (&XExtentsOfFontSet_dylibloader_wrapper_xlib) = dlsym(handle, "XExtentsOfFontSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbTextEscapement
+ *(void **) (&XmbTextEscapement_dylibloader_wrapper_xlib) = dlsym(handle, "XmbTextEscapement");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcTextEscapement
+ *(void **) (&XwcTextEscapement_dylibloader_wrapper_xlib) = dlsym(handle, "XwcTextEscapement");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8TextEscapement
+ *(void **) (&Xutf8TextEscapement_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8TextEscapement");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbTextExtents
+ *(void **) (&XmbTextExtents_dylibloader_wrapper_xlib) = dlsym(handle, "XmbTextExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcTextExtents
+ *(void **) (&XwcTextExtents_dylibloader_wrapper_xlib) = dlsym(handle, "XwcTextExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8TextExtents
+ *(void **) (&Xutf8TextExtents_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8TextExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbTextPerCharExtents
+ *(void **) (&XmbTextPerCharExtents_dylibloader_wrapper_xlib) = dlsym(handle, "XmbTextPerCharExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcTextPerCharExtents
+ *(void **) (&XwcTextPerCharExtents_dylibloader_wrapper_xlib) = dlsym(handle, "XwcTextPerCharExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8TextPerCharExtents
+ *(void **) (&Xutf8TextPerCharExtents_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8TextPerCharExtents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbDrawText
+ *(void **) (&XmbDrawText_dylibloader_wrapper_xlib) = dlsym(handle, "XmbDrawText");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcDrawText
+ *(void **) (&XwcDrawText_dylibloader_wrapper_xlib) = dlsym(handle, "XwcDrawText");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8DrawText
+ *(void **) (&Xutf8DrawText_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8DrawText");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbDrawString
+ *(void **) (&XmbDrawString_dylibloader_wrapper_xlib) = dlsym(handle, "XmbDrawString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcDrawString
+ *(void **) (&XwcDrawString_dylibloader_wrapper_xlib) = dlsym(handle, "XwcDrawString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8DrawString
+ *(void **) (&Xutf8DrawString_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8DrawString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbDrawImageString
+ *(void **) (&XmbDrawImageString_dylibloader_wrapper_xlib) = dlsym(handle, "XmbDrawImageString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcDrawImageString
+ *(void **) (&XwcDrawImageString_dylibloader_wrapper_xlib) = dlsym(handle, "XwcDrawImageString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8DrawImageString
+ *(void **) (&Xutf8DrawImageString_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8DrawImageString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XOpenIM
+ *(void **) (&XOpenIM_dylibloader_wrapper_xlib) = dlsym(handle, "XOpenIM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCloseIM
+ *(void **) (&XCloseIM_dylibloader_wrapper_xlib) = dlsym(handle, "XCloseIM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetIMValues
+ *(void **) (&XGetIMValues_dylibloader_wrapper_xlib) = dlsym(handle, "XGetIMValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetIMValues
+ *(void **) (&XSetIMValues_dylibloader_wrapper_xlib) = dlsym(handle, "XSetIMValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDisplayOfIM
+ *(void **) (&XDisplayOfIM_dylibloader_wrapper_xlib) = dlsym(handle, "XDisplayOfIM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLocaleOfIM
+ *(void **) (&XLocaleOfIM_dylibloader_wrapper_xlib) = dlsym(handle, "XLocaleOfIM");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateIC
+ *(void **) (&XCreateIC_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateIC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDestroyIC
+ *(void **) (&XDestroyIC_dylibloader_wrapper_xlib) = dlsym(handle, "XDestroyIC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetICFocus
+ *(void **) (&XSetICFocus_dylibloader_wrapper_xlib) = dlsym(handle, "XSetICFocus");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnsetICFocus
+ *(void **) (&XUnsetICFocus_dylibloader_wrapper_xlib) = dlsym(handle, "XUnsetICFocus");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcResetIC
+ *(void **) (&XwcResetIC_dylibloader_wrapper_xlib) = dlsym(handle, "XwcResetIC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbResetIC
+ *(void **) (&XmbResetIC_dylibloader_wrapper_xlib) = dlsym(handle, "XmbResetIC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8ResetIC
+ *(void **) (&Xutf8ResetIC_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8ResetIC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetICValues
+ *(void **) (&XSetICValues_dylibloader_wrapper_xlib) = dlsym(handle, "XSetICValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetICValues
+ *(void **) (&XGetICValues_dylibloader_wrapper_xlib) = dlsym(handle, "XGetICValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIMOfIC
+ *(void **) (&XIMOfIC_dylibloader_wrapper_xlib) = dlsym(handle, "XIMOfIC");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFilterEvent
+ *(void **) (&XFilterEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XFilterEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbLookupString
+ *(void **) (&XmbLookupString_dylibloader_wrapper_xlib) = dlsym(handle, "XmbLookupString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcLookupString
+ *(void **) (&XwcLookupString_dylibloader_wrapper_xlib) = dlsym(handle, "XwcLookupString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8LookupString
+ *(void **) (&Xutf8LookupString_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8LookupString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XVaCreateNestedList
+ *(void **) (&XVaCreateNestedList_dylibloader_wrapper_xlib) = dlsym(handle, "XVaCreateNestedList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRegisterIMInstantiateCallback
+ *(void **) (&XRegisterIMInstantiateCallback_dylibloader_wrapper_xlib) = dlsym(handle, "XRegisterIMInstantiateCallback");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnregisterIMInstantiateCallback
+ *(void **) (&XUnregisterIMInstantiateCallback_dylibloader_wrapper_xlib) = dlsym(handle, "XUnregisterIMInstantiateCallback");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XInternalConnectionNumbers
+ *(void **) (&XInternalConnectionNumbers_dylibloader_wrapper_xlib) = dlsym(handle, "XInternalConnectionNumbers");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XProcessInternalConnection
+ *(void **) (&XProcessInternalConnection_dylibloader_wrapper_xlib) = dlsym(handle, "XProcessInternalConnection");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAddConnectionWatch
+ *(void **) (&XAddConnectionWatch_dylibloader_wrapper_xlib) = dlsym(handle, "XAddConnectionWatch");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRemoveConnectionWatch
+ *(void **) (&XRemoveConnectionWatch_dylibloader_wrapper_xlib) = dlsym(handle, "XRemoveConnectionWatch");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetAuthorization
+ *(void **) (&XSetAuthorization_dylibloader_wrapper_xlib) = dlsym(handle, "XSetAuthorization");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// _Xmbtowc
+ *(void **) (&_Xmbtowc_dylibloader_wrapper_xlib) = dlsym(handle, "_Xmbtowc");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// _Xwctomb
+ *(void **) (&_Xwctomb_dylibloader_wrapper_xlib) = dlsym(handle, "_Xwctomb");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetEventData
+ *(void **) (&XGetEventData_dylibloader_wrapper_xlib) = dlsym(handle, "XGetEventData");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFreeEventData
+ *(void **) (&XFreeEventData_dylibloader_wrapper_xlib) = dlsym(handle, "XFreeEventData");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocClassHint
+ *(void **) (&XAllocClassHint_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocClassHint");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocIconSize
+ *(void **) (&XAllocIconSize_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocIconSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocSizeHints
+ *(void **) (&XAllocSizeHints_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocSizeHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocStandardColormap
+ *(void **) (&XAllocStandardColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocStandardColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XAllocWMHints
+ *(void **) (&XAllocWMHints_dylibloader_wrapper_xlib) = dlsym(handle, "XAllocWMHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XClipBox
+ *(void **) (&XClipBox_dylibloader_wrapper_xlib) = dlsym(handle, "XClipBox");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XCreateRegion
+ *(void **) (&XCreateRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XCreateRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDefaultString
+ *(void **) (&XDefaultString_dylibloader_wrapper_xlib) = dlsym(handle, "XDefaultString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDeleteContext
+ *(void **) (&XDeleteContext_dylibloader_wrapper_xlib) = dlsym(handle, "XDeleteContext");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XDestroyRegion
+ *(void **) (&XDestroyRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XDestroyRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XEmptyRegion
+ *(void **) (&XEmptyRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XEmptyRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XEqualRegion
+ *(void **) (&XEqualRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XEqualRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XFindContext
+ *(void **) (&XFindContext_dylibloader_wrapper_xlib) = dlsym(handle, "XFindContext");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetClassHint
+ *(void **) (&XGetClassHint_dylibloader_wrapper_xlib) = dlsym(handle, "XGetClassHint");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetIconSizes
+ *(void **) (&XGetIconSizes_dylibloader_wrapper_xlib) = dlsym(handle, "XGetIconSizes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetNormalHints
+ *(void **) (&XGetNormalHints_dylibloader_wrapper_xlib) = dlsym(handle, "XGetNormalHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetRGBColormaps
+ *(void **) (&XGetRGBColormaps_dylibloader_wrapper_xlib) = dlsym(handle, "XGetRGBColormaps");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetSizeHints
+ *(void **) (&XGetSizeHints_dylibloader_wrapper_xlib) = dlsym(handle, "XGetSizeHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetStandardColormap
+ *(void **) (&XGetStandardColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XGetStandardColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetTextProperty
+ *(void **) (&XGetTextProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XGetTextProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetVisualInfo
+ *(void **) (&XGetVisualInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XGetVisualInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMClientMachine
+ *(void **) (&XGetWMClientMachine_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMClientMachine");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMHints
+ *(void **) (&XGetWMHints_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMIconName
+ *(void **) (&XGetWMIconName_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMIconName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMName
+ *(void **) (&XGetWMName_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMNormalHints
+ *(void **) (&XGetWMNormalHints_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMNormalHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetWMSizeHints
+ *(void **) (&XGetWMSizeHints_dylibloader_wrapper_xlib) = dlsym(handle, "XGetWMSizeHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XGetZoomHints
+ *(void **) (&XGetZoomHints_dylibloader_wrapper_xlib) = dlsym(handle, "XGetZoomHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XIntersectRegion
+ *(void **) (&XIntersectRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XIntersectRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XConvertCase
+ *(void **) (&XConvertCase_dylibloader_wrapper_xlib) = dlsym(handle, "XConvertCase");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XLookupString
+ *(void **) (&XLookupString_dylibloader_wrapper_xlib) = dlsym(handle, "XLookupString");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XMatchVisualInfo
+ *(void **) (&XMatchVisualInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XMatchVisualInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XOffsetRegion
+ *(void **) (&XOffsetRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XOffsetRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPointInRegion
+ *(void **) (&XPointInRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XPointInRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XPolygonRegion
+ *(void **) (&XPolygonRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XPolygonRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRectInRegion
+ *(void **) (&XRectInRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XRectInRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSaveContext
+ *(void **) (&XSaveContext_dylibloader_wrapper_xlib) = dlsym(handle, "XSaveContext");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetClassHint
+ *(void **) (&XSetClassHint_dylibloader_wrapper_xlib) = dlsym(handle, "XSetClassHint");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetIconSizes
+ *(void **) (&XSetIconSizes_dylibloader_wrapper_xlib) = dlsym(handle, "XSetIconSizes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetNormalHints
+ *(void **) (&XSetNormalHints_dylibloader_wrapper_xlib) = dlsym(handle, "XSetNormalHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetRGBColormaps
+ *(void **) (&XSetRGBColormaps_dylibloader_wrapper_xlib) = dlsym(handle, "XSetRGBColormaps");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetSizeHints
+ *(void **) (&XSetSizeHints_dylibloader_wrapper_xlib) = dlsym(handle, "XSetSizeHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetStandardProperties
+ *(void **) (&XSetStandardProperties_dylibloader_wrapper_xlib) = dlsym(handle, "XSetStandardProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetTextProperty
+ *(void **) (&XSetTextProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XSetTextProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMClientMachine
+ *(void **) (&XSetWMClientMachine_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMClientMachine");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMHints
+ *(void **) (&XSetWMHints_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMIconName
+ *(void **) (&XSetWMIconName_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMIconName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMName
+ *(void **) (&XSetWMName_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMNormalHints
+ *(void **) (&XSetWMNormalHints_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMNormalHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMProperties
+ *(void **) (&XSetWMProperties_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbSetWMProperties
+ *(void **) (&XmbSetWMProperties_dylibloader_wrapper_xlib) = dlsym(handle, "XmbSetWMProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8SetWMProperties
+ *(void **) (&Xutf8SetWMProperties_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8SetWMProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetWMSizeHints
+ *(void **) (&XSetWMSizeHints_dylibloader_wrapper_xlib) = dlsym(handle, "XSetWMSizeHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetRegion
+ *(void **) (&XSetRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XSetRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetStandardColormap
+ *(void **) (&XSetStandardColormap_dylibloader_wrapper_xlib) = dlsym(handle, "XSetStandardColormap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSetZoomHints
+ *(void **) (&XSetZoomHints_dylibloader_wrapper_xlib) = dlsym(handle, "XSetZoomHints");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XShrinkRegion
+ *(void **) (&XShrinkRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XShrinkRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XStringListToTextProperty
+ *(void **) (&XStringListToTextProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XStringListToTextProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XSubtractRegion
+ *(void **) (&XSubtractRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XSubtractRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbTextListToTextProperty
+ *(void **) (&XmbTextListToTextProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XmbTextListToTextProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcTextListToTextProperty
+ *(void **) (&XwcTextListToTextProperty_dylibloader_wrapper_xlib) = dlsym(handle, "XwcTextListToTextProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8TextListToTextProperty
+ *(void **) (&Xutf8TextListToTextProperty_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8TextListToTextProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcFreeStringList
+ *(void **) (&XwcFreeStringList_dylibloader_wrapper_xlib) = dlsym(handle, "XwcFreeStringList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XTextPropertyToStringList
+ *(void **) (&XTextPropertyToStringList_dylibloader_wrapper_xlib) = dlsym(handle, "XTextPropertyToStringList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XmbTextPropertyToTextList
+ *(void **) (&XmbTextPropertyToTextList_dylibloader_wrapper_xlib) = dlsym(handle, "XmbTextPropertyToTextList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XwcTextPropertyToTextList
+ *(void **) (&XwcTextPropertyToTextList_dylibloader_wrapper_xlib) = dlsym(handle, "XwcTextPropertyToTextList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// Xutf8TextPropertyToTextList
+ *(void **) (&Xutf8TextPropertyToTextList_dylibloader_wrapper_xlib) = dlsym(handle, "Xutf8TextPropertyToTextList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnionRectWithRegion
+ *(void **) (&XUnionRectWithRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XUnionRectWithRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XUnionRegion
+ *(void **) (&XUnionRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XUnionRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XWMGeometry
+ *(void **) (&XWMGeometry_dylibloader_wrapper_xlib) = dlsym(handle, "XWMGeometry");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XXorRegion
+ *(void **) (&XXorRegion_dylibloader_wrapper_xlib) = dlsym(handle, "XXorRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbIgnoreExtension
+ *(void **) (&XkbIgnoreExtension_dylibloader_wrapper_xlib) = dlsym(handle, "XkbIgnoreExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbOpenDisplay
+ *(void **) (&XkbOpenDisplay_dylibloader_wrapper_xlib) = dlsym(handle, "XkbOpenDisplay");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbQueryExtension
+ *(void **) (&XkbQueryExtension_dylibloader_wrapper_xlib) = dlsym(handle, "XkbQueryExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbUseExtension
+ *(void **) (&XkbUseExtension_dylibloader_wrapper_xlib) = dlsym(handle, "XkbUseExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbLibraryVersion
+ *(void **) (&XkbLibraryVersion_dylibloader_wrapper_xlib) = dlsym(handle, "XkbLibraryVersion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetXlibControls
+ *(void **) (&XkbSetXlibControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetXlibControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetXlibControls
+ *(void **) (&XkbGetXlibControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetXlibControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbXlibControlsImplemented
+ *(void **) (&XkbXlibControlsImplemented_dylibloader_wrapper_xlib) = dlsym(handle, "XkbXlibControlsImplemented");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetAtomFuncs
+ *(void **) (&XkbSetAtomFuncs_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetAtomFuncs");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbKeycodeToKeysym
+ *(void **) (&XkbKeycodeToKeysym_dylibloader_wrapper_xlib) = dlsym(handle, "XkbKeycodeToKeysym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbKeysymToModifiers
+ *(void **) (&XkbKeysymToModifiers_dylibloader_wrapper_xlib) = dlsym(handle, "XkbKeysymToModifiers");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbLookupKeySym
+ *(void **) (&XkbLookupKeySym_dylibloader_wrapper_xlib) = dlsym(handle, "XkbLookupKeySym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbLookupKeyBinding
+ *(void **) (&XkbLookupKeyBinding_dylibloader_wrapper_xlib) = dlsym(handle, "XkbLookupKeyBinding");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbTranslateKeyCode
+ *(void **) (&XkbTranslateKeyCode_dylibloader_wrapper_xlib) = dlsym(handle, "XkbTranslateKeyCode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbTranslateKeySym
+ *(void **) (&XkbTranslateKeySym_dylibloader_wrapper_xlib) = dlsym(handle, "XkbTranslateKeySym");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetAutoRepeatRate
+ *(void **) (&XkbSetAutoRepeatRate_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetAutoRepeatRate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetAutoRepeatRate
+ *(void **) (&XkbGetAutoRepeatRate_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetAutoRepeatRate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbChangeEnabledControls
+ *(void **) (&XkbChangeEnabledControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbChangeEnabledControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbDeviceBell
+ *(void **) (&XkbDeviceBell_dylibloader_wrapper_xlib) = dlsym(handle, "XkbDeviceBell");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbForceDeviceBell
+ *(void **) (&XkbForceDeviceBell_dylibloader_wrapper_xlib) = dlsym(handle, "XkbForceDeviceBell");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbDeviceBellEvent
+ *(void **) (&XkbDeviceBellEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XkbDeviceBellEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbBell
+ *(void **) (&XkbBell_dylibloader_wrapper_xlib) = dlsym(handle, "XkbBell");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbForceBell
+ *(void **) (&XkbForceBell_dylibloader_wrapper_xlib) = dlsym(handle, "XkbForceBell");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbBellEvent
+ *(void **) (&XkbBellEvent_dylibloader_wrapper_xlib) = dlsym(handle, "XkbBellEvent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSelectEvents
+ *(void **) (&XkbSelectEvents_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSelectEvents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSelectEventDetails
+ *(void **) (&XkbSelectEventDetails_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSelectEventDetails");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbNoteMapChanges
+ *(void **) (&XkbNoteMapChanges_dylibloader_wrapper_xlib) = dlsym(handle, "XkbNoteMapChanges");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbNoteNameChanges
+ *(void **) (&XkbNoteNameChanges_dylibloader_wrapper_xlib) = dlsym(handle, "XkbNoteNameChanges");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetIndicatorState
+ *(void **) (&XkbGetIndicatorState_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetIndicatorState");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetIndicatorMap
+ *(void **) (&XkbGetIndicatorMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetIndicatorMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetIndicatorMap
+ *(void **) (&XkbSetIndicatorMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetIndicatorMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetNamedIndicator
+ *(void **) (&XkbGetNamedIndicator_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetNamedIndicator");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetNamedDeviceIndicator
+ *(void **) (&XkbGetNamedDeviceIndicator_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetNamedDeviceIndicator");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetNamedIndicator
+ *(void **) (&XkbSetNamedIndicator_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetNamedIndicator");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetNamedDeviceIndicator
+ *(void **) (&XkbSetNamedDeviceIndicator_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetNamedDeviceIndicator");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbLockModifiers
+ *(void **) (&XkbLockModifiers_dylibloader_wrapper_xlib) = dlsym(handle, "XkbLockModifiers");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbLatchModifiers
+ *(void **) (&XkbLatchModifiers_dylibloader_wrapper_xlib) = dlsym(handle, "XkbLatchModifiers");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbLockGroup
+ *(void **) (&XkbLockGroup_dylibloader_wrapper_xlib) = dlsym(handle, "XkbLockGroup");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbLatchGroup
+ *(void **) (&XkbLatchGroup_dylibloader_wrapper_xlib) = dlsym(handle, "XkbLatchGroup");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetServerInternalMods
+ *(void **) (&XkbSetServerInternalMods_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetServerInternalMods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetIgnoreLockMods
+ *(void **) (&XkbSetIgnoreLockMods_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetIgnoreLockMods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbVirtualModsToReal
+ *(void **) (&XkbVirtualModsToReal_dylibloader_wrapper_xlib) = dlsym(handle, "XkbVirtualModsToReal");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbComputeEffectiveMap
+ *(void **) (&XkbComputeEffectiveMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbComputeEffectiveMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbInitCanonicalKeyTypes
+ *(void **) (&XkbInitCanonicalKeyTypes_dylibloader_wrapper_xlib) = dlsym(handle, "XkbInitCanonicalKeyTypes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocKeyboard
+ *(void **) (&XkbAllocKeyboard_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocKeyboard");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeKeyboard
+ *(void **) (&XkbFreeKeyboard_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeKeyboard");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocClientMap
+ *(void **) (&XkbAllocClientMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocClientMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocServerMap
+ *(void **) (&XkbAllocServerMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocServerMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeClientMap
+ *(void **) (&XkbFreeClientMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeClientMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeServerMap
+ *(void **) (&XkbFreeServerMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeServerMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAddKeyType
+ *(void **) (&XkbAddKeyType_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAddKeyType");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocIndicatorMaps
+ *(void **) (&XkbAllocIndicatorMaps_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocIndicatorMaps");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeIndicatorMaps
+ *(void **) (&XkbFreeIndicatorMaps_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeIndicatorMaps");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetMap
+ *(void **) (&XkbGetMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetUpdatedMap
+ *(void **) (&XkbGetUpdatedMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetUpdatedMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetMapChanges
+ *(void **) (&XkbGetMapChanges_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetMapChanges");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbRefreshKeyboardMapping
+ *(void **) (&XkbRefreshKeyboardMapping_dylibloader_wrapper_xlib) = dlsym(handle, "XkbRefreshKeyboardMapping");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyTypes
+ *(void **) (&XkbGetKeyTypes_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyTypes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeySyms
+ *(void **) (&XkbGetKeySyms_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeySyms");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyActions
+ *(void **) (&XkbGetKeyActions_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyActions");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyBehaviors
+ *(void **) (&XkbGetKeyBehaviors_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyBehaviors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetVirtualMods
+ *(void **) (&XkbGetVirtualMods_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetVirtualMods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyExplicitComponents
+ *(void **) (&XkbGetKeyExplicitComponents_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyExplicitComponents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyModifierMap
+ *(void **) (&XkbGetKeyModifierMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyModifierMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyVirtualModMap
+ *(void **) (&XkbGetKeyVirtualModMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyVirtualModMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocControls
+ *(void **) (&XkbAllocControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeControls
+ *(void **) (&XkbFreeControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetControls
+ *(void **) (&XkbGetControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetControls
+ *(void **) (&XkbSetControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbNoteControlsChanges
+ *(void **) (&XkbNoteControlsChanges_dylibloader_wrapper_xlib) = dlsym(handle, "XkbNoteControlsChanges");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocCompatMap
+ *(void **) (&XkbAllocCompatMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocCompatMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeCompatMap
+ *(void **) (&XkbFreeCompatMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeCompatMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetCompatMap
+ *(void **) (&XkbGetCompatMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetCompatMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetCompatMap
+ *(void **) (&XkbSetCompatMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetCompatMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocNames
+ *(void **) (&XkbAllocNames_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocNames");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetNames
+ *(void **) (&XkbGetNames_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetNames");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetNames
+ *(void **) (&XkbSetNames_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetNames");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbChangeNames
+ *(void **) (&XkbChangeNames_dylibloader_wrapper_xlib) = dlsym(handle, "XkbChangeNames");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeNames
+ *(void **) (&XkbFreeNames_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeNames");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetState
+ *(void **) (&XkbGetState_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetState");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetMap
+ *(void **) (&XkbSetMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbChangeMap
+ *(void **) (&XkbChangeMap_dylibloader_wrapper_xlib) = dlsym(handle, "XkbChangeMap");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetDetectableAutoRepeat
+ *(void **) (&XkbSetDetectableAutoRepeat_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetDetectableAutoRepeat");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetDetectableAutoRepeat
+ *(void **) (&XkbGetDetectableAutoRepeat_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetDetectableAutoRepeat");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetAutoResetControls
+ *(void **) (&XkbSetAutoResetControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetAutoResetControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetAutoResetControls
+ *(void **) (&XkbGetAutoResetControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetAutoResetControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetPerClientControls
+ *(void **) (&XkbSetPerClientControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetPerClientControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetPerClientControls
+ *(void **) (&XkbGetPerClientControls_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetPerClientControls");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbCopyKeyType
+ *(void **) (&XkbCopyKeyType_dylibloader_wrapper_xlib) = dlsym(handle, "XkbCopyKeyType");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbCopyKeyTypes
+ *(void **) (&XkbCopyKeyTypes_dylibloader_wrapper_xlib) = dlsym(handle, "XkbCopyKeyTypes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbResizeKeyType
+ *(void **) (&XkbResizeKeyType_dylibloader_wrapper_xlib) = dlsym(handle, "XkbResizeKeyType");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbResizeKeySyms
+ *(void **) (&XkbResizeKeySyms_dylibloader_wrapper_xlib) = dlsym(handle, "XkbResizeKeySyms");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbResizeKeyActions
+ *(void **) (&XkbResizeKeyActions_dylibloader_wrapper_xlib) = dlsym(handle, "XkbResizeKeyActions");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbChangeTypesOfKey
+ *(void **) (&XkbChangeTypesOfKey_dylibloader_wrapper_xlib) = dlsym(handle, "XkbChangeTypesOfKey");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbChangeKeycodeRange
+ *(void **) (&XkbChangeKeycodeRange_dylibloader_wrapper_xlib) = dlsym(handle, "XkbChangeKeycodeRange");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbListComponents
+ *(void **) (&XkbListComponents_dylibloader_wrapper_xlib) = dlsym(handle, "XkbListComponents");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeComponentList
+ *(void **) (&XkbFreeComponentList_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeComponentList");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyboard
+ *(void **) (&XkbGetKeyboard_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyboard");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetKeyboardByName
+ *(void **) (&XkbGetKeyboardByName_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetKeyboardByName");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbKeyTypesForCoreSymbols
+ *(void **) (&XkbKeyTypesForCoreSymbols_dylibloader_wrapper_xlib) = dlsym(handle, "XkbKeyTypesForCoreSymbols");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbApplyCompatMapToKey
+ *(void **) (&XkbApplyCompatMapToKey_dylibloader_wrapper_xlib) = dlsym(handle, "XkbApplyCompatMapToKey");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbUpdateMapFromCore
+ *(void **) (&XkbUpdateMapFromCore_dylibloader_wrapper_xlib) = dlsym(handle, "XkbUpdateMapFromCore");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAddDeviceLedInfo
+ *(void **) (&XkbAddDeviceLedInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAddDeviceLedInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbResizeDeviceButtonActions
+ *(void **) (&XkbResizeDeviceButtonActions_dylibloader_wrapper_xlib) = dlsym(handle, "XkbResizeDeviceButtonActions");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbAllocDeviceInfo
+ *(void **) (&XkbAllocDeviceInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbAllocDeviceInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbFreeDeviceInfo
+ *(void **) (&XkbFreeDeviceInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbFreeDeviceInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbNoteDeviceChanges
+ *(void **) (&XkbNoteDeviceChanges_dylibloader_wrapper_xlib) = dlsym(handle, "XkbNoteDeviceChanges");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetDeviceInfo
+ *(void **) (&XkbGetDeviceInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetDeviceInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetDeviceInfoChanges
+ *(void **) (&XkbGetDeviceInfoChanges_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetDeviceInfoChanges");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetDeviceButtonActions
+ *(void **) (&XkbGetDeviceButtonActions_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetDeviceButtonActions");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbGetDeviceLedInfo
+ *(void **) (&XkbGetDeviceLedInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbGetDeviceLedInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetDeviceInfo
+ *(void **) (&XkbSetDeviceInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetDeviceInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbChangeDeviceInfo
+ *(void **) (&XkbChangeDeviceInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbChangeDeviceInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetDeviceLedInfo
+ *(void **) (&XkbSetDeviceLedInfo_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetDeviceLedInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetDeviceButtonActions
+ *(void **) (&XkbSetDeviceButtonActions_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetDeviceButtonActions");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbToControl
+ *(void **) (&XkbToControl_dylibloader_wrapper_xlib) = dlsym(handle, "XkbToControl");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbSetDebuggingFlags
+ *(void **) (&XkbSetDebuggingFlags_dylibloader_wrapper_xlib) = dlsym(handle, "XkbSetDebuggingFlags");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbApplyVirtualModChanges
+ *(void **) (&XkbApplyVirtualModChanges_dylibloader_wrapper_xlib) = dlsym(handle, "XkbApplyVirtualModChanges");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbUpdateActionVirtualMods
+ *(void **) (&XkbUpdateActionVirtualMods_dylibloader_wrapper_xlib) = dlsym(handle, "XkbUpdateActionVirtualMods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XkbUpdateKeyTypeVirtualMods
+ *(void **) (&XkbUpdateKeyTypeVirtualMods_dylibloader_wrapper_xlib) = dlsym(handle, "XkbUpdateKeyTypeVirtualMods");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.h
new file mode 100644
index 0000000000..b40a25f601
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.h
@@ -0,0 +1,2439 @@
+#ifndef DYLIBLOAD_WRAPPER_XLIB
+#define DYLIBLOAD_WRAPPER_XLIB
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:13:26
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/Xlib.h --include ./thirdparty/linuxbsd_headers/X11/Xutil.h --include ./thirdparty/linuxbsd_headers/X11/XKBlib.h --sys-include "thirdparty/linuxbsd_headers/X11/Xlib.h" --sys-include "thirdparty/linuxbsd_headers/X11/Xutil.h" --sys-include "thirdparty/linuxbsd_headers/X11/XKBlib.h" --soname libX11.so.6 --init-name xlib --omit-prefix XkbGetDeviceIndicatorState --omit-prefix XkbAddSymInterpret --output-header ./platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xlib-so_wrap.c~
+//
+// NOTE: Generated from Xlib 1.6.9.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, the type of the third argument of
+// XIfEvent, XPeekIfEvent and XCheckIfEvent had to be fixed as it wasn't parsed
+// fully (it's a Bool function pointer, but it was just being parsed as an int
+// pointer).
+
+#include <stdint.h>
+
+#define _Xmblen _Xmblen_dylibloader_orig_xlib
+#define XLoadQueryFont XLoadQueryFont_dylibloader_orig_xlib
+#define XQueryFont XQueryFont_dylibloader_orig_xlib
+#define XGetMotionEvents XGetMotionEvents_dylibloader_orig_xlib
+#define XDeleteModifiermapEntry XDeleteModifiermapEntry_dylibloader_orig_xlib
+#define XGetModifierMapping XGetModifierMapping_dylibloader_orig_xlib
+#define XInsertModifiermapEntry XInsertModifiermapEntry_dylibloader_orig_xlib
+#define XNewModifiermap XNewModifiermap_dylibloader_orig_xlib
+#define XCreateImage XCreateImage_dylibloader_orig_xlib
+#define XInitImage XInitImage_dylibloader_orig_xlib
+#define XGetImage XGetImage_dylibloader_orig_xlib
+#define XGetSubImage XGetSubImage_dylibloader_orig_xlib
+#define XOpenDisplay XOpenDisplay_dylibloader_orig_xlib
+#define XrmInitialize XrmInitialize_dylibloader_orig_xlib
+#define XFetchBytes XFetchBytes_dylibloader_orig_xlib
+#define XFetchBuffer XFetchBuffer_dylibloader_orig_xlib
+#define XGetAtomName XGetAtomName_dylibloader_orig_xlib
+#define XGetAtomNames XGetAtomNames_dylibloader_orig_xlib
+#define XGetDefault XGetDefault_dylibloader_orig_xlib
+#define XDisplayName XDisplayName_dylibloader_orig_xlib
+#define XKeysymToString XKeysymToString_dylibloader_orig_xlib
+#define XSynchronize XSynchronize_dylibloader_orig_xlib
+#define XSetAfterFunction XSetAfterFunction_dylibloader_orig_xlib
+#define XInternAtom XInternAtom_dylibloader_orig_xlib
+#define XInternAtoms XInternAtoms_dylibloader_orig_xlib
+#define XCopyColormapAndFree XCopyColormapAndFree_dylibloader_orig_xlib
+#define XCreateColormap XCreateColormap_dylibloader_orig_xlib
+#define XCreatePixmapCursor XCreatePixmapCursor_dylibloader_orig_xlib
+#define XCreateGlyphCursor XCreateGlyphCursor_dylibloader_orig_xlib
+#define XCreateFontCursor XCreateFontCursor_dylibloader_orig_xlib
+#define XLoadFont XLoadFont_dylibloader_orig_xlib
+#define XCreateGC XCreateGC_dylibloader_orig_xlib
+#define XGContextFromGC XGContextFromGC_dylibloader_orig_xlib
+#define XFlushGC XFlushGC_dylibloader_orig_xlib
+#define XCreatePixmap XCreatePixmap_dylibloader_orig_xlib
+#define XCreateBitmapFromData XCreateBitmapFromData_dylibloader_orig_xlib
+#define XCreatePixmapFromBitmapData XCreatePixmapFromBitmapData_dylibloader_orig_xlib
+#define XCreateSimpleWindow XCreateSimpleWindow_dylibloader_orig_xlib
+#define XGetSelectionOwner XGetSelectionOwner_dylibloader_orig_xlib
+#define XCreateWindow XCreateWindow_dylibloader_orig_xlib
+#define XListInstalledColormaps XListInstalledColormaps_dylibloader_orig_xlib
+#define XListFonts XListFonts_dylibloader_orig_xlib
+#define XListFontsWithInfo XListFontsWithInfo_dylibloader_orig_xlib
+#define XGetFontPath XGetFontPath_dylibloader_orig_xlib
+#define XListExtensions XListExtensions_dylibloader_orig_xlib
+#define XListProperties XListProperties_dylibloader_orig_xlib
+#define XListHosts XListHosts_dylibloader_orig_xlib
+#define XKeycodeToKeysym XKeycodeToKeysym_dylibloader_orig_xlib
+#define XLookupKeysym XLookupKeysym_dylibloader_orig_xlib
+#define XGetKeyboardMapping XGetKeyboardMapping_dylibloader_orig_xlib
+#define XStringToKeysym XStringToKeysym_dylibloader_orig_xlib
+#define XMaxRequestSize XMaxRequestSize_dylibloader_orig_xlib
+#define XExtendedMaxRequestSize XExtendedMaxRequestSize_dylibloader_orig_xlib
+#define XResourceManagerString XResourceManagerString_dylibloader_orig_xlib
+#define XScreenResourceString XScreenResourceString_dylibloader_orig_xlib
+#define XDisplayMotionBufferSize XDisplayMotionBufferSize_dylibloader_orig_xlib
+#define XVisualIDFromVisual XVisualIDFromVisual_dylibloader_orig_xlib
+#define XInitThreads XInitThreads_dylibloader_orig_xlib
+#define XLockDisplay XLockDisplay_dylibloader_orig_xlib
+#define XUnlockDisplay XUnlockDisplay_dylibloader_orig_xlib
+#define XInitExtension XInitExtension_dylibloader_orig_xlib
+#define XAddExtension XAddExtension_dylibloader_orig_xlib
+#define XFindOnExtensionList XFindOnExtensionList_dylibloader_orig_xlib
+#define XEHeadOfExtensionList XEHeadOfExtensionList_dylibloader_orig_xlib
+#define XRootWindow XRootWindow_dylibloader_orig_xlib
+#define XDefaultRootWindow XDefaultRootWindow_dylibloader_orig_xlib
+#define XRootWindowOfScreen XRootWindowOfScreen_dylibloader_orig_xlib
+#define XDefaultVisual XDefaultVisual_dylibloader_orig_xlib
+#define XDefaultVisualOfScreen XDefaultVisualOfScreen_dylibloader_orig_xlib
+#define XDefaultGC XDefaultGC_dylibloader_orig_xlib
+#define XDefaultGCOfScreen XDefaultGCOfScreen_dylibloader_orig_xlib
+#define XBlackPixel XBlackPixel_dylibloader_orig_xlib
+#define XWhitePixel XWhitePixel_dylibloader_orig_xlib
+#define XAllPlanes XAllPlanes_dylibloader_orig_xlib
+#define XBlackPixelOfScreen XBlackPixelOfScreen_dylibloader_orig_xlib
+#define XWhitePixelOfScreen XWhitePixelOfScreen_dylibloader_orig_xlib
+#define XNextRequest XNextRequest_dylibloader_orig_xlib
+#define XLastKnownRequestProcessed XLastKnownRequestProcessed_dylibloader_orig_xlib
+#define XServerVendor XServerVendor_dylibloader_orig_xlib
+#define XDisplayString XDisplayString_dylibloader_orig_xlib
+#define XDefaultColormap XDefaultColormap_dylibloader_orig_xlib
+#define XDefaultColormapOfScreen XDefaultColormapOfScreen_dylibloader_orig_xlib
+#define XDisplayOfScreen XDisplayOfScreen_dylibloader_orig_xlib
+#define XScreenOfDisplay XScreenOfDisplay_dylibloader_orig_xlib
+#define XDefaultScreenOfDisplay XDefaultScreenOfDisplay_dylibloader_orig_xlib
+#define XEventMaskOfScreen XEventMaskOfScreen_dylibloader_orig_xlib
+#define XScreenNumberOfScreen XScreenNumberOfScreen_dylibloader_orig_xlib
+#define XSetErrorHandler XSetErrorHandler_dylibloader_orig_xlib
+#define XSetIOErrorHandler XSetIOErrorHandler_dylibloader_orig_xlib
+#define XListPixmapFormats XListPixmapFormats_dylibloader_orig_xlib
+#define XListDepths XListDepths_dylibloader_orig_xlib
+#define XReconfigureWMWindow XReconfigureWMWindow_dylibloader_orig_xlib
+#define XGetWMProtocols XGetWMProtocols_dylibloader_orig_xlib
+#define XSetWMProtocols XSetWMProtocols_dylibloader_orig_xlib
+#define XIconifyWindow XIconifyWindow_dylibloader_orig_xlib
+#define XWithdrawWindow XWithdrawWindow_dylibloader_orig_xlib
+#define XGetCommand XGetCommand_dylibloader_orig_xlib
+#define XGetWMColormapWindows XGetWMColormapWindows_dylibloader_orig_xlib
+#define XSetWMColormapWindows XSetWMColormapWindows_dylibloader_orig_xlib
+#define XFreeStringList XFreeStringList_dylibloader_orig_xlib
+#define XSetTransientForHint XSetTransientForHint_dylibloader_orig_xlib
+#define XActivateScreenSaver XActivateScreenSaver_dylibloader_orig_xlib
+#define XAddHost XAddHost_dylibloader_orig_xlib
+#define XAddHosts XAddHosts_dylibloader_orig_xlib
+#define XAddToExtensionList XAddToExtensionList_dylibloader_orig_xlib
+#define XAddToSaveSet XAddToSaveSet_dylibloader_orig_xlib
+#define XAllocColor XAllocColor_dylibloader_orig_xlib
+#define XAllocColorCells XAllocColorCells_dylibloader_orig_xlib
+#define XAllocColorPlanes XAllocColorPlanes_dylibloader_orig_xlib
+#define XAllocNamedColor XAllocNamedColor_dylibloader_orig_xlib
+#define XAllowEvents XAllowEvents_dylibloader_orig_xlib
+#define XAutoRepeatOff XAutoRepeatOff_dylibloader_orig_xlib
+#define XAutoRepeatOn XAutoRepeatOn_dylibloader_orig_xlib
+#define XBell XBell_dylibloader_orig_xlib
+#define XBitmapBitOrder XBitmapBitOrder_dylibloader_orig_xlib
+#define XBitmapPad XBitmapPad_dylibloader_orig_xlib
+#define XBitmapUnit XBitmapUnit_dylibloader_orig_xlib
+#define XCellsOfScreen XCellsOfScreen_dylibloader_orig_xlib
+#define XChangeActivePointerGrab XChangeActivePointerGrab_dylibloader_orig_xlib
+#define XChangeGC XChangeGC_dylibloader_orig_xlib
+#define XChangeKeyboardControl XChangeKeyboardControl_dylibloader_orig_xlib
+#define XChangeKeyboardMapping XChangeKeyboardMapping_dylibloader_orig_xlib
+#define XChangePointerControl XChangePointerControl_dylibloader_orig_xlib
+#define XChangeProperty XChangeProperty_dylibloader_orig_xlib
+#define XChangeSaveSet XChangeSaveSet_dylibloader_orig_xlib
+#define XChangeWindowAttributes XChangeWindowAttributes_dylibloader_orig_xlib
+#define XCheckIfEvent XCheckIfEvent_dylibloader_orig_xlib
+#define XCheckMaskEvent XCheckMaskEvent_dylibloader_orig_xlib
+#define XCheckTypedEvent XCheckTypedEvent_dylibloader_orig_xlib
+#define XCheckTypedWindowEvent XCheckTypedWindowEvent_dylibloader_orig_xlib
+#define XCheckWindowEvent XCheckWindowEvent_dylibloader_orig_xlib
+#define XCirculateSubwindows XCirculateSubwindows_dylibloader_orig_xlib
+#define XCirculateSubwindowsDown XCirculateSubwindowsDown_dylibloader_orig_xlib
+#define XCirculateSubwindowsUp XCirculateSubwindowsUp_dylibloader_orig_xlib
+#define XClearArea XClearArea_dylibloader_orig_xlib
+#define XClearWindow XClearWindow_dylibloader_orig_xlib
+#define XCloseDisplay XCloseDisplay_dylibloader_orig_xlib
+#define XConfigureWindow XConfigureWindow_dylibloader_orig_xlib
+#define XConnectionNumber XConnectionNumber_dylibloader_orig_xlib
+#define XConvertSelection XConvertSelection_dylibloader_orig_xlib
+#define XCopyArea XCopyArea_dylibloader_orig_xlib
+#define XCopyGC XCopyGC_dylibloader_orig_xlib
+#define XCopyPlane XCopyPlane_dylibloader_orig_xlib
+#define XDefaultDepth XDefaultDepth_dylibloader_orig_xlib
+#define XDefaultDepthOfScreen XDefaultDepthOfScreen_dylibloader_orig_xlib
+#define XDefaultScreen XDefaultScreen_dylibloader_orig_xlib
+#define XDefineCursor XDefineCursor_dylibloader_orig_xlib
+#define XDeleteProperty XDeleteProperty_dylibloader_orig_xlib
+#define XDestroyWindow XDestroyWindow_dylibloader_orig_xlib
+#define XDestroySubwindows XDestroySubwindows_dylibloader_orig_xlib
+#define XDoesBackingStore XDoesBackingStore_dylibloader_orig_xlib
+#define XDoesSaveUnders XDoesSaveUnders_dylibloader_orig_xlib
+#define XDisableAccessControl XDisableAccessControl_dylibloader_orig_xlib
+#define XDisplayCells XDisplayCells_dylibloader_orig_xlib
+#define XDisplayHeight XDisplayHeight_dylibloader_orig_xlib
+#define XDisplayHeightMM XDisplayHeightMM_dylibloader_orig_xlib
+#define XDisplayKeycodes XDisplayKeycodes_dylibloader_orig_xlib
+#define XDisplayPlanes XDisplayPlanes_dylibloader_orig_xlib
+#define XDisplayWidth XDisplayWidth_dylibloader_orig_xlib
+#define XDisplayWidthMM XDisplayWidthMM_dylibloader_orig_xlib
+#define XDrawArc XDrawArc_dylibloader_orig_xlib
+#define XDrawArcs XDrawArcs_dylibloader_orig_xlib
+#define XDrawImageString XDrawImageString_dylibloader_orig_xlib
+#define XDrawImageString16 XDrawImageString16_dylibloader_orig_xlib
+#define XDrawLine XDrawLine_dylibloader_orig_xlib
+#define XDrawLines XDrawLines_dylibloader_orig_xlib
+#define XDrawPoint XDrawPoint_dylibloader_orig_xlib
+#define XDrawPoints XDrawPoints_dylibloader_orig_xlib
+#define XDrawRectangle XDrawRectangle_dylibloader_orig_xlib
+#define XDrawRectangles XDrawRectangles_dylibloader_orig_xlib
+#define XDrawSegments XDrawSegments_dylibloader_orig_xlib
+#define XDrawString XDrawString_dylibloader_orig_xlib
+#define XDrawString16 XDrawString16_dylibloader_orig_xlib
+#define XDrawText XDrawText_dylibloader_orig_xlib
+#define XDrawText16 XDrawText16_dylibloader_orig_xlib
+#define XEnableAccessControl XEnableAccessControl_dylibloader_orig_xlib
+#define XEventsQueued XEventsQueued_dylibloader_orig_xlib
+#define XFetchName XFetchName_dylibloader_orig_xlib
+#define XFillArc XFillArc_dylibloader_orig_xlib
+#define XFillArcs XFillArcs_dylibloader_orig_xlib
+#define XFillPolygon XFillPolygon_dylibloader_orig_xlib
+#define XFillRectangle XFillRectangle_dylibloader_orig_xlib
+#define XFillRectangles XFillRectangles_dylibloader_orig_xlib
+#define XFlush XFlush_dylibloader_orig_xlib
+#define XForceScreenSaver XForceScreenSaver_dylibloader_orig_xlib
+#define XFree XFree_dylibloader_orig_xlib
+#define XFreeColormap XFreeColormap_dylibloader_orig_xlib
+#define XFreeColors XFreeColors_dylibloader_orig_xlib
+#define XFreeCursor XFreeCursor_dylibloader_orig_xlib
+#define XFreeExtensionList XFreeExtensionList_dylibloader_orig_xlib
+#define XFreeFont XFreeFont_dylibloader_orig_xlib
+#define XFreeFontInfo XFreeFontInfo_dylibloader_orig_xlib
+#define XFreeFontNames XFreeFontNames_dylibloader_orig_xlib
+#define XFreeFontPath XFreeFontPath_dylibloader_orig_xlib
+#define XFreeGC XFreeGC_dylibloader_orig_xlib
+#define XFreeModifiermap XFreeModifiermap_dylibloader_orig_xlib
+#define XFreePixmap XFreePixmap_dylibloader_orig_xlib
+#define XGeometry XGeometry_dylibloader_orig_xlib
+#define XGetErrorDatabaseText XGetErrorDatabaseText_dylibloader_orig_xlib
+#define XGetErrorText XGetErrorText_dylibloader_orig_xlib
+#define XGetFontProperty XGetFontProperty_dylibloader_orig_xlib
+#define XGetGCValues XGetGCValues_dylibloader_orig_xlib
+#define XGetGeometry XGetGeometry_dylibloader_orig_xlib
+#define XGetIconName XGetIconName_dylibloader_orig_xlib
+#define XGetInputFocus XGetInputFocus_dylibloader_orig_xlib
+#define XGetKeyboardControl XGetKeyboardControl_dylibloader_orig_xlib
+#define XGetPointerControl XGetPointerControl_dylibloader_orig_xlib
+#define XGetPointerMapping XGetPointerMapping_dylibloader_orig_xlib
+#define XGetScreenSaver XGetScreenSaver_dylibloader_orig_xlib
+#define XGetTransientForHint XGetTransientForHint_dylibloader_orig_xlib
+#define XGetWindowProperty XGetWindowProperty_dylibloader_orig_xlib
+#define XGetWindowAttributes XGetWindowAttributes_dylibloader_orig_xlib
+#define XGrabButton XGrabButton_dylibloader_orig_xlib
+#define XGrabKey XGrabKey_dylibloader_orig_xlib
+#define XGrabKeyboard XGrabKeyboard_dylibloader_orig_xlib
+#define XGrabPointer XGrabPointer_dylibloader_orig_xlib
+#define XGrabServer XGrabServer_dylibloader_orig_xlib
+#define XHeightMMOfScreen XHeightMMOfScreen_dylibloader_orig_xlib
+#define XHeightOfScreen XHeightOfScreen_dylibloader_orig_xlib
+#define XIfEvent XIfEvent_dylibloader_orig_xlib
+#define XImageByteOrder XImageByteOrder_dylibloader_orig_xlib
+#define XInstallColormap XInstallColormap_dylibloader_orig_xlib
+#define XKeysymToKeycode XKeysymToKeycode_dylibloader_orig_xlib
+#define XKillClient XKillClient_dylibloader_orig_xlib
+#define XLookupColor XLookupColor_dylibloader_orig_xlib
+#define XLowerWindow XLowerWindow_dylibloader_orig_xlib
+#define XMapRaised XMapRaised_dylibloader_orig_xlib
+#define XMapSubwindows XMapSubwindows_dylibloader_orig_xlib
+#define XMapWindow XMapWindow_dylibloader_orig_xlib
+#define XMaskEvent XMaskEvent_dylibloader_orig_xlib
+#define XMaxCmapsOfScreen XMaxCmapsOfScreen_dylibloader_orig_xlib
+#define XMinCmapsOfScreen XMinCmapsOfScreen_dylibloader_orig_xlib
+#define XMoveResizeWindow XMoveResizeWindow_dylibloader_orig_xlib
+#define XMoveWindow XMoveWindow_dylibloader_orig_xlib
+#define XNextEvent XNextEvent_dylibloader_orig_xlib
+#define XNoOp XNoOp_dylibloader_orig_xlib
+#define XParseColor XParseColor_dylibloader_orig_xlib
+#define XParseGeometry XParseGeometry_dylibloader_orig_xlib
+#define XPeekEvent XPeekEvent_dylibloader_orig_xlib
+#define XPeekIfEvent XPeekIfEvent_dylibloader_orig_xlib
+#define XPending XPending_dylibloader_orig_xlib
+#define XPlanesOfScreen XPlanesOfScreen_dylibloader_orig_xlib
+#define XProtocolRevision XProtocolRevision_dylibloader_orig_xlib
+#define XProtocolVersion XProtocolVersion_dylibloader_orig_xlib
+#define XPutBackEvent XPutBackEvent_dylibloader_orig_xlib
+#define XPutImage XPutImage_dylibloader_orig_xlib
+#define XQLength XQLength_dylibloader_orig_xlib
+#define XQueryBestCursor XQueryBestCursor_dylibloader_orig_xlib
+#define XQueryBestSize XQueryBestSize_dylibloader_orig_xlib
+#define XQueryBestStipple XQueryBestStipple_dylibloader_orig_xlib
+#define XQueryBestTile XQueryBestTile_dylibloader_orig_xlib
+#define XQueryColor XQueryColor_dylibloader_orig_xlib
+#define XQueryColors XQueryColors_dylibloader_orig_xlib
+#define XQueryExtension XQueryExtension_dylibloader_orig_xlib
+#define XQueryKeymap XQueryKeymap_dylibloader_orig_xlib
+#define XQueryPointer XQueryPointer_dylibloader_orig_xlib
+#define XQueryTextExtents XQueryTextExtents_dylibloader_orig_xlib
+#define XQueryTextExtents16 XQueryTextExtents16_dylibloader_orig_xlib
+#define XQueryTree XQueryTree_dylibloader_orig_xlib
+#define XRaiseWindow XRaiseWindow_dylibloader_orig_xlib
+#define XReadBitmapFile XReadBitmapFile_dylibloader_orig_xlib
+#define XReadBitmapFileData XReadBitmapFileData_dylibloader_orig_xlib
+#define XRebindKeysym XRebindKeysym_dylibloader_orig_xlib
+#define XRecolorCursor XRecolorCursor_dylibloader_orig_xlib
+#define XRefreshKeyboardMapping XRefreshKeyboardMapping_dylibloader_orig_xlib
+#define XRemoveFromSaveSet XRemoveFromSaveSet_dylibloader_orig_xlib
+#define XRemoveHost XRemoveHost_dylibloader_orig_xlib
+#define XRemoveHosts XRemoveHosts_dylibloader_orig_xlib
+#define XReparentWindow XReparentWindow_dylibloader_orig_xlib
+#define XResetScreenSaver XResetScreenSaver_dylibloader_orig_xlib
+#define XResizeWindow XResizeWindow_dylibloader_orig_xlib
+#define XRestackWindows XRestackWindows_dylibloader_orig_xlib
+#define XRotateBuffers XRotateBuffers_dylibloader_orig_xlib
+#define XRotateWindowProperties XRotateWindowProperties_dylibloader_orig_xlib
+#define XScreenCount XScreenCount_dylibloader_orig_xlib
+#define XSelectInput XSelectInput_dylibloader_orig_xlib
+#define XSendEvent XSendEvent_dylibloader_orig_xlib
+#define XSetAccessControl XSetAccessControl_dylibloader_orig_xlib
+#define XSetArcMode XSetArcMode_dylibloader_orig_xlib
+#define XSetBackground XSetBackground_dylibloader_orig_xlib
+#define XSetClipMask XSetClipMask_dylibloader_orig_xlib
+#define XSetClipOrigin XSetClipOrigin_dylibloader_orig_xlib
+#define XSetClipRectangles XSetClipRectangles_dylibloader_orig_xlib
+#define XSetCloseDownMode XSetCloseDownMode_dylibloader_orig_xlib
+#define XSetCommand XSetCommand_dylibloader_orig_xlib
+#define XSetDashes XSetDashes_dylibloader_orig_xlib
+#define XSetFillRule XSetFillRule_dylibloader_orig_xlib
+#define XSetFillStyle XSetFillStyle_dylibloader_orig_xlib
+#define XSetFont XSetFont_dylibloader_orig_xlib
+#define XSetFontPath XSetFontPath_dylibloader_orig_xlib
+#define XSetForeground XSetForeground_dylibloader_orig_xlib
+#define XSetFunction XSetFunction_dylibloader_orig_xlib
+#define XSetGraphicsExposures XSetGraphicsExposures_dylibloader_orig_xlib
+#define XSetIconName XSetIconName_dylibloader_orig_xlib
+#define XSetInputFocus XSetInputFocus_dylibloader_orig_xlib
+#define XSetLineAttributes XSetLineAttributes_dylibloader_orig_xlib
+#define XSetModifierMapping XSetModifierMapping_dylibloader_orig_xlib
+#define XSetPlaneMask XSetPlaneMask_dylibloader_orig_xlib
+#define XSetPointerMapping XSetPointerMapping_dylibloader_orig_xlib
+#define XSetScreenSaver XSetScreenSaver_dylibloader_orig_xlib
+#define XSetSelectionOwner XSetSelectionOwner_dylibloader_orig_xlib
+#define XSetState XSetState_dylibloader_orig_xlib
+#define XSetStipple XSetStipple_dylibloader_orig_xlib
+#define XSetSubwindowMode XSetSubwindowMode_dylibloader_orig_xlib
+#define XSetTSOrigin XSetTSOrigin_dylibloader_orig_xlib
+#define XSetTile XSetTile_dylibloader_orig_xlib
+#define XSetWindowBackground XSetWindowBackground_dylibloader_orig_xlib
+#define XSetWindowBackgroundPixmap XSetWindowBackgroundPixmap_dylibloader_orig_xlib
+#define XSetWindowBorder XSetWindowBorder_dylibloader_orig_xlib
+#define XSetWindowBorderPixmap XSetWindowBorderPixmap_dylibloader_orig_xlib
+#define XSetWindowBorderWidth XSetWindowBorderWidth_dylibloader_orig_xlib
+#define XSetWindowColormap XSetWindowColormap_dylibloader_orig_xlib
+#define XStoreBuffer XStoreBuffer_dylibloader_orig_xlib
+#define XStoreBytes XStoreBytes_dylibloader_orig_xlib
+#define XStoreColor XStoreColor_dylibloader_orig_xlib
+#define XStoreColors XStoreColors_dylibloader_orig_xlib
+#define XStoreName XStoreName_dylibloader_orig_xlib
+#define XStoreNamedColor XStoreNamedColor_dylibloader_orig_xlib
+#define XSync XSync_dylibloader_orig_xlib
+#define XTextExtents XTextExtents_dylibloader_orig_xlib
+#define XTextExtents16 XTextExtents16_dylibloader_orig_xlib
+#define XTextWidth XTextWidth_dylibloader_orig_xlib
+#define XTextWidth16 XTextWidth16_dylibloader_orig_xlib
+#define XTranslateCoordinates XTranslateCoordinates_dylibloader_orig_xlib
+#define XUndefineCursor XUndefineCursor_dylibloader_orig_xlib
+#define XUngrabButton XUngrabButton_dylibloader_orig_xlib
+#define XUngrabKey XUngrabKey_dylibloader_orig_xlib
+#define XUngrabKeyboard XUngrabKeyboard_dylibloader_orig_xlib
+#define XUngrabPointer XUngrabPointer_dylibloader_orig_xlib
+#define XUngrabServer XUngrabServer_dylibloader_orig_xlib
+#define XUninstallColormap XUninstallColormap_dylibloader_orig_xlib
+#define XUnloadFont XUnloadFont_dylibloader_orig_xlib
+#define XUnmapSubwindows XUnmapSubwindows_dylibloader_orig_xlib
+#define XUnmapWindow XUnmapWindow_dylibloader_orig_xlib
+#define XVendorRelease XVendorRelease_dylibloader_orig_xlib
+#define XWarpPointer XWarpPointer_dylibloader_orig_xlib
+#define XWidthMMOfScreen XWidthMMOfScreen_dylibloader_orig_xlib
+#define XWidthOfScreen XWidthOfScreen_dylibloader_orig_xlib
+#define XWindowEvent XWindowEvent_dylibloader_orig_xlib
+#define XWriteBitmapFile XWriteBitmapFile_dylibloader_orig_xlib
+#define XSupportsLocale XSupportsLocale_dylibloader_orig_xlib
+#define XSetLocaleModifiers XSetLocaleModifiers_dylibloader_orig_xlib
+#define XOpenOM XOpenOM_dylibloader_orig_xlib
+#define XCloseOM XCloseOM_dylibloader_orig_xlib
+#define XSetOMValues XSetOMValues_dylibloader_orig_xlib
+#define XGetOMValues XGetOMValues_dylibloader_orig_xlib
+#define XDisplayOfOM XDisplayOfOM_dylibloader_orig_xlib
+#define XLocaleOfOM XLocaleOfOM_dylibloader_orig_xlib
+#define XCreateOC XCreateOC_dylibloader_orig_xlib
+#define XDestroyOC XDestroyOC_dylibloader_orig_xlib
+#define XOMOfOC XOMOfOC_dylibloader_orig_xlib
+#define XSetOCValues XSetOCValues_dylibloader_orig_xlib
+#define XGetOCValues XGetOCValues_dylibloader_orig_xlib
+#define XCreateFontSet XCreateFontSet_dylibloader_orig_xlib
+#define XFreeFontSet XFreeFontSet_dylibloader_orig_xlib
+#define XFontsOfFontSet XFontsOfFontSet_dylibloader_orig_xlib
+#define XBaseFontNameListOfFontSet XBaseFontNameListOfFontSet_dylibloader_orig_xlib
+#define XLocaleOfFontSet XLocaleOfFontSet_dylibloader_orig_xlib
+#define XContextDependentDrawing XContextDependentDrawing_dylibloader_orig_xlib
+#define XDirectionalDependentDrawing XDirectionalDependentDrawing_dylibloader_orig_xlib
+#define XContextualDrawing XContextualDrawing_dylibloader_orig_xlib
+#define XExtentsOfFontSet XExtentsOfFontSet_dylibloader_orig_xlib
+#define XmbTextEscapement XmbTextEscapement_dylibloader_orig_xlib
+#define XwcTextEscapement XwcTextEscapement_dylibloader_orig_xlib
+#define Xutf8TextEscapement Xutf8TextEscapement_dylibloader_orig_xlib
+#define XmbTextExtents XmbTextExtents_dylibloader_orig_xlib
+#define XwcTextExtents XwcTextExtents_dylibloader_orig_xlib
+#define Xutf8TextExtents Xutf8TextExtents_dylibloader_orig_xlib
+#define XmbTextPerCharExtents XmbTextPerCharExtents_dylibloader_orig_xlib
+#define XwcTextPerCharExtents XwcTextPerCharExtents_dylibloader_orig_xlib
+#define Xutf8TextPerCharExtents Xutf8TextPerCharExtents_dylibloader_orig_xlib
+#define XmbDrawText XmbDrawText_dylibloader_orig_xlib
+#define XwcDrawText XwcDrawText_dylibloader_orig_xlib
+#define Xutf8DrawText Xutf8DrawText_dylibloader_orig_xlib
+#define XmbDrawString XmbDrawString_dylibloader_orig_xlib
+#define XwcDrawString XwcDrawString_dylibloader_orig_xlib
+#define Xutf8DrawString Xutf8DrawString_dylibloader_orig_xlib
+#define XmbDrawImageString XmbDrawImageString_dylibloader_orig_xlib
+#define XwcDrawImageString XwcDrawImageString_dylibloader_orig_xlib
+#define Xutf8DrawImageString Xutf8DrawImageString_dylibloader_orig_xlib
+#define XOpenIM XOpenIM_dylibloader_orig_xlib
+#define XCloseIM XCloseIM_dylibloader_orig_xlib
+#define XGetIMValues XGetIMValues_dylibloader_orig_xlib
+#define XSetIMValues XSetIMValues_dylibloader_orig_xlib
+#define XDisplayOfIM XDisplayOfIM_dylibloader_orig_xlib
+#define XLocaleOfIM XLocaleOfIM_dylibloader_orig_xlib
+#define XCreateIC XCreateIC_dylibloader_orig_xlib
+#define XDestroyIC XDestroyIC_dylibloader_orig_xlib
+#define XSetICFocus XSetICFocus_dylibloader_orig_xlib
+#define XUnsetICFocus XUnsetICFocus_dylibloader_orig_xlib
+#define XwcResetIC XwcResetIC_dylibloader_orig_xlib
+#define XmbResetIC XmbResetIC_dylibloader_orig_xlib
+#define Xutf8ResetIC Xutf8ResetIC_dylibloader_orig_xlib
+#define XSetICValues XSetICValues_dylibloader_orig_xlib
+#define XGetICValues XGetICValues_dylibloader_orig_xlib
+#define XIMOfIC XIMOfIC_dylibloader_orig_xlib
+#define XFilterEvent XFilterEvent_dylibloader_orig_xlib
+#define XmbLookupString XmbLookupString_dylibloader_orig_xlib
+#define XwcLookupString XwcLookupString_dylibloader_orig_xlib
+#define Xutf8LookupString Xutf8LookupString_dylibloader_orig_xlib
+#define XVaCreateNestedList XVaCreateNestedList_dylibloader_orig_xlib
+#define XRegisterIMInstantiateCallback XRegisterIMInstantiateCallback_dylibloader_orig_xlib
+#define XUnregisterIMInstantiateCallback XUnregisterIMInstantiateCallback_dylibloader_orig_xlib
+#define XInternalConnectionNumbers XInternalConnectionNumbers_dylibloader_orig_xlib
+#define XProcessInternalConnection XProcessInternalConnection_dylibloader_orig_xlib
+#define XAddConnectionWatch XAddConnectionWatch_dylibloader_orig_xlib
+#define XRemoveConnectionWatch XRemoveConnectionWatch_dylibloader_orig_xlib
+#define XSetAuthorization XSetAuthorization_dylibloader_orig_xlib
+#define _Xmbtowc _Xmbtowc_dylibloader_orig_xlib
+#define _Xwctomb _Xwctomb_dylibloader_orig_xlib
+#define XGetEventData XGetEventData_dylibloader_orig_xlib
+#define XFreeEventData XFreeEventData_dylibloader_orig_xlib
+#define XAllocClassHint XAllocClassHint_dylibloader_orig_xlib
+#define XAllocIconSize XAllocIconSize_dylibloader_orig_xlib
+#define XAllocSizeHints XAllocSizeHints_dylibloader_orig_xlib
+#define XAllocStandardColormap XAllocStandardColormap_dylibloader_orig_xlib
+#define XAllocWMHints XAllocWMHints_dylibloader_orig_xlib
+#define XClipBox XClipBox_dylibloader_orig_xlib
+#define XCreateRegion XCreateRegion_dylibloader_orig_xlib
+#define XDefaultString XDefaultString_dylibloader_orig_xlib
+#define XDeleteContext XDeleteContext_dylibloader_orig_xlib
+#define XDestroyRegion XDestroyRegion_dylibloader_orig_xlib
+#define XEmptyRegion XEmptyRegion_dylibloader_orig_xlib
+#define XEqualRegion XEqualRegion_dylibloader_orig_xlib
+#define XFindContext XFindContext_dylibloader_orig_xlib
+#define XGetClassHint XGetClassHint_dylibloader_orig_xlib
+#define XGetIconSizes XGetIconSizes_dylibloader_orig_xlib
+#define XGetNormalHints XGetNormalHints_dylibloader_orig_xlib
+#define XGetRGBColormaps XGetRGBColormaps_dylibloader_orig_xlib
+#define XGetSizeHints XGetSizeHints_dylibloader_orig_xlib
+#define XGetStandardColormap XGetStandardColormap_dylibloader_orig_xlib
+#define XGetTextProperty XGetTextProperty_dylibloader_orig_xlib
+#define XGetVisualInfo XGetVisualInfo_dylibloader_orig_xlib
+#define XGetWMClientMachine XGetWMClientMachine_dylibloader_orig_xlib
+#define XGetWMHints XGetWMHints_dylibloader_orig_xlib
+#define XGetWMIconName XGetWMIconName_dylibloader_orig_xlib
+#define XGetWMName XGetWMName_dylibloader_orig_xlib
+#define XGetWMNormalHints XGetWMNormalHints_dylibloader_orig_xlib
+#define XGetWMSizeHints XGetWMSizeHints_dylibloader_orig_xlib
+#define XGetZoomHints XGetZoomHints_dylibloader_orig_xlib
+#define XIntersectRegion XIntersectRegion_dylibloader_orig_xlib
+#define XConvertCase XConvertCase_dylibloader_orig_xlib
+#define XLookupString XLookupString_dylibloader_orig_xlib
+#define XMatchVisualInfo XMatchVisualInfo_dylibloader_orig_xlib
+#define XOffsetRegion XOffsetRegion_dylibloader_orig_xlib
+#define XPointInRegion XPointInRegion_dylibloader_orig_xlib
+#define XPolygonRegion XPolygonRegion_dylibloader_orig_xlib
+#define XRectInRegion XRectInRegion_dylibloader_orig_xlib
+#define XSaveContext XSaveContext_dylibloader_orig_xlib
+#define XSetClassHint XSetClassHint_dylibloader_orig_xlib
+#define XSetIconSizes XSetIconSizes_dylibloader_orig_xlib
+#define XSetNormalHints XSetNormalHints_dylibloader_orig_xlib
+#define XSetRGBColormaps XSetRGBColormaps_dylibloader_orig_xlib
+#define XSetSizeHints XSetSizeHints_dylibloader_orig_xlib
+#define XSetStandardProperties XSetStandardProperties_dylibloader_orig_xlib
+#define XSetTextProperty XSetTextProperty_dylibloader_orig_xlib
+#define XSetWMClientMachine XSetWMClientMachine_dylibloader_orig_xlib
+#define XSetWMHints XSetWMHints_dylibloader_orig_xlib
+#define XSetWMIconName XSetWMIconName_dylibloader_orig_xlib
+#define XSetWMName XSetWMName_dylibloader_orig_xlib
+#define XSetWMNormalHints XSetWMNormalHints_dylibloader_orig_xlib
+#define XSetWMProperties XSetWMProperties_dylibloader_orig_xlib
+#define XmbSetWMProperties XmbSetWMProperties_dylibloader_orig_xlib
+#define Xutf8SetWMProperties Xutf8SetWMProperties_dylibloader_orig_xlib
+#define XSetWMSizeHints XSetWMSizeHints_dylibloader_orig_xlib
+#define XSetRegion XSetRegion_dylibloader_orig_xlib
+#define XSetStandardColormap XSetStandardColormap_dylibloader_orig_xlib
+#define XSetZoomHints XSetZoomHints_dylibloader_orig_xlib
+#define XShrinkRegion XShrinkRegion_dylibloader_orig_xlib
+#define XStringListToTextProperty XStringListToTextProperty_dylibloader_orig_xlib
+#define XSubtractRegion XSubtractRegion_dylibloader_orig_xlib
+#define XmbTextListToTextProperty XmbTextListToTextProperty_dylibloader_orig_xlib
+#define XwcTextListToTextProperty XwcTextListToTextProperty_dylibloader_orig_xlib
+#define Xutf8TextListToTextProperty Xutf8TextListToTextProperty_dylibloader_orig_xlib
+#define XwcFreeStringList XwcFreeStringList_dylibloader_orig_xlib
+#define XTextPropertyToStringList XTextPropertyToStringList_dylibloader_orig_xlib
+#define XmbTextPropertyToTextList XmbTextPropertyToTextList_dylibloader_orig_xlib
+#define XwcTextPropertyToTextList XwcTextPropertyToTextList_dylibloader_orig_xlib
+#define Xutf8TextPropertyToTextList Xutf8TextPropertyToTextList_dylibloader_orig_xlib
+#define XUnionRectWithRegion XUnionRectWithRegion_dylibloader_orig_xlib
+#define XUnionRegion XUnionRegion_dylibloader_orig_xlib
+#define XWMGeometry XWMGeometry_dylibloader_orig_xlib
+#define XXorRegion XXorRegion_dylibloader_orig_xlib
+#define XkbIgnoreExtension XkbIgnoreExtension_dylibloader_orig_xlib
+#define XkbOpenDisplay XkbOpenDisplay_dylibloader_orig_xlib
+#define XkbQueryExtension XkbQueryExtension_dylibloader_orig_xlib
+#define XkbUseExtension XkbUseExtension_dylibloader_orig_xlib
+#define XkbLibraryVersion XkbLibraryVersion_dylibloader_orig_xlib
+#define XkbSetXlibControls XkbSetXlibControls_dylibloader_orig_xlib
+#define XkbGetXlibControls XkbGetXlibControls_dylibloader_orig_xlib
+#define XkbXlibControlsImplemented XkbXlibControlsImplemented_dylibloader_orig_xlib
+#define XkbSetAtomFuncs XkbSetAtomFuncs_dylibloader_orig_xlib
+#define XkbKeycodeToKeysym XkbKeycodeToKeysym_dylibloader_orig_xlib
+#define XkbKeysymToModifiers XkbKeysymToModifiers_dylibloader_orig_xlib
+#define XkbLookupKeySym XkbLookupKeySym_dylibloader_orig_xlib
+#define XkbLookupKeyBinding XkbLookupKeyBinding_dylibloader_orig_xlib
+#define XkbTranslateKeyCode XkbTranslateKeyCode_dylibloader_orig_xlib
+#define XkbTranslateKeySym XkbTranslateKeySym_dylibloader_orig_xlib
+#define XkbSetAutoRepeatRate XkbSetAutoRepeatRate_dylibloader_orig_xlib
+#define XkbGetAutoRepeatRate XkbGetAutoRepeatRate_dylibloader_orig_xlib
+#define XkbChangeEnabledControls XkbChangeEnabledControls_dylibloader_orig_xlib
+#define XkbDeviceBell XkbDeviceBell_dylibloader_orig_xlib
+#define XkbForceDeviceBell XkbForceDeviceBell_dylibloader_orig_xlib
+#define XkbDeviceBellEvent XkbDeviceBellEvent_dylibloader_orig_xlib
+#define XkbBell XkbBell_dylibloader_orig_xlib
+#define XkbForceBell XkbForceBell_dylibloader_orig_xlib
+#define XkbBellEvent XkbBellEvent_dylibloader_orig_xlib
+#define XkbSelectEvents XkbSelectEvents_dylibloader_orig_xlib
+#define XkbSelectEventDetails XkbSelectEventDetails_dylibloader_orig_xlib
+#define XkbNoteMapChanges XkbNoteMapChanges_dylibloader_orig_xlib
+#define XkbNoteNameChanges XkbNoteNameChanges_dylibloader_orig_xlib
+#define XkbGetIndicatorState XkbGetIndicatorState_dylibloader_orig_xlib
+#define XkbGetIndicatorMap XkbGetIndicatorMap_dylibloader_orig_xlib
+#define XkbSetIndicatorMap XkbSetIndicatorMap_dylibloader_orig_xlib
+#define XkbGetNamedIndicator XkbGetNamedIndicator_dylibloader_orig_xlib
+#define XkbGetNamedDeviceIndicator XkbGetNamedDeviceIndicator_dylibloader_orig_xlib
+#define XkbSetNamedIndicator XkbSetNamedIndicator_dylibloader_orig_xlib
+#define XkbSetNamedDeviceIndicator XkbSetNamedDeviceIndicator_dylibloader_orig_xlib
+#define XkbLockModifiers XkbLockModifiers_dylibloader_orig_xlib
+#define XkbLatchModifiers XkbLatchModifiers_dylibloader_orig_xlib
+#define XkbLockGroup XkbLockGroup_dylibloader_orig_xlib
+#define XkbLatchGroup XkbLatchGroup_dylibloader_orig_xlib
+#define XkbSetServerInternalMods XkbSetServerInternalMods_dylibloader_orig_xlib
+#define XkbSetIgnoreLockMods XkbSetIgnoreLockMods_dylibloader_orig_xlib
+#define XkbVirtualModsToReal XkbVirtualModsToReal_dylibloader_orig_xlib
+#define XkbComputeEffectiveMap XkbComputeEffectiveMap_dylibloader_orig_xlib
+#define XkbInitCanonicalKeyTypes XkbInitCanonicalKeyTypes_dylibloader_orig_xlib
+#define XkbAllocKeyboard XkbAllocKeyboard_dylibloader_orig_xlib
+#define XkbFreeKeyboard XkbFreeKeyboard_dylibloader_orig_xlib
+#define XkbAllocClientMap XkbAllocClientMap_dylibloader_orig_xlib
+#define XkbAllocServerMap XkbAllocServerMap_dylibloader_orig_xlib
+#define XkbFreeClientMap XkbFreeClientMap_dylibloader_orig_xlib
+#define XkbFreeServerMap XkbFreeServerMap_dylibloader_orig_xlib
+#define XkbAddKeyType XkbAddKeyType_dylibloader_orig_xlib
+#define XkbAllocIndicatorMaps XkbAllocIndicatorMaps_dylibloader_orig_xlib
+#define XkbFreeIndicatorMaps XkbFreeIndicatorMaps_dylibloader_orig_xlib
+#define XkbGetMap XkbGetMap_dylibloader_orig_xlib
+#define XkbGetUpdatedMap XkbGetUpdatedMap_dylibloader_orig_xlib
+#define XkbGetMapChanges XkbGetMapChanges_dylibloader_orig_xlib
+#define XkbRefreshKeyboardMapping XkbRefreshKeyboardMapping_dylibloader_orig_xlib
+#define XkbGetKeyTypes XkbGetKeyTypes_dylibloader_orig_xlib
+#define XkbGetKeySyms XkbGetKeySyms_dylibloader_orig_xlib
+#define XkbGetKeyActions XkbGetKeyActions_dylibloader_orig_xlib
+#define XkbGetKeyBehaviors XkbGetKeyBehaviors_dylibloader_orig_xlib
+#define XkbGetVirtualMods XkbGetVirtualMods_dylibloader_orig_xlib
+#define XkbGetKeyExplicitComponents XkbGetKeyExplicitComponents_dylibloader_orig_xlib
+#define XkbGetKeyModifierMap XkbGetKeyModifierMap_dylibloader_orig_xlib
+#define XkbGetKeyVirtualModMap XkbGetKeyVirtualModMap_dylibloader_orig_xlib
+#define XkbAllocControls XkbAllocControls_dylibloader_orig_xlib
+#define XkbFreeControls XkbFreeControls_dylibloader_orig_xlib
+#define XkbGetControls XkbGetControls_dylibloader_orig_xlib
+#define XkbSetControls XkbSetControls_dylibloader_orig_xlib
+#define XkbNoteControlsChanges XkbNoteControlsChanges_dylibloader_orig_xlib
+#define XkbAllocCompatMap XkbAllocCompatMap_dylibloader_orig_xlib
+#define XkbFreeCompatMap XkbFreeCompatMap_dylibloader_orig_xlib
+#define XkbGetCompatMap XkbGetCompatMap_dylibloader_orig_xlib
+#define XkbSetCompatMap XkbSetCompatMap_dylibloader_orig_xlib
+#define XkbAllocNames XkbAllocNames_dylibloader_orig_xlib
+#define XkbGetNames XkbGetNames_dylibloader_orig_xlib
+#define XkbSetNames XkbSetNames_dylibloader_orig_xlib
+#define XkbChangeNames XkbChangeNames_dylibloader_orig_xlib
+#define XkbFreeNames XkbFreeNames_dylibloader_orig_xlib
+#define XkbGetState XkbGetState_dylibloader_orig_xlib
+#define XkbSetMap XkbSetMap_dylibloader_orig_xlib
+#define XkbChangeMap XkbChangeMap_dylibloader_orig_xlib
+#define XkbSetDetectableAutoRepeat XkbSetDetectableAutoRepeat_dylibloader_orig_xlib
+#define XkbGetDetectableAutoRepeat XkbGetDetectableAutoRepeat_dylibloader_orig_xlib
+#define XkbSetAutoResetControls XkbSetAutoResetControls_dylibloader_orig_xlib
+#define XkbGetAutoResetControls XkbGetAutoResetControls_dylibloader_orig_xlib
+#define XkbSetPerClientControls XkbSetPerClientControls_dylibloader_orig_xlib
+#define XkbGetPerClientControls XkbGetPerClientControls_dylibloader_orig_xlib
+#define XkbCopyKeyType XkbCopyKeyType_dylibloader_orig_xlib
+#define XkbCopyKeyTypes XkbCopyKeyTypes_dylibloader_orig_xlib
+#define XkbResizeKeyType XkbResizeKeyType_dylibloader_orig_xlib
+#define XkbResizeKeySyms XkbResizeKeySyms_dylibloader_orig_xlib
+#define XkbResizeKeyActions XkbResizeKeyActions_dylibloader_orig_xlib
+#define XkbChangeTypesOfKey XkbChangeTypesOfKey_dylibloader_orig_xlib
+#define XkbChangeKeycodeRange XkbChangeKeycodeRange_dylibloader_orig_xlib
+#define XkbListComponents XkbListComponents_dylibloader_orig_xlib
+#define XkbFreeComponentList XkbFreeComponentList_dylibloader_orig_xlib
+#define XkbGetKeyboard XkbGetKeyboard_dylibloader_orig_xlib
+#define XkbGetKeyboardByName XkbGetKeyboardByName_dylibloader_orig_xlib
+#define XkbKeyTypesForCoreSymbols XkbKeyTypesForCoreSymbols_dylibloader_orig_xlib
+#define XkbApplyCompatMapToKey XkbApplyCompatMapToKey_dylibloader_orig_xlib
+#define XkbUpdateMapFromCore XkbUpdateMapFromCore_dylibloader_orig_xlib
+#define XkbAddDeviceLedInfo XkbAddDeviceLedInfo_dylibloader_orig_xlib
+#define XkbResizeDeviceButtonActions XkbResizeDeviceButtonActions_dylibloader_orig_xlib
+#define XkbAllocDeviceInfo XkbAllocDeviceInfo_dylibloader_orig_xlib
+#define XkbFreeDeviceInfo XkbFreeDeviceInfo_dylibloader_orig_xlib
+#define XkbNoteDeviceChanges XkbNoteDeviceChanges_dylibloader_orig_xlib
+#define XkbGetDeviceInfo XkbGetDeviceInfo_dylibloader_orig_xlib
+#define XkbGetDeviceInfoChanges XkbGetDeviceInfoChanges_dylibloader_orig_xlib
+#define XkbGetDeviceButtonActions XkbGetDeviceButtonActions_dylibloader_orig_xlib
+#define XkbGetDeviceLedInfo XkbGetDeviceLedInfo_dylibloader_orig_xlib
+#define XkbSetDeviceInfo XkbSetDeviceInfo_dylibloader_orig_xlib
+#define XkbChangeDeviceInfo XkbChangeDeviceInfo_dylibloader_orig_xlib
+#define XkbSetDeviceLedInfo XkbSetDeviceLedInfo_dylibloader_orig_xlib
+#define XkbSetDeviceButtonActions XkbSetDeviceButtonActions_dylibloader_orig_xlib
+#define XkbToControl XkbToControl_dylibloader_orig_xlib
+#define XkbSetDebuggingFlags XkbSetDebuggingFlags_dylibloader_orig_xlib
+#define XkbApplyVirtualModChanges XkbApplyVirtualModChanges_dylibloader_orig_xlib
+#define XkbUpdateActionVirtualMods XkbUpdateActionVirtualMods_dylibloader_orig_xlib
+#define XkbUpdateKeyTypeVirtualMods XkbUpdateKeyTypeVirtualMods_dylibloader_orig_xlib
+#include "thirdparty/linuxbsd_headers/X11/Xlib.h"
+#include "thirdparty/linuxbsd_headers/X11/Xutil.h"
+#include "thirdparty/linuxbsd_headers/X11/XKBlib.h"
+#undef _Xmblen
+#undef XLoadQueryFont
+#undef XQueryFont
+#undef XGetMotionEvents
+#undef XDeleteModifiermapEntry
+#undef XGetModifierMapping
+#undef XInsertModifiermapEntry
+#undef XNewModifiermap
+#undef XCreateImage
+#undef XInitImage
+#undef XGetImage
+#undef XGetSubImage
+#undef XOpenDisplay
+#undef XrmInitialize
+#undef XFetchBytes
+#undef XFetchBuffer
+#undef XGetAtomName
+#undef XGetAtomNames
+#undef XGetDefault
+#undef XDisplayName
+#undef XKeysymToString
+#undef XSynchronize
+#undef XSetAfterFunction
+#undef XInternAtom
+#undef XInternAtoms
+#undef XCopyColormapAndFree
+#undef XCreateColormap
+#undef XCreatePixmapCursor
+#undef XCreateGlyphCursor
+#undef XCreateFontCursor
+#undef XLoadFont
+#undef XCreateGC
+#undef XGContextFromGC
+#undef XFlushGC
+#undef XCreatePixmap
+#undef XCreateBitmapFromData
+#undef XCreatePixmapFromBitmapData
+#undef XCreateSimpleWindow
+#undef XGetSelectionOwner
+#undef XCreateWindow
+#undef XListInstalledColormaps
+#undef XListFonts
+#undef XListFontsWithInfo
+#undef XGetFontPath
+#undef XListExtensions
+#undef XListProperties
+#undef XListHosts
+#undef XKeycodeToKeysym
+#undef XLookupKeysym
+#undef XGetKeyboardMapping
+#undef XStringToKeysym
+#undef XMaxRequestSize
+#undef XExtendedMaxRequestSize
+#undef XResourceManagerString
+#undef XScreenResourceString
+#undef XDisplayMotionBufferSize
+#undef XVisualIDFromVisual
+#undef XInitThreads
+#undef XLockDisplay
+#undef XUnlockDisplay
+#undef XInitExtension
+#undef XAddExtension
+#undef XFindOnExtensionList
+#undef XEHeadOfExtensionList
+#undef XRootWindow
+#undef XDefaultRootWindow
+#undef XRootWindowOfScreen
+#undef XDefaultVisual
+#undef XDefaultVisualOfScreen
+#undef XDefaultGC
+#undef XDefaultGCOfScreen
+#undef XBlackPixel
+#undef XWhitePixel
+#undef XAllPlanes
+#undef XBlackPixelOfScreen
+#undef XWhitePixelOfScreen
+#undef XNextRequest
+#undef XLastKnownRequestProcessed
+#undef XServerVendor
+#undef XDisplayString
+#undef XDefaultColormap
+#undef XDefaultColormapOfScreen
+#undef XDisplayOfScreen
+#undef XScreenOfDisplay
+#undef XDefaultScreenOfDisplay
+#undef XEventMaskOfScreen
+#undef XScreenNumberOfScreen
+#undef XSetErrorHandler
+#undef XSetIOErrorHandler
+#undef XListPixmapFormats
+#undef XListDepths
+#undef XReconfigureWMWindow
+#undef XGetWMProtocols
+#undef XSetWMProtocols
+#undef XIconifyWindow
+#undef XWithdrawWindow
+#undef XGetCommand
+#undef XGetWMColormapWindows
+#undef XSetWMColormapWindows
+#undef XFreeStringList
+#undef XSetTransientForHint
+#undef XActivateScreenSaver
+#undef XAddHost
+#undef XAddHosts
+#undef XAddToExtensionList
+#undef XAddToSaveSet
+#undef XAllocColor
+#undef XAllocColorCells
+#undef XAllocColorPlanes
+#undef XAllocNamedColor
+#undef XAllowEvents
+#undef XAutoRepeatOff
+#undef XAutoRepeatOn
+#undef XBell
+#undef XBitmapBitOrder
+#undef XBitmapPad
+#undef XBitmapUnit
+#undef XCellsOfScreen
+#undef XChangeActivePointerGrab
+#undef XChangeGC
+#undef XChangeKeyboardControl
+#undef XChangeKeyboardMapping
+#undef XChangePointerControl
+#undef XChangeProperty
+#undef XChangeSaveSet
+#undef XChangeWindowAttributes
+#undef XCheckIfEvent
+#undef XCheckMaskEvent
+#undef XCheckTypedEvent
+#undef XCheckTypedWindowEvent
+#undef XCheckWindowEvent
+#undef XCirculateSubwindows
+#undef XCirculateSubwindowsDown
+#undef XCirculateSubwindowsUp
+#undef XClearArea
+#undef XClearWindow
+#undef XCloseDisplay
+#undef XConfigureWindow
+#undef XConnectionNumber
+#undef XConvertSelection
+#undef XCopyArea
+#undef XCopyGC
+#undef XCopyPlane
+#undef XDefaultDepth
+#undef XDefaultDepthOfScreen
+#undef XDefaultScreen
+#undef XDefineCursor
+#undef XDeleteProperty
+#undef XDestroyWindow
+#undef XDestroySubwindows
+#undef XDoesBackingStore
+#undef XDoesSaveUnders
+#undef XDisableAccessControl
+#undef XDisplayCells
+#undef XDisplayHeight
+#undef XDisplayHeightMM
+#undef XDisplayKeycodes
+#undef XDisplayPlanes
+#undef XDisplayWidth
+#undef XDisplayWidthMM
+#undef XDrawArc
+#undef XDrawArcs
+#undef XDrawImageString
+#undef XDrawImageString16
+#undef XDrawLine
+#undef XDrawLines
+#undef XDrawPoint
+#undef XDrawPoints
+#undef XDrawRectangle
+#undef XDrawRectangles
+#undef XDrawSegments
+#undef XDrawString
+#undef XDrawString16
+#undef XDrawText
+#undef XDrawText16
+#undef XEnableAccessControl
+#undef XEventsQueued
+#undef XFetchName
+#undef XFillArc
+#undef XFillArcs
+#undef XFillPolygon
+#undef XFillRectangle
+#undef XFillRectangles
+#undef XFlush
+#undef XForceScreenSaver
+#undef XFree
+#undef XFreeColormap
+#undef XFreeColors
+#undef XFreeCursor
+#undef XFreeExtensionList
+#undef XFreeFont
+#undef XFreeFontInfo
+#undef XFreeFontNames
+#undef XFreeFontPath
+#undef XFreeGC
+#undef XFreeModifiermap
+#undef XFreePixmap
+#undef XGeometry
+#undef XGetErrorDatabaseText
+#undef XGetErrorText
+#undef XGetFontProperty
+#undef XGetGCValues
+#undef XGetGeometry
+#undef XGetIconName
+#undef XGetInputFocus
+#undef XGetKeyboardControl
+#undef XGetPointerControl
+#undef XGetPointerMapping
+#undef XGetScreenSaver
+#undef XGetTransientForHint
+#undef XGetWindowProperty
+#undef XGetWindowAttributes
+#undef XGrabButton
+#undef XGrabKey
+#undef XGrabKeyboard
+#undef XGrabPointer
+#undef XGrabServer
+#undef XHeightMMOfScreen
+#undef XHeightOfScreen
+#undef XIfEvent
+#undef XImageByteOrder
+#undef XInstallColormap
+#undef XKeysymToKeycode
+#undef XKillClient
+#undef XLookupColor
+#undef XLowerWindow
+#undef XMapRaised
+#undef XMapSubwindows
+#undef XMapWindow
+#undef XMaskEvent
+#undef XMaxCmapsOfScreen
+#undef XMinCmapsOfScreen
+#undef XMoveResizeWindow
+#undef XMoveWindow
+#undef XNextEvent
+#undef XNoOp
+#undef XParseColor
+#undef XParseGeometry
+#undef XPeekEvent
+#undef XPeekIfEvent
+#undef XPending
+#undef XPlanesOfScreen
+#undef XProtocolRevision
+#undef XProtocolVersion
+#undef XPutBackEvent
+#undef XPutImage
+#undef XQLength
+#undef XQueryBestCursor
+#undef XQueryBestSize
+#undef XQueryBestStipple
+#undef XQueryBestTile
+#undef XQueryColor
+#undef XQueryColors
+#undef XQueryExtension
+#undef XQueryKeymap
+#undef XQueryPointer
+#undef XQueryTextExtents
+#undef XQueryTextExtents16
+#undef XQueryTree
+#undef XRaiseWindow
+#undef XReadBitmapFile
+#undef XReadBitmapFileData
+#undef XRebindKeysym
+#undef XRecolorCursor
+#undef XRefreshKeyboardMapping
+#undef XRemoveFromSaveSet
+#undef XRemoveHost
+#undef XRemoveHosts
+#undef XReparentWindow
+#undef XResetScreenSaver
+#undef XResizeWindow
+#undef XRestackWindows
+#undef XRotateBuffers
+#undef XRotateWindowProperties
+#undef XScreenCount
+#undef XSelectInput
+#undef XSendEvent
+#undef XSetAccessControl
+#undef XSetArcMode
+#undef XSetBackground
+#undef XSetClipMask
+#undef XSetClipOrigin
+#undef XSetClipRectangles
+#undef XSetCloseDownMode
+#undef XSetCommand
+#undef XSetDashes
+#undef XSetFillRule
+#undef XSetFillStyle
+#undef XSetFont
+#undef XSetFontPath
+#undef XSetForeground
+#undef XSetFunction
+#undef XSetGraphicsExposures
+#undef XSetIconName
+#undef XSetInputFocus
+#undef XSetLineAttributes
+#undef XSetModifierMapping
+#undef XSetPlaneMask
+#undef XSetPointerMapping
+#undef XSetScreenSaver
+#undef XSetSelectionOwner
+#undef XSetState
+#undef XSetStipple
+#undef XSetSubwindowMode
+#undef XSetTSOrigin
+#undef XSetTile
+#undef XSetWindowBackground
+#undef XSetWindowBackgroundPixmap
+#undef XSetWindowBorder
+#undef XSetWindowBorderPixmap
+#undef XSetWindowBorderWidth
+#undef XSetWindowColormap
+#undef XStoreBuffer
+#undef XStoreBytes
+#undef XStoreColor
+#undef XStoreColors
+#undef XStoreName
+#undef XStoreNamedColor
+#undef XSync
+#undef XTextExtents
+#undef XTextExtents16
+#undef XTextWidth
+#undef XTextWidth16
+#undef XTranslateCoordinates
+#undef XUndefineCursor
+#undef XUngrabButton
+#undef XUngrabKey
+#undef XUngrabKeyboard
+#undef XUngrabPointer
+#undef XUngrabServer
+#undef XUninstallColormap
+#undef XUnloadFont
+#undef XUnmapSubwindows
+#undef XUnmapWindow
+#undef XVendorRelease
+#undef XWarpPointer
+#undef XWidthMMOfScreen
+#undef XWidthOfScreen
+#undef XWindowEvent
+#undef XWriteBitmapFile
+#undef XSupportsLocale
+#undef XSetLocaleModifiers
+#undef XOpenOM
+#undef XCloseOM
+#undef XSetOMValues
+#undef XGetOMValues
+#undef XDisplayOfOM
+#undef XLocaleOfOM
+#undef XCreateOC
+#undef XDestroyOC
+#undef XOMOfOC
+#undef XSetOCValues
+#undef XGetOCValues
+#undef XCreateFontSet
+#undef XFreeFontSet
+#undef XFontsOfFontSet
+#undef XBaseFontNameListOfFontSet
+#undef XLocaleOfFontSet
+#undef XContextDependentDrawing
+#undef XDirectionalDependentDrawing
+#undef XContextualDrawing
+#undef XExtentsOfFontSet
+#undef XmbTextEscapement
+#undef XwcTextEscapement
+#undef Xutf8TextEscapement
+#undef XmbTextExtents
+#undef XwcTextExtents
+#undef Xutf8TextExtents
+#undef XmbTextPerCharExtents
+#undef XwcTextPerCharExtents
+#undef Xutf8TextPerCharExtents
+#undef XmbDrawText
+#undef XwcDrawText
+#undef Xutf8DrawText
+#undef XmbDrawString
+#undef XwcDrawString
+#undef Xutf8DrawString
+#undef XmbDrawImageString
+#undef XwcDrawImageString
+#undef Xutf8DrawImageString
+#undef XOpenIM
+#undef XCloseIM
+#undef XGetIMValues
+#undef XSetIMValues
+#undef XDisplayOfIM
+#undef XLocaleOfIM
+#undef XCreateIC
+#undef XDestroyIC
+#undef XSetICFocus
+#undef XUnsetICFocus
+#undef XwcResetIC
+#undef XmbResetIC
+#undef Xutf8ResetIC
+#undef XSetICValues
+#undef XGetICValues
+#undef XIMOfIC
+#undef XFilterEvent
+#undef XmbLookupString
+#undef XwcLookupString
+#undef Xutf8LookupString
+#undef XVaCreateNestedList
+#undef XRegisterIMInstantiateCallback
+#undef XUnregisterIMInstantiateCallback
+#undef XInternalConnectionNumbers
+#undef XProcessInternalConnection
+#undef XAddConnectionWatch
+#undef XRemoveConnectionWatch
+#undef XSetAuthorization
+#undef _Xmbtowc
+#undef _Xwctomb
+#undef XGetEventData
+#undef XFreeEventData
+#undef XAllocClassHint
+#undef XAllocIconSize
+#undef XAllocSizeHints
+#undef XAllocStandardColormap
+#undef XAllocWMHints
+#undef XClipBox
+#undef XCreateRegion
+#undef XDefaultString
+#undef XDeleteContext
+#undef XDestroyRegion
+#undef XEmptyRegion
+#undef XEqualRegion
+#undef XFindContext
+#undef XGetClassHint
+#undef XGetIconSizes
+#undef XGetNormalHints
+#undef XGetRGBColormaps
+#undef XGetSizeHints
+#undef XGetStandardColormap
+#undef XGetTextProperty
+#undef XGetVisualInfo
+#undef XGetWMClientMachine
+#undef XGetWMHints
+#undef XGetWMIconName
+#undef XGetWMName
+#undef XGetWMNormalHints
+#undef XGetWMSizeHints
+#undef XGetZoomHints
+#undef XIntersectRegion
+#undef XConvertCase
+#undef XLookupString
+#undef XMatchVisualInfo
+#undef XOffsetRegion
+#undef XPointInRegion
+#undef XPolygonRegion
+#undef XRectInRegion
+#undef XSaveContext
+#undef XSetClassHint
+#undef XSetIconSizes
+#undef XSetNormalHints
+#undef XSetRGBColormaps
+#undef XSetSizeHints
+#undef XSetStandardProperties
+#undef XSetTextProperty
+#undef XSetWMClientMachine
+#undef XSetWMHints
+#undef XSetWMIconName
+#undef XSetWMName
+#undef XSetWMNormalHints
+#undef XSetWMProperties
+#undef XmbSetWMProperties
+#undef Xutf8SetWMProperties
+#undef XSetWMSizeHints
+#undef XSetRegion
+#undef XSetStandardColormap
+#undef XSetZoomHints
+#undef XShrinkRegion
+#undef XStringListToTextProperty
+#undef XSubtractRegion
+#undef XmbTextListToTextProperty
+#undef XwcTextListToTextProperty
+#undef Xutf8TextListToTextProperty
+#undef XwcFreeStringList
+#undef XTextPropertyToStringList
+#undef XmbTextPropertyToTextList
+#undef XwcTextPropertyToTextList
+#undef Xutf8TextPropertyToTextList
+#undef XUnionRectWithRegion
+#undef XUnionRegion
+#undef XWMGeometry
+#undef XXorRegion
+#undef XkbIgnoreExtension
+#undef XkbOpenDisplay
+#undef XkbQueryExtension
+#undef XkbUseExtension
+#undef XkbLibraryVersion
+#undef XkbSetXlibControls
+#undef XkbGetXlibControls
+#undef XkbXlibControlsImplemented
+#undef XkbSetAtomFuncs
+#undef XkbKeycodeToKeysym
+#undef XkbKeysymToModifiers
+#undef XkbLookupKeySym
+#undef XkbLookupKeyBinding
+#undef XkbTranslateKeyCode
+#undef XkbTranslateKeySym
+#undef XkbSetAutoRepeatRate
+#undef XkbGetAutoRepeatRate
+#undef XkbChangeEnabledControls
+#undef XkbDeviceBell
+#undef XkbForceDeviceBell
+#undef XkbDeviceBellEvent
+#undef XkbBell
+#undef XkbForceBell
+#undef XkbBellEvent
+#undef XkbSelectEvents
+#undef XkbSelectEventDetails
+#undef XkbNoteMapChanges
+#undef XkbNoteNameChanges
+#undef XkbGetIndicatorState
+#undef XkbGetIndicatorMap
+#undef XkbSetIndicatorMap
+#undef XkbGetNamedIndicator
+#undef XkbGetNamedDeviceIndicator
+#undef XkbSetNamedIndicator
+#undef XkbSetNamedDeviceIndicator
+#undef XkbLockModifiers
+#undef XkbLatchModifiers
+#undef XkbLockGroup
+#undef XkbLatchGroup
+#undef XkbSetServerInternalMods
+#undef XkbSetIgnoreLockMods
+#undef XkbVirtualModsToReal
+#undef XkbComputeEffectiveMap
+#undef XkbInitCanonicalKeyTypes
+#undef XkbAllocKeyboard
+#undef XkbFreeKeyboard
+#undef XkbAllocClientMap
+#undef XkbAllocServerMap
+#undef XkbFreeClientMap
+#undef XkbFreeServerMap
+#undef XkbAddKeyType
+#undef XkbAllocIndicatorMaps
+#undef XkbFreeIndicatorMaps
+#undef XkbGetMap
+#undef XkbGetUpdatedMap
+#undef XkbGetMapChanges
+#undef XkbRefreshKeyboardMapping
+#undef XkbGetKeyTypes
+#undef XkbGetKeySyms
+#undef XkbGetKeyActions
+#undef XkbGetKeyBehaviors
+#undef XkbGetVirtualMods
+#undef XkbGetKeyExplicitComponents
+#undef XkbGetKeyModifierMap
+#undef XkbGetKeyVirtualModMap
+#undef XkbAllocControls
+#undef XkbFreeControls
+#undef XkbGetControls
+#undef XkbSetControls
+#undef XkbNoteControlsChanges
+#undef XkbAllocCompatMap
+#undef XkbFreeCompatMap
+#undef XkbGetCompatMap
+#undef XkbSetCompatMap
+#undef XkbAllocNames
+#undef XkbGetNames
+#undef XkbSetNames
+#undef XkbChangeNames
+#undef XkbFreeNames
+#undef XkbGetState
+#undef XkbSetMap
+#undef XkbChangeMap
+#undef XkbSetDetectableAutoRepeat
+#undef XkbGetDetectableAutoRepeat
+#undef XkbSetAutoResetControls
+#undef XkbGetAutoResetControls
+#undef XkbSetPerClientControls
+#undef XkbGetPerClientControls
+#undef XkbCopyKeyType
+#undef XkbCopyKeyTypes
+#undef XkbResizeKeyType
+#undef XkbResizeKeySyms
+#undef XkbResizeKeyActions
+#undef XkbChangeTypesOfKey
+#undef XkbChangeKeycodeRange
+#undef XkbListComponents
+#undef XkbFreeComponentList
+#undef XkbGetKeyboard
+#undef XkbGetKeyboardByName
+#undef XkbKeyTypesForCoreSymbols
+#undef XkbApplyCompatMapToKey
+#undef XkbUpdateMapFromCore
+#undef XkbAddDeviceLedInfo
+#undef XkbResizeDeviceButtonActions
+#undef XkbAllocDeviceInfo
+#undef XkbFreeDeviceInfo
+#undef XkbNoteDeviceChanges
+#undef XkbGetDeviceInfo
+#undef XkbGetDeviceInfoChanges
+#undef XkbGetDeviceButtonActions
+#undef XkbGetDeviceLedInfo
+#undef XkbSetDeviceInfo
+#undef XkbChangeDeviceInfo
+#undef XkbSetDeviceLedInfo
+#undef XkbSetDeviceButtonActions
+#undef XkbToControl
+#undef XkbSetDebuggingFlags
+#undef XkbApplyVirtualModChanges
+#undef XkbUpdateActionVirtualMods
+#undef XkbUpdateKeyTypeVirtualMods
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define _Xmblen _Xmblen_dylibloader_wrapper_xlib
+#define XLoadQueryFont XLoadQueryFont_dylibloader_wrapper_xlib
+#define XQueryFont XQueryFont_dylibloader_wrapper_xlib
+#define XGetMotionEvents XGetMotionEvents_dylibloader_wrapper_xlib
+#define XDeleteModifiermapEntry XDeleteModifiermapEntry_dylibloader_wrapper_xlib
+#define XGetModifierMapping XGetModifierMapping_dylibloader_wrapper_xlib
+#define XInsertModifiermapEntry XInsertModifiermapEntry_dylibloader_wrapper_xlib
+#define XNewModifiermap XNewModifiermap_dylibloader_wrapper_xlib
+#define XCreateImage XCreateImage_dylibloader_wrapper_xlib
+#define XInitImage XInitImage_dylibloader_wrapper_xlib
+#define XGetImage XGetImage_dylibloader_wrapper_xlib
+#define XGetSubImage XGetSubImage_dylibloader_wrapper_xlib
+#define XOpenDisplay XOpenDisplay_dylibloader_wrapper_xlib
+#define XrmInitialize XrmInitialize_dylibloader_wrapper_xlib
+#define XFetchBytes XFetchBytes_dylibloader_wrapper_xlib
+#define XFetchBuffer XFetchBuffer_dylibloader_wrapper_xlib
+#define XGetAtomName XGetAtomName_dylibloader_wrapper_xlib
+#define XGetAtomNames XGetAtomNames_dylibloader_wrapper_xlib
+#define XGetDefault XGetDefault_dylibloader_wrapper_xlib
+#define XDisplayName XDisplayName_dylibloader_wrapper_xlib
+#define XKeysymToString XKeysymToString_dylibloader_wrapper_xlib
+#define XSynchronize XSynchronize_dylibloader_wrapper_xlib
+#define XSetAfterFunction XSetAfterFunction_dylibloader_wrapper_xlib
+#define XInternAtom XInternAtom_dylibloader_wrapper_xlib
+#define XInternAtoms XInternAtoms_dylibloader_wrapper_xlib
+#define XCopyColormapAndFree XCopyColormapAndFree_dylibloader_wrapper_xlib
+#define XCreateColormap XCreateColormap_dylibloader_wrapper_xlib
+#define XCreatePixmapCursor XCreatePixmapCursor_dylibloader_wrapper_xlib
+#define XCreateGlyphCursor XCreateGlyphCursor_dylibloader_wrapper_xlib
+#define XCreateFontCursor XCreateFontCursor_dylibloader_wrapper_xlib
+#define XLoadFont XLoadFont_dylibloader_wrapper_xlib
+#define XCreateGC XCreateGC_dylibloader_wrapper_xlib
+#define XGContextFromGC XGContextFromGC_dylibloader_wrapper_xlib
+#define XFlushGC XFlushGC_dylibloader_wrapper_xlib
+#define XCreatePixmap XCreatePixmap_dylibloader_wrapper_xlib
+#define XCreateBitmapFromData XCreateBitmapFromData_dylibloader_wrapper_xlib
+#define XCreatePixmapFromBitmapData XCreatePixmapFromBitmapData_dylibloader_wrapper_xlib
+#define XCreateSimpleWindow XCreateSimpleWindow_dylibloader_wrapper_xlib
+#define XGetSelectionOwner XGetSelectionOwner_dylibloader_wrapper_xlib
+#define XCreateWindow XCreateWindow_dylibloader_wrapper_xlib
+#define XListInstalledColormaps XListInstalledColormaps_dylibloader_wrapper_xlib
+#define XListFonts XListFonts_dylibloader_wrapper_xlib
+#define XListFontsWithInfo XListFontsWithInfo_dylibloader_wrapper_xlib
+#define XGetFontPath XGetFontPath_dylibloader_wrapper_xlib
+#define XListExtensions XListExtensions_dylibloader_wrapper_xlib
+#define XListProperties XListProperties_dylibloader_wrapper_xlib
+#define XListHosts XListHosts_dylibloader_wrapper_xlib
+#define XKeycodeToKeysym XKeycodeToKeysym_dylibloader_wrapper_xlib
+#define XLookupKeysym XLookupKeysym_dylibloader_wrapper_xlib
+#define XGetKeyboardMapping XGetKeyboardMapping_dylibloader_wrapper_xlib
+#define XStringToKeysym XStringToKeysym_dylibloader_wrapper_xlib
+#define XMaxRequestSize XMaxRequestSize_dylibloader_wrapper_xlib
+#define XExtendedMaxRequestSize XExtendedMaxRequestSize_dylibloader_wrapper_xlib
+#define XResourceManagerString XResourceManagerString_dylibloader_wrapper_xlib
+#define XScreenResourceString XScreenResourceString_dylibloader_wrapper_xlib
+#define XDisplayMotionBufferSize XDisplayMotionBufferSize_dylibloader_wrapper_xlib
+#define XVisualIDFromVisual XVisualIDFromVisual_dylibloader_wrapper_xlib
+#define XInitThreads XInitThreads_dylibloader_wrapper_xlib
+#define XLockDisplay XLockDisplay_dylibloader_wrapper_xlib
+#define XUnlockDisplay XUnlockDisplay_dylibloader_wrapper_xlib
+#define XInitExtension XInitExtension_dylibloader_wrapper_xlib
+#define XAddExtension XAddExtension_dylibloader_wrapper_xlib
+#define XFindOnExtensionList XFindOnExtensionList_dylibloader_wrapper_xlib
+#define XEHeadOfExtensionList XEHeadOfExtensionList_dylibloader_wrapper_xlib
+#define XRootWindow XRootWindow_dylibloader_wrapper_xlib
+#define XDefaultRootWindow XDefaultRootWindow_dylibloader_wrapper_xlib
+#define XRootWindowOfScreen XRootWindowOfScreen_dylibloader_wrapper_xlib
+#define XDefaultVisual XDefaultVisual_dylibloader_wrapper_xlib
+#define XDefaultVisualOfScreen XDefaultVisualOfScreen_dylibloader_wrapper_xlib
+#define XDefaultGC XDefaultGC_dylibloader_wrapper_xlib
+#define XDefaultGCOfScreen XDefaultGCOfScreen_dylibloader_wrapper_xlib
+#define XBlackPixel XBlackPixel_dylibloader_wrapper_xlib
+#define XWhitePixel XWhitePixel_dylibloader_wrapper_xlib
+#define XAllPlanes XAllPlanes_dylibloader_wrapper_xlib
+#define XBlackPixelOfScreen XBlackPixelOfScreen_dylibloader_wrapper_xlib
+#define XWhitePixelOfScreen XWhitePixelOfScreen_dylibloader_wrapper_xlib
+#define XNextRequest XNextRequest_dylibloader_wrapper_xlib
+#define XLastKnownRequestProcessed XLastKnownRequestProcessed_dylibloader_wrapper_xlib
+#define XServerVendor XServerVendor_dylibloader_wrapper_xlib
+#define XDisplayString XDisplayString_dylibloader_wrapper_xlib
+#define XDefaultColormap XDefaultColormap_dylibloader_wrapper_xlib
+#define XDefaultColormapOfScreen XDefaultColormapOfScreen_dylibloader_wrapper_xlib
+#define XDisplayOfScreen XDisplayOfScreen_dylibloader_wrapper_xlib
+#define XScreenOfDisplay XScreenOfDisplay_dylibloader_wrapper_xlib
+#define XDefaultScreenOfDisplay XDefaultScreenOfDisplay_dylibloader_wrapper_xlib
+#define XEventMaskOfScreen XEventMaskOfScreen_dylibloader_wrapper_xlib
+#define XScreenNumberOfScreen XScreenNumberOfScreen_dylibloader_wrapper_xlib
+#define XSetErrorHandler XSetErrorHandler_dylibloader_wrapper_xlib
+#define XSetIOErrorHandler XSetIOErrorHandler_dylibloader_wrapper_xlib
+#define XListPixmapFormats XListPixmapFormats_dylibloader_wrapper_xlib
+#define XListDepths XListDepths_dylibloader_wrapper_xlib
+#define XReconfigureWMWindow XReconfigureWMWindow_dylibloader_wrapper_xlib
+#define XGetWMProtocols XGetWMProtocols_dylibloader_wrapper_xlib
+#define XSetWMProtocols XSetWMProtocols_dylibloader_wrapper_xlib
+#define XIconifyWindow XIconifyWindow_dylibloader_wrapper_xlib
+#define XWithdrawWindow XWithdrawWindow_dylibloader_wrapper_xlib
+#define XGetCommand XGetCommand_dylibloader_wrapper_xlib
+#define XGetWMColormapWindows XGetWMColormapWindows_dylibloader_wrapper_xlib
+#define XSetWMColormapWindows XSetWMColormapWindows_dylibloader_wrapper_xlib
+#define XFreeStringList XFreeStringList_dylibloader_wrapper_xlib
+#define XSetTransientForHint XSetTransientForHint_dylibloader_wrapper_xlib
+#define XActivateScreenSaver XActivateScreenSaver_dylibloader_wrapper_xlib
+#define XAddHost XAddHost_dylibloader_wrapper_xlib
+#define XAddHosts XAddHosts_dylibloader_wrapper_xlib
+#define XAddToExtensionList XAddToExtensionList_dylibloader_wrapper_xlib
+#define XAddToSaveSet XAddToSaveSet_dylibloader_wrapper_xlib
+#define XAllocColor XAllocColor_dylibloader_wrapper_xlib
+#define XAllocColorCells XAllocColorCells_dylibloader_wrapper_xlib
+#define XAllocColorPlanes XAllocColorPlanes_dylibloader_wrapper_xlib
+#define XAllocNamedColor XAllocNamedColor_dylibloader_wrapper_xlib
+#define XAllowEvents XAllowEvents_dylibloader_wrapper_xlib
+#define XAutoRepeatOff XAutoRepeatOff_dylibloader_wrapper_xlib
+#define XAutoRepeatOn XAutoRepeatOn_dylibloader_wrapper_xlib
+#define XBell XBell_dylibloader_wrapper_xlib
+#define XBitmapBitOrder XBitmapBitOrder_dylibloader_wrapper_xlib
+#define XBitmapPad XBitmapPad_dylibloader_wrapper_xlib
+#define XBitmapUnit XBitmapUnit_dylibloader_wrapper_xlib
+#define XCellsOfScreen XCellsOfScreen_dylibloader_wrapper_xlib
+#define XChangeActivePointerGrab XChangeActivePointerGrab_dylibloader_wrapper_xlib
+#define XChangeGC XChangeGC_dylibloader_wrapper_xlib
+#define XChangeKeyboardControl XChangeKeyboardControl_dylibloader_wrapper_xlib
+#define XChangeKeyboardMapping XChangeKeyboardMapping_dylibloader_wrapper_xlib
+#define XChangePointerControl XChangePointerControl_dylibloader_wrapper_xlib
+#define XChangeProperty XChangeProperty_dylibloader_wrapper_xlib
+#define XChangeSaveSet XChangeSaveSet_dylibloader_wrapper_xlib
+#define XChangeWindowAttributes XChangeWindowAttributes_dylibloader_wrapper_xlib
+#define XCheckIfEvent XCheckIfEvent_dylibloader_wrapper_xlib
+#define XCheckMaskEvent XCheckMaskEvent_dylibloader_wrapper_xlib
+#define XCheckTypedEvent XCheckTypedEvent_dylibloader_wrapper_xlib
+#define XCheckTypedWindowEvent XCheckTypedWindowEvent_dylibloader_wrapper_xlib
+#define XCheckWindowEvent XCheckWindowEvent_dylibloader_wrapper_xlib
+#define XCirculateSubwindows XCirculateSubwindows_dylibloader_wrapper_xlib
+#define XCirculateSubwindowsDown XCirculateSubwindowsDown_dylibloader_wrapper_xlib
+#define XCirculateSubwindowsUp XCirculateSubwindowsUp_dylibloader_wrapper_xlib
+#define XClearArea XClearArea_dylibloader_wrapper_xlib
+#define XClearWindow XClearWindow_dylibloader_wrapper_xlib
+#define XCloseDisplay XCloseDisplay_dylibloader_wrapper_xlib
+#define XConfigureWindow XConfigureWindow_dylibloader_wrapper_xlib
+#define XConnectionNumber XConnectionNumber_dylibloader_wrapper_xlib
+#define XConvertSelection XConvertSelection_dylibloader_wrapper_xlib
+#define XCopyArea XCopyArea_dylibloader_wrapper_xlib
+#define XCopyGC XCopyGC_dylibloader_wrapper_xlib
+#define XCopyPlane XCopyPlane_dylibloader_wrapper_xlib
+#define XDefaultDepth XDefaultDepth_dylibloader_wrapper_xlib
+#define XDefaultDepthOfScreen XDefaultDepthOfScreen_dylibloader_wrapper_xlib
+#define XDefaultScreen XDefaultScreen_dylibloader_wrapper_xlib
+#define XDefineCursor XDefineCursor_dylibloader_wrapper_xlib
+#define XDeleteProperty XDeleteProperty_dylibloader_wrapper_xlib
+#define XDestroyWindow XDestroyWindow_dylibloader_wrapper_xlib
+#define XDestroySubwindows XDestroySubwindows_dylibloader_wrapper_xlib
+#define XDoesBackingStore XDoesBackingStore_dylibloader_wrapper_xlib
+#define XDoesSaveUnders XDoesSaveUnders_dylibloader_wrapper_xlib
+#define XDisableAccessControl XDisableAccessControl_dylibloader_wrapper_xlib
+#define XDisplayCells XDisplayCells_dylibloader_wrapper_xlib
+#define XDisplayHeight XDisplayHeight_dylibloader_wrapper_xlib
+#define XDisplayHeightMM XDisplayHeightMM_dylibloader_wrapper_xlib
+#define XDisplayKeycodes XDisplayKeycodes_dylibloader_wrapper_xlib
+#define XDisplayPlanes XDisplayPlanes_dylibloader_wrapper_xlib
+#define XDisplayWidth XDisplayWidth_dylibloader_wrapper_xlib
+#define XDisplayWidthMM XDisplayWidthMM_dylibloader_wrapper_xlib
+#define XDrawArc XDrawArc_dylibloader_wrapper_xlib
+#define XDrawArcs XDrawArcs_dylibloader_wrapper_xlib
+#define XDrawImageString XDrawImageString_dylibloader_wrapper_xlib
+#define XDrawImageString16 XDrawImageString16_dylibloader_wrapper_xlib
+#define XDrawLine XDrawLine_dylibloader_wrapper_xlib
+#define XDrawLines XDrawLines_dylibloader_wrapper_xlib
+#define XDrawPoint XDrawPoint_dylibloader_wrapper_xlib
+#define XDrawPoints XDrawPoints_dylibloader_wrapper_xlib
+#define XDrawRectangle XDrawRectangle_dylibloader_wrapper_xlib
+#define XDrawRectangles XDrawRectangles_dylibloader_wrapper_xlib
+#define XDrawSegments XDrawSegments_dylibloader_wrapper_xlib
+#define XDrawString XDrawString_dylibloader_wrapper_xlib
+#define XDrawString16 XDrawString16_dylibloader_wrapper_xlib
+#define XDrawText XDrawText_dylibloader_wrapper_xlib
+#define XDrawText16 XDrawText16_dylibloader_wrapper_xlib
+#define XEnableAccessControl XEnableAccessControl_dylibloader_wrapper_xlib
+#define XEventsQueued XEventsQueued_dylibloader_wrapper_xlib
+#define XFetchName XFetchName_dylibloader_wrapper_xlib
+#define XFillArc XFillArc_dylibloader_wrapper_xlib
+#define XFillArcs XFillArcs_dylibloader_wrapper_xlib
+#define XFillPolygon XFillPolygon_dylibloader_wrapper_xlib
+#define XFillRectangle XFillRectangle_dylibloader_wrapper_xlib
+#define XFillRectangles XFillRectangles_dylibloader_wrapper_xlib
+#define XFlush XFlush_dylibloader_wrapper_xlib
+#define XForceScreenSaver XForceScreenSaver_dylibloader_wrapper_xlib
+#define XFree XFree_dylibloader_wrapper_xlib
+#define XFreeColormap XFreeColormap_dylibloader_wrapper_xlib
+#define XFreeColors XFreeColors_dylibloader_wrapper_xlib
+#define XFreeCursor XFreeCursor_dylibloader_wrapper_xlib
+#define XFreeExtensionList XFreeExtensionList_dylibloader_wrapper_xlib
+#define XFreeFont XFreeFont_dylibloader_wrapper_xlib
+#define XFreeFontInfo XFreeFontInfo_dylibloader_wrapper_xlib
+#define XFreeFontNames XFreeFontNames_dylibloader_wrapper_xlib
+#define XFreeFontPath XFreeFontPath_dylibloader_wrapper_xlib
+#define XFreeGC XFreeGC_dylibloader_wrapper_xlib
+#define XFreeModifiermap XFreeModifiermap_dylibloader_wrapper_xlib
+#define XFreePixmap XFreePixmap_dylibloader_wrapper_xlib
+#define XGeometry XGeometry_dylibloader_wrapper_xlib
+#define XGetErrorDatabaseText XGetErrorDatabaseText_dylibloader_wrapper_xlib
+#define XGetErrorText XGetErrorText_dylibloader_wrapper_xlib
+#define XGetFontProperty XGetFontProperty_dylibloader_wrapper_xlib
+#define XGetGCValues XGetGCValues_dylibloader_wrapper_xlib
+#define XGetGeometry XGetGeometry_dylibloader_wrapper_xlib
+#define XGetIconName XGetIconName_dylibloader_wrapper_xlib
+#define XGetInputFocus XGetInputFocus_dylibloader_wrapper_xlib
+#define XGetKeyboardControl XGetKeyboardControl_dylibloader_wrapper_xlib
+#define XGetPointerControl XGetPointerControl_dylibloader_wrapper_xlib
+#define XGetPointerMapping XGetPointerMapping_dylibloader_wrapper_xlib
+#define XGetScreenSaver XGetScreenSaver_dylibloader_wrapper_xlib
+#define XGetTransientForHint XGetTransientForHint_dylibloader_wrapper_xlib
+#define XGetWindowProperty XGetWindowProperty_dylibloader_wrapper_xlib
+#define XGetWindowAttributes XGetWindowAttributes_dylibloader_wrapper_xlib
+#define XGrabButton XGrabButton_dylibloader_wrapper_xlib
+#define XGrabKey XGrabKey_dylibloader_wrapper_xlib
+#define XGrabKeyboard XGrabKeyboard_dylibloader_wrapper_xlib
+#define XGrabPointer XGrabPointer_dylibloader_wrapper_xlib
+#define XGrabServer XGrabServer_dylibloader_wrapper_xlib
+#define XHeightMMOfScreen XHeightMMOfScreen_dylibloader_wrapper_xlib
+#define XHeightOfScreen XHeightOfScreen_dylibloader_wrapper_xlib
+#define XIfEvent XIfEvent_dylibloader_wrapper_xlib
+#define XImageByteOrder XImageByteOrder_dylibloader_wrapper_xlib
+#define XInstallColormap XInstallColormap_dylibloader_wrapper_xlib
+#define XKeysymToKeycode XKeysymToKeycode_dylibloader_wrapper_xlib
+#define XKillClient XKillClient_dylibloader_wrapper_xlib
+#define XLookupColor XLookupColor_dylibloader_wrapper_xlib
+#define XLowerWindow XLowerWindow_dylibloader_wrapper_xlib
+#define XMapRaised XMapRaised_dylibloader_wrapper_xlib
+#define XMapSubwindows XMapSubwindows_dylibloader_wrapper_xlib
+#define XMapWindow XMapWindow_dylibloader_wrapper_xlib
+#define XMaskEvent XMaskEvent_dylibloader_wrapper_xlib
+#define XMaxCmapsOfScreen XMaxCmapsOfScreen_dylibloader_wrapper_xlib
+#define XMinCmapsOfScreen XMinCmapsOfScreen_dylibloader_wrapper_xlib
+#define XMoveResizeWindow XMoveResizeWindow_dylibloader_wrapper_xlib
+#define XMoveWindow XMoveWindow_dylibloader_wrapper_xlib
+#define XNextEvent XNextEvent_dylibloader_wrapper_xlib
+#define XNoOp XNoOp_dylibloader_wrapper_xlib
+#define XParseColor XParseColor_dylibloader_wrapper_xlib
+#define XParseGeometry XParseGeometry_dylibloader_wrapper_xlib
+#define XPeekEvent XPeekEvent_dylibloader_wrapper_xlib
+#define XPeekIfEvent XPeekIfEvent_dylibloader_wrapper_xlib
+#define XPending XPending_dylibloader_wrapper_xlib
+#define XPlanesOfScreen XPlanesOfScreen_dylibloader_wrapper_xlib
+#define XProtocolRevision XProtocolRevision_dylibloader_wrapper_xlib
+#define XProtocolVersion XProtocolVersion_dylibloader_wrapper_xlib
+#define XPutBackEvent XPutBackEvent_dylibloader_wrapper_xlib
+#define XPutImage XPutImage_dylibloader_wrapper_xlib
+#define XQLength XQLength_dylibloader_wrapper_xlib
+#define XQueryBestCursor XQueryBestCursor_dylibloader_wrapper_xlib
+#define XQueryBestSize XQueryBestSize_dylibloader_wrapper_xlib
+#define XQueryBestStipple XQueryBestStipple_dylibloader_wrapper_xlib
+#define XQueryBestTile XQueryBestTile_dylibloader_wrapper_xlib
+#define XQueryColor XQueryColor_dylibloader_wrapper_xlib
+#define XQueryColors XQueryColors_dylibloader_wrapper_xlib
+#define XQueryExtension XQueryExtension_dylibloader_wrapper_xlib
+#define XQueryKeymap XQueryKeymap_dylibloader_wrapper_xlib
+#define XQueryPointer XQueryPointer_dylibloader_wrapper_xlib
+#define XQueryTextExtents XQueryTextExtents_dylibloader_wrapper_xlib
+#define XQueryTextExtents16 XQueryTextExtents16_dylibloader_wrapper_xlib
+#define XQueryTree XQueryTree_dylibloader_wrapper_xlib
+#define XRaiseWindow XRaiseWindow_dylibloader_wrapper_xlib
+#define XReadBitmapFile XReadBitmapFile_dylibloader_wrapper_xlib
+#define XReadBitmapFileData XReadBitmapFileData_dylibloader_wrapper_xlib
+#define XRebindKeysym XRebindKeysym_dylibloader_wrapper_xlib
+#define XRecolorCursor XRecolorCursor_dylibloader_wrapper_xlib
+#define XRefreshKeyboardMapping XRefreshKeyboardMapping_dylibloader_wrapper_xlib
+#define XRemoveFromSaveSet XRemoveFromSaveSet_dylibloader_wrapper_xlib
+#define XRemoveHost XRemoveHost_dylibloader_wrapper_xlib
+#define XRemoveHosts XRemoveHosts_dylibloader_wrapper_xlib
+#define XReparentWindow XReparentWindow_dylibloader_wrapper_xlib
+#define XResetScreenSaver XResetScreenSaver_dylibloader_wrapper_xlib
+#define XResizeWindow XResizeWindow_dylibloader_wrapper_xlib
+#define XRestackWindows XRestackWindows_dylibloader_wrapper_xlib
+#define XRotateBuffers XRotateBuffers_dylibloader_wrapper_xlib
+#define XRotateWindowProperties XRotateWindowProperties_dylibloader_wrapper_xlib
+#define XScreenCount XScreenCount_dylibloader_wrapper_xlib
+#define XSelectInput XSelectInput_dylibloader_wrapper_xlib
+#define XSendEvent XSendEvent_dylibloader_wrapper_xlib
+#define XSetAccessControl XSetAccessControl_dylibloader_wrapper_xlib
+#define XSetArcMode XSetArcMode_dylibloader_wrapper_xlib
+#define XSetBackground XSetBackground_dylibloader_wrapper_xlib
+#define XSetClipMask XSetClipMask_dylibloader_wrapper_xlib
+#define XSetClipOrigin XSetClipOrigin_dylibloader_wrapper_xlib
+#define XSetClipRectangles XSetClipRectangles_dylibloader_wrapper_xlib
+#define XSetCloseDownMode XSetCloseDownMode_dylibloader_wrapper_xlib
+#define XSetCommand XSetCommand_dylibloader_wrapper_xlib
+#define XSetDashes XSetDashes_dylibloader_wrapper_xlib
+#define XSetFillRule XSetFillRule_dylibloader_wrapper_xlib
+#define XSetFillStyle XSetFillStyle_dylibloader_wrapper_xlib
+#define XSetFont XSetFont_dylibloader_wrapper_xlib
+#define XSetFontPath XSetFontPath_dylibloader_wrapper_xlib
+#define XSetForeground XSetForeground_dylibloader_wrapper_xlib
+#define XSetFunction XSetFunction_dylibloader_wrapper_xlib
+#define XSetGraphicsExposures XSetGraphicsExposures_dylibloader_wrapper_xlib
+#define XSetIconName XSetIconName_dylibloader_wrapper_xlib
+#define XSetInputFocus XSetInputFocus_dylibloader_wrapper_xlib
+#define XSetLineAttributes XSetLineAttributes_dylibloader_wrapper_xlib
+#define XSetModifierMapping XSetModifierMapping_dylibloader_wrapper_xlib
+#define XSetPlaneMask XSetPlaneMask_dylibloader_wrapper_xlib
+#define XSetPointerMapping XSetPointerMapping_dylibloader_wrapper_xlib
+#define XSetScreenSaver XSetScreenSaver_dylibloader_wrapper_xlib
+#define XSetSelectionOwner XSetSelectionOwner_dylibloader_wrapper_xlib
+#define XSetState XSetState_dylibloader_wrapper_xlib
+#define XSetStipple XSetStipple_dylibloader_wrapper_xlib
+#define XSetSubwindowMode XSetSubwindowMode_dylibloader_wrapper_xlib
+#define XSetTSOrigin XSetTSOrigin_dylibloader_wrapper_xlib
+#define XSetTile XSetTile_dylibloader_wrapper_xlib
+#define XSetWindowBackground XSetWindowBackground_dylibloader_wrapper_xlib
+#define XSetWindowBackgroundPixmap XSetWindowBackgroundPixmap_dylibloader_wrapper_xlib
+#define XSetWindowBorder XSetWindowBorder_dylibloader_wrapper_xlib
+#define XSetWindowBorderPixmap XSetWindowBorderPixmap_dylibloader_wrapper_xlib
+#define XSetWindowBorderWidth XSetWindowBorderWidth_dylibloader_wrapper_xlib
+#define XSetWindowColormap XSetWindowColormap_dylibloader_wrapper_xlib
+#define XStoreBuffer XStoreBuffer_dylibloader_wrapper_xlib
+#define XStoreBytes XStoreBytes_dylibloader_wrapper_xlib
+#define XStoreColor XStoreColor_dylibloader_wrapper_xlib
+#define XStoreColors XStoreColors_dylibloader_wrapper_xlib
+#define XStoreName XStoreName_dylibloader_wrapper_xlib
+#define XStoreNamedColor XStoreNamedColor_dylibloader_wrapper_xlib
+#define XSync XSync_dylibloader_wrapper_xlib
+#define XTextExtents XTextExtents_dylibloader_wrapper_xlib
+#define XTextExtents16 XTextExtents16_dylibloader_wrapper_xlib
+#define XTextWidth XTextWidth_dylibloader_wrapper_xlib
+#define XTextWidth16 XTextWidth16_dylibloader_wrapper_xlib
+#define XTranslateCoordinates XTranslateCoordinates_dylibloader_wrapper_xlib
+#define XUndefineCursor XUndefineCursor_dylibloader_wrapper_xlib
+#define XUngrabButton XUngrabButton_dylibloader_wrapper_xlib
+#define XUngrabKey XUngrabKey_dylibloader_wrapper_xlib
+#define XUngrabKeyboard XUngrabKeyboard_dylibloader_wrapper_xlib
+#define XUngrabPointer XUngrabPointer_dylibloader_wrapper_xlib
+#define XUngrabServer XUngrabServer_dylibloader_wrapper_xlib
+#define XUninstallColormap XUninstallColormap_dylibloader_wrapper_xlib
+#define XUnloadFont XUnloadFont_dylibloader_wrapper_xlib
+#define XUnmapSubwindows XUnmapSubwindows_dylibloader_wrapper_xlib
+#define XUnmapWindow XUnmapWindow_dylibloader_wrapper_xlib
+#define XVendorRelease XVendorRelease_dylibloader_wrapper_xlib
+#define XWarpPointer XWarpPointer_dylibloader_wrapper_xlib
+#define XWidthMMOfScreen XWidthMMOfScreen_dylibloader_wrapper_xlib
+#define XWidthOfScreen XWidthOfScreen_dylibloader_wrapper_xlib
+#define XWindowEvent XWindowEvent_dylibloader_wrapper_xlib
+#define XWriteBitmapFile XWriteBitmapFile_dylibloader_wrapper_xlib
+#define XSupportsLocale XSupportsLocale_dylibloader_wrapper_xlib
+#define XSetLocaleModifiers XSetLocaleModifiers_dylibloader_wrapper_xlib
+#define XOpenOM XOpenOM_dylibloader_wrapper_xlib
+#define XCloseOM XCloseOM_dylibloader_wrapper_xlib
+#define XSetOMValues XSetOMValues_dylibloader_wrapper_xlib
+#define XGetOMValues XGetOMValues_dylibloader_wrapper_xlib
+#define XDisplayOfOM XDisplayOfOM_dylibloader_wrapper_xlib
+#define XLocaleOfOM XLocaleOfOM_dylibloader_wrapper_xlib
+#define XCreateOC XCreateOC_dylibloader_wrapper_xlib
+#define XDestroyOC XDestroyOC_dylibloader_wrapper_xlib
+#define XOMOfOC XOMOfOC_dylibloader_wrapper_xlib
+#define XSetOCValues XSetOCValues_dylibloader_wrapper_xlib
+#define XGetOCValues XGetOCValues_dylibloader_wrapper_xlib
+#define XCreateFontSet XCreateFontSet_dylibloader_wrapper_xlib
+#define XFreeFontSet XFreeFontSet_dylibloader_wrapper_xlib
+#define XFontsOfFontSet XFontsOfFontSet_dylibloader_wrapper_xlib
+#define XBaseFontNameListOfFontSet XBaseFontNameListOfFontSet_dylibloader_wrapper_xlib
+#define XLocaleOfFontSet XLocaleOfFontSet_dylibloader_wrapper_xlib
+#define XContextDependentDrawing XContextDependentDrawing_dylibloader_wrapper_xlib
+#define XDirectionalDependentDrawing XDirectionalDependentDrawing_dylibloader_wrapper_xlib
+#define XContextualDrawing XContextualDrawing_dylibloader_wrapper_xlib
+#define XExtentsOfFontSet XExtentsOfFontSet_dylibloader_wrapper_xlib
+#define XmbTextEscapement XmbTextEscapement_dylibloader_wrapper_xlib
+#define XwcTextEscapement XwcTextEscapement_dylibloader_wrapper_xlib
+#define Xutf8TextEscapement Xutf8TextEscapement_dylibloader_wrapper_xlib
+#define XmbTextExtents XmbTextExtents_dylibloader_wrapper_xlib
+#define XwcTextExtents XwcTextExtents_dylibloader_wrapper_xlib
+#define Xutf8TextExtents Xutf8TextExtents_dylibloader_wrapper_xlib
+#define XmbTextPerCharExtents XmbTextPerCharExtents_dylibloader_wrapper_xlib
+#define XwcTextPerCharExtents XwcTextPerCharExtents_dylibloader_wrapper_xlib
+#define Xutf8TextPerCharExtents Xutf8TextPerCharExtents_dylibloader_wrapper_xlib
+#define XmbDrawText XmbDrawText_dylibloader_wrapper_xlib
+#define XwcDrawText XwcDrawText_dylibloader_wrapper_xlib
+#define Xutf8DrawText Xutf8DrawText_dylibloader_wrapper_xlib
+#define XmbDrawString XmbDrawString_dylibloader_wrapper_xlib
+#define XwcDrawString XwcDrawString_dylibloader_wrapper_xlib
+#define Xutf8DrawString Xutf8DrawString_dylibloader_wrapper_xlib
+#define XmbDrawImageString XmbDrawImageString_dylibloader_wrapper_xlib
+#define XwcDrawImageString XwcDrawImageString_dylibloader_wrapper_xlib
+#define Xutf8DrawImageString Xutf8DrawImageString_dylibloader_wrapper_xlib
+#define XOpenIM XOpenIM_dylibloader_wrapper_xlib
+#define XCloseIM XCloseIM_dylibloader_wrapper_xlib
+#define XGetIMValues XGetIMValues_dylibloader_wrapper_xlib
+#define XSetIMValues XSetIMValues_dylibloader_wrapper_xlib
+#define XDisplayOfIM XDisplayOfIM_dylibloader_wrapper_xlib
+#define XLocaleOfIM XLocaleOfIM_dylibloader_wrapper_xlib
+#define XCreateIC XCreateIC_dylibloader_wrapper_xlib
+#define XDestroyIC XDestroyIC_dylibloader_wrapper_xlib
+#define XSetICFocus XSetICFocus_dylibloader_wrapper_xlib
+#define XUnsetICFocus XUnsetICFocus_dylibloader_wrapper_xlib
+#define XwcResetIC XwcResetIC_dylibloader_wrapper_xlib
+#define XmbResetIC XmbResetIC_dylibloader_wrapper_xlib
+#define Xutf8ResetIC Xutf8ResetIC_dylibloader_wrapper_xlib
+#define XSetICValues XSetICValues_dylibloader_wrapper_xlib
+#define XGetICValues XGetICValues_dylibloader_wrapper_xlib
+#define XIMOfIC XIMOfIC_dylibloader_wrapper_xlib
+#define XFilterEvent XFilterEvent_dylibloader_wrapper_xlib
+#define XmbLookupString XmbLookupString_dylibloader_wrapper_xlib
+#define XwcLookupString XwcLookupString_dylibloader_wrapper_xlib
+#define Xutf8LookupString Xutf8LookupString_dylibloader_wrapper_xlib
+#define XVaCreateNestedList XVaCreateNestedList_dylibloader_wrapper_xlib
+#define XRegisterIMInstantiateCallback XRegisterIMInstantiateCallback_dylibloader_wrapper_xlib
+#define XUnregisterIMInstantiateCallback XUnregisterIMInstantiateCallback_dylibloader_wrapper_xlib
+#define XInternalConnectionNumbers XInternalConnectionNumbers_dylibloader_wrapper_xlib
+#define XProcessInternalConnection XProcessInternalConnection_dylibloader_wrapper_xlib
+#define XAddConnectionWatch XAddConnectionWatch_dylibloader_wrapper_xlib
+#define XRemoveConnectionWatch XRemoveConnectionWatch_dylibloader_wrapper_xlib
+#define XSetAuthorization XSetAuthorization_dylibloader_wrapper_xlib
+#define _Xmbtowc _Xmbtowc_dylibloader_wrapper_xlib
+#define _Xwctomb _Xwctomb_dylibloader_wrapper_xlib
+#define XGetEventData XGetEventData_dylibloader_wrapper_xlib
+#define XFreeEventData XFreeEventData_dylibloader_wrapper_xlib
+#define XAllocClassHint XAllocClassHint_dylibloader_wrapper_xlib
+#define XAllocIconSize XAllocIconSize_dylibloader_wrapper_xlib
+#define XAllocSizeHints XAllocSizeHints_dylibloader_wrapper_xlib
+#define XAllocStandardColormap XAllocStandardColormap_dylibloader_wrapper_xlib
+#define XAllocWMHints XAllocWMHints_dylibloader_wrapper_xlib
+#define XClipBox XClipBox_dylibloader_wrapper_xlib
+#define XCreateRegion XCreateRegion_dylibloader_wrapper_xlib
+#define XDefaultString XDefaultString_dylibloader_wrapper_xlib
+#define XDeleteContext XDeleteContext_dylibloader_wrapper_xlib
+#define XDestroyRegion XDestroyRegion_dylibloader_wrapper_xlib
+#define XEmptyRegion XEmptyRegion_dylibloader_wrapper_xlib
+#define XEqualRegion XEqualRegion_dylibloader_wrapper_xlib
+#define XFindContext XFindContext_dylibloader_wrapper_xlib
+#define XGetClassHint XGetClassHint_dylibloader_wrapper_xlib
+#define XGetIconSizes XGetIconSizes_dylibloader_wrapper_xlib
+#define XGetNormalHints XGetNormalHints_dylibloader_wrapper_xlib
+#define XGetRGBColormaps XGetRGBColormaps_dylibloader_wrapper_xlib
+#define XGetSizeHints XGetSizeHints_dylibloader_wrapper_xlib
+#define XGetStandardColormap XGetStandardColormap_dylibloader_wrapper_xlib
+#define XGetTextProperty XGetTextProperty_dylibloader_wrapper_xlib
+#define XGetVisualInfo XGetVisualInfo_dylibloader_wrapper_xlib
+#define XGetWMClientMachine XGetWMClientMachine_dylibloader_wrapper_xlib
+#define XGetWMHints XGetWMHints_dylibloader_wrapper_xlib
+#define XGetWMIconName XGetWMIconName_dylibloader_wrapper_xlib
+#define XGetWMName XGetWMName_dylibloader_wrapper_xlib
+#define XGetWMNormalHints XGetWMNormalHints_dylibloader_wrapper_xlib
+#define XGetWMSizeHints XGetWMSizeHints_dylibloader_wrapper_xlib
+#define XGetZoomHints XGetZoomHints_dylibloader_wrapper_xlib
+#define XIntersectRegion XIntersectRegion_dylibloader_wrapper_xlib
+#define XConvertCase XConvertCase_dylibloader_wrapper_xlib
+#define XLookupString XLookupString_dylibloader_wrapper_xlib
+#define XMatchVisualInfo XMatchVisualInfo_dylibloader_wrapper_xlib
+#define XOffsetRegion XOffsetRegion_dylibloader_wrapper_xlib
+#define XPointInRegion XPointInRegion_dylibloader_wrapper_xlib
+#define XPolygonRegion XPolygonRegion_dylibloader_wrapper_xlib
+#define XRectInRegion XRectInRegion_dylibloader_wrapper_xlib
+#define XSaveContext XSaveContext_dylibloader_wrapper_xlib
+#define XSetClassHint XSetClassHint_dylibloader_wrapper_xlib
+#define XSetIconSizes XSetIconSizes_dylibloader_wrapper_xlib
+#define XSetNormalHints XSetNormalHints_dylibloader_wrapper_xlib
+#define XSetRGBColormaps XSetRGBColormaps_dylibloader_wrapper_xlib
+#define XSetSizeHints XSetSizeHints_dylibloader_wrapper_xlib
+#define XSetStandardProperties XSetStandardProperties_dylibloader_wrapper_xlib
+#define XSetTextProperty XSetTextProperty_dylibloader_wrapper_xlib
+#define XSetWMClientMachine XSetWMClientMachine_dylibloader_wrapper_xlib
+#define XSetWMHints XSetWMHints_dylibloader_wrapper_xlib
+#define XSetWMIconName XSetWMIconName_dylibloader_wrapper_xlib
+#define XSetWMName XSetWMName_dylibloader_wrapper_xlib
+#define XSetWMNormalHints XSetWMNormalHints_dylibloader_wrapper_xlib
+#define XSetWMProperties XSetWMProperties_dylibloader_wrapper_xlib
+#define XmbSetWMProperties XmbSetWMProperties_dylibloader_wrapper_xlib
+#define Xutf8SetWMProperties Xutf8SetWMProperties_dylibloader_wrapper_xlib
+#define XSetWMSizeHints XSetWMSizeHints_dylibloader_wrapper_xlib
+#define XSetRegion XSetRegion_dylibloader_wrapper_xlib
+#define XSetStandardColormap XSetStandardColormap_dylibloader_wrapper_xlib
+#define XSetZoomHints XSetZoomHints_dylibloader_wrapper_xlib
+#define XShrinkRegion XShrinkRegion_dylibloader_wrapper_xlib
+#define XStringListToTextProperty XStringListToTextProperty_dylibloader_wrapper_xlib
+#define XSubtractRegion XSubtractRegion_dylibloader_wrapper_xlib
+#define XmbTextListToTextProperty XmbTextListToTextProperty_dylibloader_wrapper_xlib
+#define XwcTextListToTextProperty XwcTextListToTextProperty_dylibloader_wrapper_xlib
+#define Xutf8TextListToTextProperty Xutf8TextListToTextProperty_dylibloader_wrapper_xlib
+#define XwcFreeStringList XwcFreeStringList_dylibloader_wrapper_xlib
+#define XTextPropertyToStringList XTextPropertyToStringList_dylibloader_wrapper_xlib
+#define XmbTextPropertyToTextList XmbTextPropertyToTextList_dylibloader_wrapper_xlib
+#define XwcTextPropertyToTextList XwcTextPropertyToTextList_dylibloader_wrapper_xlib
+#define Xutf8TextPropertyToTextList Xutf8TextPropertyToTextList_dylibloader_wrapper_xlib
+#define XUnionRectWithRegion XUnionRectWithRegion_dylibloader_wrapper_xlib
+#define XUnionRegion XUnionRegion_dylibloader_wrapper_xlib
+#define XWMGeometry XWMGeometry_dylibloader_wrapper_xlib
+#define XXorRegion XXorRegion_dylibloader_wrapper_xlib
+#define XkbIgnoreExtension XkbIgnoreExtension_dylibloader_wrapper_xlib
+#define XkbOpenDisplay XkbOpenDisplay_dylibloader_wrapper_xlib
+#define XkbQueryExtension XkbQueryExtension_dylibloader_wrapper_xlib
+#define XkbUseExtension XkbUseExtension_dylibloader_wrapper_xlib
+#define XkbLibraryVersion XkbLibraryVersion_dylibloader_wrapper_xlib
+#define XkbSetXlibControls XkbSetXlibControls_dylibloader_wrapper_xlib
+#define XkbGetXlibControls XkbGetXlibControls_dylibloader_wrapper_xlib
+#define XkbXlibControlsImplemented XkbXlibControlsImplemented_dylibloader_wrapper_xlib
+#define XkbSetAtomFuncs XkbSetAtomFuncs_dylibloader_wrapper_xlib
+#define XkbKeycodeToKeysym XkbKeycodeToKeysym_dylibloader_wrapper_xlib
+#define XkbKeysymToModifiers XkbKeysymToModifiers_dylibloader_wrapper_xlib
+#define XkbLookupKeySym XkbLookupKeySym_dylibloader_wrapper_xlib
+#define XkbLookupKeyBinding XkbLookupKeyBinding_dylibloader_wrapper_xlib
+#define XkbTranslateKeyCode XkbTranslateKeyCode_dylibloader_wrapper_xlib
+#define XkbTranslateKeySym XkbTranslateKeySym_dylibloader_wrapper_xlib
+#define XkbSetAutoRepeatRate XkbSetAutoRepeatRate_dylibloader_wrapper_xlib
+#define XkbGetAutoRepeatRate XkbGetAutoRepeatRate_dylibloader_wrapper_xlib
+#define XkbChangeEnabledControls XkbChangeEnabledControls_dylibloader_wrapper_xlib
+#define XkbDeviceBell XkbDeviceBell_dylibloader_wrapper_xlib
+#define XkbForceDeviceBell XkbForceDeviceBell_dylibloader_wrapper_xlib
+#define XkbDeviceBellEvent XkbDeviceBellEvent_dylibloader_wrapper_xlib
+#define XkbBell XkbBell_dylibloader_wrapper_xlib
+#define XkbForceBell XkbForceBell_dylibloader_wrapper_xlib
+#define XkbBellEvent XkbBellEvent_dylibloader_wrapper_xlib
+#define XkbSelectEvents XkbSelectEvents_dylibloader_wrapper_xlib
+#define XkbSelectEventDetails XkbSelectEventDetails_dylibloader_wrapper_xlib
+#define XkbNoteMapChanges XkbNoteMapChanges_dylibloader_wrapper_xlib
+#define XkbNoteNameChanges XkbNoteNameChanges_dylibloader_wrapper_xlib
+#define XkbGetIndicatorState XkbGetIndicatorState_dylibloader_wrapper_xlib
+#define XkbGetIndicatorMap XkbGetIndicatorMap_dylibloader_wrapper_xlib
+#define XkbSetIndicatorMap XkbSetIndicatorMap_dylibloader_wrapper_xlib
+#define XkbGetNamedIndicator XkbGetNamedIndicator_dylibloader_wrapper_xlib
+#define XkbGetNamedDeviceIndicator XkbGetNamedDeviceIndicator_dylibloader_wrapper_xlib
+#define XkbSetNamedIndicator XkbSetNamedIndicator_dylibloader_wrapper_xlib
+#define XkbSetNamedDeviceIndicator XkbSetNamedDeviceIndicator_dylibloader_wrapper_xlib
+#define XkbLockModifiers XkbLockModifiers_dylibloader_wrapper_xlib
+#define XkbLatchModifiers XkbLatchModifiers_dylibloader_wrapper_xlib
+#define XkbLockGroup XkbLockGroup_dylibloader_wrapper_xlib
+#define XkbLatchGroup XkbLatchGroup_dylibloader_wrapper_xlib
+#define XkbSetServerInternalMods XkbSetServerInternalMods_dylibloader_wrapper_xlib
+#define XkbSetIgnoreLockMods XkbSetIgnoreLockMods_dylibloader_wrapper_xlib
+#define XkbVirtualModsToReal XkbVirtualModsToReal_dylibloader_wrapper_xlib
+#define XkbComputeEffectiveMap XkbComputeEffectiveMap_dylibloader_wrapper_xlib
+#define XkbInitCanonicalKeyTypes XkbInitCanonicalKeyTypes_dylibloader_wrapper_xlib
+#define XkbAllocKeyboard XkbAllocKeyboard_dylibloader_wrapper_xlib
+#define XkbFreeKeyboard XkbFreeKeyboard_dylibloader_wrapper_xlib
+#define XkbAllocClientMap XkbAllocClientMap_dylibloader_wrapper_xlib
+#define XkbAllocServerMap XkbAllocServerMap_dylibloader_wrapper_xlib
+#define XkbFreeClientMap XkbFreeClientMap_dylibloader_wrapper_xlib
+#define XkbFreeServerMap XkbFreeServerMap_dylibloader_wrapper_xlib
+#define XkbAddKeyType XkbAddKeyType_dylibloader_wrapper_xlib
+#define XkbAllocIndicatorMaps XkbAllocIndicatorMaps_dylibloader_wrapper_xlib
+#define XkbFreeIndicatorMaps XkbFreeIndicatorMaps_dylibloader_wrapper_xlib
+#define XkbGetMap XkbGetMap_dylibloader_wrapper_xlib
+#define XkbGetUpdatedMap XkbGetUpdatedMap_dylibloader_wrapper_xlib
+#define XkbGetMapChanges XkbGetMapChanges_dylibloader_wrapper_xlib
+#define XkbRefreshKeyboardMapping XkbRefreshKeyboardMapping_dylibloader_wrapper_xlib
+#define XkbGetKeyTypes XkbGetKeyTypes_dylibloader_wrapper_xlib
+#define XkbGetKeySyms XkbGetKeySyms_dylibloader_wrapper_xlib
+#define XkbGetKeyActions XkbGetKeyActions_dylibloader_wrapper_xlib
+#define XkbGetKeyBehaviors XkbGetKeyBehaviors_dylibloader_wrapper_xlib
+#define XkbGetVirtualMods XkbGetVirtualMods_dylibloader_wrapper_xlib
+#define XkbGetKeyExplicitComponents XkbGetKeyExplicitComponents_dylibloader_wrapper_xlib
+#define XkbGetKeyModifierMap XkbGetKeyModifierMap_dylibloader_wrapper_xlib
+#define XkbGetKeyVirtualModMap XkbGetKeyVirtualModMap_dylibloader_wrapper_xlib
+#define XkbAllocControls XkbAllocControls_dylibloader_wrapper_xlib
+#define XkbFreeControls XkbFreeControls_dylibloader_wrapper_xlib
+#define XkbGetControls XkbGetControls_dylibloader_wrapper_xlib
+#define XkbSetControls XkbSetControls_dylibloader_wrapper_xlib
+#define XkbNoteControlsChanges XkbNoteControlsChanges_dylibloader_wrapper_xlib
+#define XkbAllocCompatMap XkbAllocCompatMap_dylibloader_wrapper_xlib
+#define XkbFreeCompatMap XkbFreeCompatMap_dylibloader_wrapper_xlib
+#define XkbGetCompatMap XkbGetCompatMap_dylibloader_wrapper_xlib
+#define XkbSetCompatMap XkbSetCompatMap_dylibloader_wrapper_xlib
+#define XkbAllocNames XkbAllocNames_dylibloader_wrapper_xlib
+#define XkbGetNames XkbGetNames_dylibloader_wrapper_xlib
+#define XkbSetNames XkbSetNames_dylibloader_wrapper_xlib
+#define XkbChangeNames XkbChangeNames_dylibloader_wrapper_xlib
+#define XkbFreeNames XkbFreeNames_dylibloader_wrapper_xlib
+#define XkbGetState XkbGetState_dylibloader_wrapper_xlib
+#define XkbSetMap XkbSetMap_dylibloader_wrapper_xlib
+#define XkbChangeMap XkbChangeMap_dylibloader_wrapper_xlib
+#define XkbSetDetectableAutoRepeat XkbSetDetectableAutoRepeat_dylibloader_wrapper_xlib
+#define XkbGetDetectableAutoRepeat XkbGetDetectableAutoRepeat_dylibloader_wrapper_xlib
+#define XkbSetAutoResetControls XkbSetAutoResetControls_dylibloader_wrapper_xlib
+#define XkbGetAutoResetControls XkbGetAutoResetControls_dylibloader_wrapper_xlib
+#define XkbSetPerClientControls XkbSetPerClientControls_dylibloader_wrapper_xlib
+#define XkbGetPerClientControls XkbGetPerClientControls_dylibloader_wrapper_xlib
+#define XkbCopyKeyType XkbCopyKeyType_dylibloader_wrapper_xlib
+#define XkbCopyKeyTypes XkbCopyKeyTypes_dylibloader_wrapper_xlib
+#define XkbResizeKeyType XkbResizeKeyType_dylibloader_wrapper_xlib
+#define XkbResizeKeySyms XkbResizeKeySyms_dylibloader_wrapper_xlib
+#define XkbResizeKeyActions XkbResizeKeyActions_dylibloader_wrapper_xlib
+#define XkbChangeTypesOfKey XkbChangeTypesOfKey_dylibloader_wrapper_xlib
+#define XkbChangeKeycodeRange XkbChangeKeycodeRange_dylibloader_wrapper_xlib
+#define XkbListComponents XkbListComponents_dylibloader_wrapper_xlib
+#define XkbFreeComponentList XkbFreeComponentList_dylibloader_wrapper_xlib
+#define XkbGetKeyboard XkbGetKeyboard_dylibloader_wrapper_xlib
+#define XkbGetKeyboardByName XkbGetKeyboardByName_dylibloader_wrapper_xlib
+#define XkbKeyTypesForCoreSymbols XkbKeyTypesForCoreSymbols_dylibloader_wrapper_xlib
+#define XkbApplyCompatMapToKey XkbApplyCompatMapToKey_dylibloader_wrapper_xlib
+#define XkbUpdateMapFromCore XkbUpdateMapFromCore_dylibloader_wrapper_xlib
+#define XkbAddDeviceLedInfo XkbAddDeviceLedInfo_dylibloader_wrapper_xlib
+#define XkbResizeDeviceButtonActions XkbResizeDeviceButtonActions_dylibloader_wrapper_xlib
+#define XkbAllocDeviceInfo XkbAllocDeviceInfo_dylibloader_wrapper_xlib
+#define XkbFreeDeviceInfo XkbFreeDeviceInfo_dylibloader_wrapper_xlib
+#define XkbNoteDeviceChanges XkbNoteDeviceChanges_dylibloader_wrapper_xlib
+#define XkbGetDeviceInfo XkbGetDeviceInfo_dylibloader_wrapper_xlib
+#define XkbGetDeviceInfoChanges XkbGetDeviceInfoChanges_dylibloader_wrapper_xlib
+#define XkbGetDeviceButtonActions XkbGetDeviceButtonActions_dylibloader_wrapper_xlib
+#define XkbGetDeviceLedInfo XkbGetDeviceLedInfo_dylibloader_wrapper_xlib
+#define XkbSetDeviceInfo XkbSetDeviceInfo_dylibloader_wrapper_xlib
+#define XkbChangeDeviceInfo XkbChangeDeviceInfo_dylibloader_wrapper_xlib
+#define XkbSetDeviceLedInfo XkbSetDeviceLedInfo_dylibloader_wrapper_xlib
+#define XkbSetDeviceButtonActions XkbSetDeviceButtonActions_dylibloader_wrapper_xlib
+#define XkbToControl XkbToControl_dylibloader_wrapper_xlib
+#define XkbSetDebuggingFlags XkbSetDebuggingFlags_dylibloader_wrapper_xlib
+#define XkbApplyVirtualModChanges XkbApplyVirtualModChanges_dylibloader_wrapper_xlib
+#define XkbUpdateActionVirtualMods XkbUpdateActionVirtualMods_dylibloader_wrapper_xlib
+#define XkbUpdateKeyTypeVirtualMods XkbUpdateKeyTypeVirtualMods_dylibloader_wrapper_xlib
+extern int (*_Xmblen_dylibloader_wrapper_xlib)( char*, int);
+extern XFontStruct* (*XLoadQueryFont_dylibloader_wrapper_xlib)( Display*,const char*);
+extern XFontStruct* (*XQueryFont_dylibloader_wrapper_xlib)( Display*, XID);
+extern XTimeCoord* (*XGetMotionEvents_dylibloader_wrapper_xlib)( Display*, Window, Time, Time, int*);
+extern XModifierKeymap* (*XDeleteModifiermapEntry_dylibloader_wrapper_xlib)( XModifierKeymap*, KeyCode, int);
+extern XModifierKeymap* (*XGetModifierMapping_dylibloader_wrapper_xlib)( Display*);
+extern XModifierKeymap* (*XInsertModifiermapEntry_dylibloader_wrapper_xlib)( XModifierKeymap*, KeyCode, int);
+extern XModifierKeymap* (*XNewModifiermap_dylibloader_wrapper_xlib)( int);
+extern XImage* (*XCreateImage_dylibloader_wrapper_xlib)( Display*, Visual*, unsigned int, int, int, char*, unsigned int, unsigned int, int, int);
+extern int (*XInitImage_dylibloader_wrapper_xlib)( XImage*);
+extern XImage* (*XGetImage_dylibloader_wrapper_xlib)( Display*, Drawable, int, int, unsigned int, unsigned int, unsigned long, int);
+extern XImage* (*XGetSubImage_dylibloader_wrapper_xlib)( Display*, Drawable, int, int, unsigned int, unsigned int, unsigned long, int, XImage*, int, int);
+extern Display* (*XOpenDisplay_dylibloader_wrapper_xlib)(const char*);
+extern void (*XrmInitialize_dylibloader_wrapper_xlib)( void);
+extern char* (*XFetchBytes_dylibloader_wrapper_xlib)( Display*, int*);
+extern char* (*XFetchBuffer_dylibloader_wrapper_xlib)( Display*, int*, int);
+extern char* (*XGetAtomName_dylibloader_wrapper_xlib)( Display*, Atom);
+extern int (*XGetAtomNames_dylibloader_wrapper_xlib)( Display*, Atom*, int, char**);
+extern char* (*XGetDefault_dylibloader_wrapper_xlib)( Display*,const char*,const char*);
+extern char* (*XDisplayName_dylibloader_wrapper_xlib)(const char*);
+extern char* (*XKeysymToString_dylibloader_wrapper_xlib)( KeySym);
+extern int* (*XSynchronize_dylibloader_wrapper_xlib)( Display*, int);
+extern int* (*XSetAfterFunction_dylibloader_wrapper_xlib)( Display*, int*);
+extern Atom (*XInternAtom_dylibloader_wrapper_xlib)( Display*,const char*, int);
+extern int (*XInternAtoms_dylibloader_wrapper_xlib)( Display*, char**, int, int, Atom*);
+extern Colormap (*XCopyColormapAndFree_dylibloader_wrapper_xlib)( Display*, Colormap);
+extern Colormap (*XCreateColormap_dylibloader_wrapper_xlib)( Display*, Window, Visual*, int);
+extern Cursor (*XCreatePixmapCursor_dylibloader_wrapper_xlib)( Display*, Pixmap, Pixmap, XColor*, XColor*, unsigned int, unsigned int);
+extern Cursor (*XCreateGlyphCursor_dylibloader_wrapper_xlib)( Display*, Font, Font, unsigned int, unsigned int,const XColor*,const XColor*);
+extern Cursor (*XCreateFontCursor_dylibloader_wrapper_xlib)( Display*, unsigned int);
+extern Font (*XLoadFont_dylibloader_wrapper_xlib)( Display*,const char*);
+extern GC (*XCreateGC_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned long, XGCValues*);
+extern GContext (*XGContextFromGC_dylibloader_wrapper_xlib)( GC);
+extern void (*XFlushGC_dylibloader_wrapper_xlib)( Display*, GC);
+extern Pixmap (*XCreatePixmap_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int);
+extern Pixmap (*XCreateBitmapFromData_dylibloader_wrapper_xlib)( Display*, Drawable,const char*, unsigned int, unsigned int);
+extern Pixmap (*XCreatePixmapFromBitmapData_dylibloader_wrapper_xlib)( Display*, Drawable, char*, unsigned int, unsigned int, unsigned long, unsigned long, unsigned int);
+extern Window (*XCreateSimpleWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int, unsigned int, unsigned long, unsigned long);
+extern Window (*XGetSelectionOwner_dylibloader_wrapper_xlib)( Display*, Atom);
+extern Window (*XCreateWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int, unsigned int, int, unsigned int, Visual*, unsigned long, XSetWindowAttributes*);
+extern Colormap* (*XListInstalledColormaps_dylibloader_wrapper_xlib)( Display*, Window, int*);
+extern char** (*XListFonts_dylibloader_wrapper_xlib)( Display*,const char*, int, int*);
+extern char** (*XListFontsWithInfo_dylibloader_wrapper_xlib)( Display*,const char*, int, int*, XFontStruct**);
+extern char** (*XGetFontPath_dylibloader_wrapper_xlib)( Display*, int*);
+extern char** (*XListExtensions_dylibloader_wrapper_xlib)( Display*, int*);
+extern Atom* (*XListProperties_dylibloader_wrapper_xlib)( Display*, Window, int*);
+extern XHostAddress* (*XListHosts_dylibloader_wrapper_xlib)( Display*, int*, int*);
+extern KeySym (*XKeycodeToKeysym_dylibloader_wrapper_xlib)( Display*, KeyCode, int);
+extern KeySym (*XLookupKeysym_dylibloader_wrapper_xlib)( XKeyEvent*, int);
+extern KeySym* (*XGetKeyboardMapping_dylibloader_wrapper_xlib)( Display*, KeyCode, int, int*);
+extern KeySym (*XStringToKeysym_dylibloader_wrapper_xlib)(const char*);
+extern long (*XMaxRequestSize_dylibloader_wrapper_xlib)( Display*);
+extern long (*XExtendedMaxRequestSize_dylibloader_wrapper_xlib)( Display*);
+extern char* (*XResourceManagerString_dylibloader_wrapper_xlib)( Display*);
+extern char* (*XScreenResourceString_dylibloader_wrapper_xlib)( Screen*);
+extern unsigned long (*XDisplayMotionBufferSize_dylibloader_wrapper_xlib)( Display*);
+extern VisualID (*XVisualIDFromVisual_dylibloader_wrapper_xlib)( Visual*);
+extern int (*XInitThreads_dylibloader_wrapper_xlib)( void);
+extern void (*XLockDisplay_dylibloader_wrapper_xlib)( Display*);
+extern void (*XUnlockDisplay_dylibloader_wrapper_xlib)( Display*);
+extern XExtCodes* (*XInitExtension_dylibloader_wrapper_xlib)( Display*,const char*);
+extern XExtCodes* (*XAddExtension_dylibloader_wrapper_xlib)( Display*);
+extern XExtData* (*XFindOnExtensionList_dylibloader_wrapper_xlib)( XExtData**, int);
+extern XExtData** (*XEHeadOfExtensionList_dylibloader_wrapper_xlib)( XEDataObject);
+extern Window (*XRootWindow_dylibloader_wrapper_xlib)( Display*, int);
+extern Window (*XDefaultRootWindow_dylibloader_wrapper_xlib)( Display*);
+extern Window (*XRootWindowOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern Visual* (*XDefaultVisual_dylibloader_wrapper_xlib)( Display*, int);
+extern Visual* (*XDefaultVisualOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern GC (*XDefaultGC_dylibloader_wrapper_xlib)( Display*, int);
+extern GC (*XDefaultGCOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern unsigned long (*XBlackPixel_dylibloader_wrapper_xlib)( Display*, int);
+extern unsigned long (*XWhitePixel_dylibloader_wrapper_xlib)( Display*, int);
+extern unsigned long (*XAllPlanes_dylibloader_wrapper_xlib)( void);
+extern unsigned long (*XBlackPixelOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern unsigned long (*XWhitePixelOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern unsigned long (*XNextRequest_dylibloader_wrapper_xlib)( Display*);
+extern unsigned long (*XLastKnownRequestProcessed_dylibloader_wrapper_xlib)( Display*);
+extern char* (*XServerVendor_dylibloader_wrapper_xlib)( Display*);
+extern char* (*XDisplayString_dylibloader_wrapper_xlib)( Display*);
+extern Colormap (*XDefaultColormap_dylibloader_wrapper_xlib)( Display*, int);
+extern Colormap (*XDefaultColormapOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern Display* (*XDisplayOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern Screen* (*XScreenOfDisplay_dylibloader_wrapper_xlib)( Display*, int);
+extern Screen* (*XDefaultScreenOfDisplay_dylibloader_wrapper_xlib)( Display*);
+extern long (*XEventMaskOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XScreenNumberOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern XErrorHandler (*XSetErrorHandler_dylibloader_wrapper_xlib)( XErrorHandler);
+extern XIOErrorHandler (*XSetIOErrorHandler_dylibloader_wrapper_xlib)( XIOErrorHandler);
+extern XPixmapFormatValues* (*XListPixmapFormats_dylibloader_wrapper_xlib)( Display*, int*);
+extern int* (*XListDepths_dylibloader_wrapper_xlib)( Display*, int, int*);
+extern int (*XReconfigureWMWindow_dylibloader_wrapper_xlib)( Display*, Window, int, unsigned int, XWindowChanges*);
+extern int (*XGetWMProtocols_dylibloader_wrapper_xlib)( Display*, Window, Atom**, int*);
+extern int (*XSetWMProtocols_dylibloader_wrapper_xlib)( Display*, Window, Atom*, int);
+extern int (*XIconifyWindow_dylibloader_wrapper_xlib)( Display*, Window, int);
+extern int (*XWithdrawWindow_dylibloader_wrapper_xlib)( Display*, Window, int);
+extern int (*XGetCommand_dylibloader_wrapper_xlib)( Display*, Window, char***, int*);
+extern int (*XGetWMColormapWindows_dylibloader_wrapper_xlib)( Display*, Window, Window**, int*);
+extern int (*XSetWMColormapWindows_dylibloader_wrapper_xlib)( Display*, Window, Window*, int);
+extern void (*XFreeStringList_dylibloader_wrapper_xlib)( char**);
+extern int (*XSetTransientForHint_dylibloader_wrapper_xlib)( Display*, Window, Window);
+extern int (*XActivateScreenSaver_dylibloader_wrapper_xlib)( Display*);
+extern int (*XAddHost_dylibloader_wrapper_xlib)( Display*, XHostAddress*);
+extern int (*XAddHosts_dylibloader_wrapper_xlib)( Display*, XHostAddress*, int);
+extern int (*XAddToExtensionList_dylibloader_wrapper_xlib)(struct _XExtData**, XExtData*);
+extern int (*XAddToSaveSet_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XAllocColor_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*);
+extern int (*XAllocColorCells_dylibloader_wrapper_xlib)( Display*, Colormap, int, unsigned long*, unsigned int, unsigned long*, unsigned int);
+extern int (*XAllocColorPlanes_dylibloader_wrapper_xlib)( Display*, Colormap, int, unsigned long*, int, int, int, int, unsigned long*, unsigned long*, unsigned long*);
+extern int (*XAllocNamedColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, XColor*, XColor*);
+extern int (*XAllowEvents_dylibloader_wrapper_xlib)( Display*, int, Time);
+extern int (*XAutoRepeatOff_dylibloader_wrapper_xlib)( Display*);
+extern int (*XAutoRepeatOn_dylibloader_wrapper_xlib)( Display*);
+extern int (*XBell_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XBitmapBitOrder_dylibloader_wrapper_xlib)( Display*);
+extern int (*XBitmapPad_dylibloader_wrapper_xlib)( Display*);
+extern int (*XBitmapUnit_dylibloader_wrapper_xlib)( Display*);
+extern int (*XCellsOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XChangeActivePointerGrab_dylibloader_wrapper_xlib)( Display*, unsigned int, Cursor, Time);
+extern int (*XChangeGC_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, XGCValues*);
+extern int (*XChangeKeyboardControl_dylibloader_wrapper_xlib)( Display*, unsigned long, XKeyboardControl*);
+extern int (*XChangeKeyboardMapping_dylibloader_wrapper_xlib)( Display*, int, int, KeySym*, int);
+extern int (*XChangePointerControl_dylibloader_wrapper_xlib)( Display*, int, int, int, int, int);
+extern int (*XChangeProperty_dylibloader_wrapper_xlib)( Display*, Window, Atom, Atom, int, int,const unsigned char*, int);
+extern int (*XChangeSaveSet_dylibloader_wrapper_xlib)( Display*, Window, int);
+extern int (*XChangeWindowAttributes_dylibloader_wrapper_xlib)( Display*, Window, unsigned long, XSetWindowAttributes*);
+extern int (*XCheckIfEvent_dylibloader_wrapper_xlib)( Display*, XEvent*, Bool (*) (Display*, XEvent*, XPointer), XPointer);
+extern int (*XCheckMaskEvent_dylibloader_wrapper_xlib)( Display*, long, XEvent*);
+extern int (*XCheckTypedEvent_dylibloader_wrapper_xlib)( Display*, int, XEvent*);
+extern int (*XCheckTypedWindowEvent_dylibloader_wrapper_xlib)( Display*, Window, int, XEvent*);
+extern int (*XCheckWindowEvent_dylibloader_wrapper_xlib)( Display*, Window, long, XEvent*);
+extern int (*XCirculateSubwindows_dylibloader_wrapper_xlib)( Display*, Window, int);
+extern int (*XCirculateSubwindowsDown_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XCirculateSubwindowsUp_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XClearArea_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int, int);
+extern int (*XClearWindow_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XCloseDisplay_dylibloader_wrapper_xlib)( Display*);
+extern int (*XConfigureWindow_dylibloader_wrapper_xlib)( Display*, Window, unsigned int, XWindowChanges*);
+extern int (*XConnectionNumber_dylibloader_wrapper_xlib)( Display*);
+extern int (*XConvertSelection_dylibloader_wrapper_xlib)( Display*, Atom, Atom, Atom, Window, Time);
+extern int (*XCopyArea_dylibloader_wrapper_xlib)( Display*, Drawable, Drawable, GC, int, int, unsigned int, unsigned int, int, int);
+extern int (*XCopyGC_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, GC);
+extern int (*XCopyPlane_dylibloader_wrapper_xlib)( Display*, Drawable, Drawable, GC, int, int, unsigned int, unsigned int, int, int, unsigned long);
+extern int (*XDefaultDepth_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XDefaultDepthOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XDefaultScreen_dylibloader_wrapper_xlib)( Display*);
+extern int (*XDefineCursor_dylibloader_wrapper_xlib)( Display*, Window, Cursor);
+extern int (*XDeleteProperty_dylibloader_wrapper_xlib)( Display*, Window, Atom);
+extern int (*XDestroyWindow_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XDestroySubwindows_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XDoesBackingStore_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XDoesSaveUnders_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XDisableAccessControl_dylibloader_wrapper_xlib)( Display*);
+extern int (*XDisplayCells_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XDisplayHeight_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XDisplayHeightMM_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XDisplayKeycodes_dylibloader_wrapper_xlib)( Display*, int*, int*);
+extern int (*XDisplayPlanes_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XDisplayWidth_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XDisplayWidthMM_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XDrawArc_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int, int, int);
+extern int (*XDrawArcs_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XArc*, int);
+extern int (*XDrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const char*, int);
+extern int (*XDrawImageString16_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const XChar2b*, int);
+extern int (*XDrawLine_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, int, int);
+extern int (*XDrawLines_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XPoint*, int, int);
+extern int (*XDrawPoint_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int);
+extern int (*XDrawPoints_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XPoint*, int, int);
+extern int (*XDrawRectangle_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int);
+extern int (*XDrawRectangles_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XRectangle*, int);
+extern int (*XDrawSegments_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XSegment*, int);
+extern int (*XDrawString_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const char*, int);
+extern int (*XDrawString16_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int,const XChar2b*, int);
+extern int (*XDrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XTextItem*, int);
+extern int (*XDrawText16_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XTextItem16*, int);
+extern int (*XEnableAccessControl_dylibloader_wrapper_xlib)( Display*);
+extern int (*XEventsQueued_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XFetchName_dylibloader_wrapper_xlib)( Display*, Window, char**);
+extern int (*XFillArc_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int, int, int);
+extern int (*XFillArcs_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XArc*, int);
+extern int (*XFillPolygon_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XPoint*, int, int, int);
+extern int (*XFillRectangle_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, unsigned int, unsigned int);
+extern int (*XFillRectangles_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XRectangle*, int);
+extern int (*XFlush_dylibloader_wrapper_xlib)( Display*);
+extern int (*XForceScreenSaver_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XFree_dylibloader_wrapper_xlib)( void*);
+extern int (*XFreeColormap_dylibloader_wrapper_xlib)( Display*, Colormap);
+extern int (*XFreeColors_dylibloader_wrapper_xlib)( Display*, Colormap, unsigned long*, int, unsigned long);
+extern int (*XFreeCursor_dylibloader_wrapper_xlib)( Display*, Cursor);
+extern int (*XFreeExtensionList_dylibloader_wrapper_xlib)( char**);
+extern int (*XFreeFont_dylibloader_wrapper_xlib)( Display*, XFontStruct*);
+extern int (*XFreeFontInfo_dylibloader_wrapper_xlib)( char**, XFontStruct*, int);
+extern int (*XFreeFontNames_dylibloader_wrapper_xlib)( char**);
+extern int (*XFreeFontPath_dylibloader_wrapper_xlib)( char**);
+extern int (*XFreeGC_dylibloader_wrapper_xlib)( Display*, GC);
+extern int (*XFreeModifiermap_dylibloader_wrapper_xlib)( XModifierKeymap*);
+extern int (*XFreePixmap_dylibloader_wrapper_xlib)( Display*, Pixmap);
+extern int (*XGeometry_dylibloader_wrapper_xlib)( Display*, int,const char*,const char*, unsigned int, unsigned int, unsigned int, int, int, int*, int*, int*, int*);
+extern int (*XGetErrorDatabaseText_dylibloader_wrapper_xlib)( Display*,const char*,const char*,const char*, char*, int);
+extern int (*XGetErrorText_dylibloader_wrapper_xlib)( Display*, int, char*, int);
+extern int (*XGetFontProperty_dylibloader_wrapper_xlib)( XFontStruct*, Atom, unsigned long*);
+extern int (*XGetGCValues_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, XGCValues*);
+extern int (*XGetGeometry_dylibloader_wrapper_xlib)( Display*, Drawable, Window*, int*, int*, unsigned int*, unsigned int*, unsigned int*, unsigned int*);
+extern int (*XGetIconName_dylibloader_wrapper_xlib)( Display*, Window, char**);
+extern int (*XGetInputFocus_dylibloader_wrapper_xlib)( Display*, Window*, int*);
+extern int (*XGetKeyboardControl_dylibloader_wrapper_xlib)( Display*, XKeyboardState*);
+extern int (*XGetPointerControl_dylibloader_wrapper_xlib)( Display*, int*, int*, int*);
+extern int (*XGetPointerMapping_dylibloader_wrapper_xlib)( Display*, unsigned char*, int);
+extern int (*XGetScreenSaver_dylibloader_wrapper_xlib)( Display*, int*, int*, int*, int*);
+extern int (*XGetTransientForHint_dylibloader_wrapper_xlib)( Display*, Window, Window*);
+extern int (*XGetWindowProperty_dylibloader_wrapper_xlib)( Display*, Window, Atom, long, long, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+extern int (*XGetWindowAttributes_dylibloader_wrapper_xlib)( Display*, Window, XWindowAttributes*);
+extern int (*XGrabButton_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, Window, int, unsigned int, int, int, Window, Cursor);
+extern int (*XGrabKey_dylibloader_wrapper_xlib)( Display*, int, unsigned int, Window, int, int, int);
+extern int (*XGrabKeyboard_dylibloader_wrapper_xlib)( Display*, Window, int, int, int, Time);
+extern int (*XGrabPointer_dylibloader_wrapper_xlib)( Display*, Window, int, unsigned int, int, int, Window, Cursor, Time);
+extern int (*XGrabServer_dylibloader_wrapper_xlib)( Display*);
+extern int (*XHeightMMOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XHeightOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XIfEvent_dylibloader_wrapper_xlib)( Display*, XEvent*, Bool (*) (Display*, XEvent*, XPointer), XPointer);
+extern int (*XImageByteOrder_dylibloader_wrapper_xlib)( Display*);
+extern int (*XInstallColormap_dylibloader_wrapper_xlib)( Display*, Colormap);
+extern KeyCode (*XKeysymToKeycode_dylibloader_wrapper_xlib)( Display*, KeySym);
+extern int (*XKillClient_dylibloader_wrapper_xlib)( Display*, XID);
+extern int (*XLookupColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, XColor*, XColor*);
+extern int (*XLowerWindow_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XMapRaised_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XMapSubwindows_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XMapWindow_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XMaskEvent_dylibloader_wrapper_xlib)( Display*, long, XEvent*);
+extern int (*XMaxCmapsOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XMinCmapsOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XMoveResizeWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int, unsigned int, unsigned int);
+extern int (*XMoveWindow_dylibloader_wrapper_xlib)( Display*, Window, int, int);
+extern int (*XNextEvent_dylibloader_wrapper_xlib)( Display*, XEvent*);
+extern int (*XNoOp_dylibloader_wrapper_xlib)( Display*);
+extern int (*XParseColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, XColor*);
+extern int (*XParseGeometry_dylibloader_wrapper_xlib)(const char*, int*, int*, unsigned int*, unsigned int*);
+extern int (*XPeekEvent_dylibloader_wrapper_xlib)( Display*, XEvent*);
+extern int (*XPeekIfEvent_dylibloader_wrapper_xlib)( Display*, XEvent*, Bool (*) (Display*, XEvent*, XPointer), XPointer);
+extern int (*XPending_dylibloader_wrapper_xlib)( Display*);
+extern int (*XPlanesOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XProtocolRevision_dylibloader_wrapper_xlib)( Display*);
+extern int (*XProtocolVersion_dylibloader_wrapper_xlib)( Display*);
+extern int (*XPutBackEvent_dylibloader_wrapper_xlib)( Display*, XEvent*);
+extern int (*XPutImage_dylibloader_wrapper_xlib)( Display*, Drawable, GC, XImage*, int, int, int, int, unsigned int, unsigned int);
+extern int (*XQLength_dylibloader_wrapper_xlib)( Display*);
+extern int (*XQueryBestCursor_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+extern int (*XQueryBestSize_dylibloader_wrapper_xlib)( Display*, int, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+extern int (*XQueryBestStipple_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+extern int (*XQueryBestTile_dylibloader_wrapper_xlib)( Display*, Drawable, unsigned int, unsigned int, unsigned int*, unsigned int*);
+extern int (*XQueryColor_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*);
+extern int (*XQueryColors_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*, int);
+extern int (*XQueryExtension_dylibloader_wrapper_xlib)( Display*,const char*, int*, int*, int*);
+extern int (*XQueryKeymap_dylibloader_wrapper_xlib)( Display*, char [32]);
+extern int (*XQueryPointer_dylibloader_wrapper_xlib)( Display*, Window, Window*, Window*, int*, int*, int*, int*, unsigned int*);
+extern int (*XQueryTextExtents_dylibloader_wrapper_xlib)( Display*, XID,const char*, int, int*, int*, int*, XCharStruct*);
+extern int (*XQueryTextExtents16_dylibloader_wrapper_xlib)( Display*, XID,const XChar2b*, int, int*, int*, int*, XCharStruct*);
+extern int (*XQueryTree_dylibloader_wrapper_xlib)( Display*, Window, Window*, Window*, Window**, unsigned int*);
+extern int (*XRaiseWindow_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XReadBitmapFile_dylibloader_wrapper_xlib)( Display*, Drawable,const char*, unsigned int*, unsigned int*, Pixmap*, int*, int*);
+extern int (*XReadBitmapFileData_dylibloader_wrapper_xlib)(const char*, unsigned int*, unsigned int*, unsigned char**, int*, int*);
+extern int (*XRebindKeysym_dylibloader_wrapper_xlib)( Display*, KeySym, KeySym*, int,const unsigned char*, int);
+extern int (*XRecolorCursor_dylibloader_wrapper_xlib)( Display*, Cursor, XColor*, XColor*);
+extern int (*XRefreshKeyboardMapping_dylibloader_wrapper_xlib)( XMappingEvent*);
+extern int (*XRemoveFromSaveSet_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XRemoveHost_dylibloader_wrapper_xlib)( Display*, XHostAddress*);
+extern int (*XRemoveHosts_dylibloader_wrapper_xlib)( Display*, XHostAddress*, int);
+extern int (*XReparentWindow_dylibloader_wrapper_xlib)( Display*, Window, Window, int, int);
+extern int (*XResetScreenSaver_dylibloader_wrapper_xlib)( Display*);
+extern int (*XResizeWindow_dylibloader_wrapper_xlib)( Display*, Window, unsigned int, unsigned int);
+extern int (*XRestackWindows_dylibloader_wrapper_xlib)( Display*, Window*, int);
+extern int (*XRotateBuffers_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XRotateWindowProperties_dylibloader_wrapper_xlib)( Display*, Window, Atom*, int, int);
+extern int (*XScreenCount_dylibloader_wrapper_xlib)( Display*);
+extern int (*XSelectInput_dylibloader_wrapper_xlib)( Display*, Window, long);
+extern int (*XSendEvent_dylibloader_wrapper_xlib)( Display*, Window, int, long, XEvent*);
+extern int (*XSetAccessControl_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XSetArcMode_dylibloader_wrapper_xlib)( Display*, GC, int);
+extern int (*XSetBackground_dylibloader_wrapper_xlib)( Display*, GC, unsigned long);
+extern int (*XSetClipMask_dylibloader_wrapper_xlib)( Display*, GC, Pixmap);
+extern int (*XSetClipOrigin_dylibloader_wrapper_xlib)( Display*, GC, int, int);
+extern int (*XSetClipRectangles_dylibloader_wrapper_xlib)( Display*, GC, int, int, XRectangle*, int, int);
+extern int (*XSetCloseDownMode_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XSetCommand_dylibloader_wrapper_xlib)( Display*, Window, char**, int);
+extern int (*XSetDashes_dylibloader_wrapper_xlib)( Display*, GC, int,const char*, int);
+extern int (*XSetFillRule_dylibloader_wrapper_xlib)( Display*, GC, int);
+extern int (*XSetFillStyle_dylibloader_wrapper_xlib)( Display*, GC, int);
+extern int (*XSetFont_dylibloader_wrapper_xlib)( Display*, GC, Font);
+extern int (*XSetFontPath_dylibloader_wrapper_xlib)( Display*, char**, int);
+extern int (*XSetForeground_dylibloader_wrapper_xlib)( Display*, GC, unsigned long);
+extern int (*XSetFunction_dylibloader_wrapper_xlib)( Display*, GC, int);
+extern int (*XSetGraphicsExposures_dylibloader_wrapper_xlib)( Display*, GC, int);
+extern int (*XSetIconName_dylibloader_wrapper_xlib)( Display*, Window,const char*);
+extern int (*XSetInputFocus_dylibloader_wrapper_xlib)( Display*, Window, int, Time);
+extern int (*XSetLineAttributes_dylibloader_wrapper_xlib)( Display*, GC, unsigned int, int, int, int);
+extern int (*XSetModifierMapping_dylibloader_wrapper_xlib)( Display*, XModifierKeymap*);
+extern int (*XSetPlaneMask_dylibloader_wrapper_xlib)( Display*, GC, unsigned long);
+extern int (*XSetPointerMapping_dylibloader_wrapper_xlib)( Display*,const unsigned char*, int);
+extern int (*XSetScreenSaver_dylibloader_wrapper_xlib)( Display*, int, int, int, int);
+extern int (*XSetSelectionOwner_dylibloader_wrapper_xlib)( Display*, Atom, Window, Time);
+extern int (*XSetState_dylibloader_wrapper_xlib)( Display*, GC, unsigned long, unsigned long, int, unsigned long);
+extern int (*XSetStipple_dylibloader_wrapper_xlib)( Display*, GC, Pixmap);
+extern int (*XSetSubwindowMode_dylibloader_wrapper_xlib)( Display*, GC, int);
+extern int (*XSetTSOrigin_dylibloader_wrapper_xlib)( Display*, GC, int, int);
+extern int (*XSetTile_dylibloader_wrapper_xlib)( Display*, GC, Pixmap);
+extern int (*XSetWindowBackground_dylibloader_wrapper_xlib)( Display*, Window, unsigned long);
+extern int (*XSetWindowBackgroundPixmap_dylibloader_wrapper_xlib)( Display*, Window, Pixmap);
+extern int (*XSetWindowBorder_dylibloader_wrapper_xlib)( Display*, Window, unsigned long);
+extern int (*XSetWindowBorderPixmap_dylibloader_wrapper_xlib)( Display*, Window, Pixmap);
+extern int (*XSetWindowBorderWidth_dylibloader_wrapper_xlib)( Display*, Window, unsigned int);
+extern int (*XSetWindowColormap_dylibloader_wrapper_xlib)( Display*, Window, Colormap);
+extern int (*XStoreBuffer_dylibloader_wrapper_xlib)( Display*,const char*, int, int);
+extern int (*XStoreBytes_dylibloader_wrapper_xlib)( Display*,const char*, int);
+extern int (*XStoreColor_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*);
+extern int (*XStoreColors_dylibloader_wrapper_xlib)( Display*, Colormap, XColor*, int);
+extern int (*XStoreName_dylibloader_wrapper_xlib)( Display*, Window,const char*);
+extern int (*XStoreNamedColor_dylibloader_wrapper_xlib)( Display*, Colormap,const char*, unsigned long, int);
+extern int (*XSync_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XTextExtents_dylibloader_wrapper_xlib)( XFontStruct*,const char*, int, int*, int*, int*, XCharStruct*);
+extern int (*XTextExtents16_dylibloader_wrapper_xlib)( XFontStruct*,const XChar2b*, int, int*, int*, int*, XCharStruct*);
+extern int (*XTextWidth_dylibloader_wrapper_xlib)( XFontStruct*,const char*, int);
+extern int (*XTextWidth16_dylibloader_wrapper_xlib)( XFontStruct*,const XChar2b*, int);
+extern int (*XTranslateCoordinates_dylibloader_wrapper_xlib)( Display*, Window, Window, int, int, int*, int*, Window*);
+extern int (*XUndefineCursor_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XUngrabButton_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, Window);
+extern int (*XUngrabKey_dylibloader_wrapper_xlib)( Display*, int, unsigned int, Window);
+extern int (*XUngrabKeyboard_dylibloader_wrapper_xlib)( Display*, Time);
+extern int (*XUngrabPointer_dylibloader_wrapper_xlib)( Display*, Time);
+extern int (*XUngrabServer_dylibloader_wrapper_xlib)( Display*);
+extern int (*XUninstallColormap_dylibloader_wrapper_xlib)( Display*, Colormap);
+extern int (*XUnloadFont_dylibloader_wrapper_xlib)( Display*, Font);
+extern int (*XUnmapSubwindows_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XUnmapWindow_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XVendorRelease_dylibloader_wrapper_xlib)( Display*);
+extern int (*XWarpPointer_dylibloader_wrapper_xlib)( Display*, Window, Window, int, int, unsigned int, unsigned int, int, int);
+extern int (*XWidthMMOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XWidthOfScreen_dylibloader_wrapper_xlib)( Screen*);
+extern int (*XWindowEvent_dylibloader_wrapper_xlib)( Display*, Window, long, XEvent*);
+extern int (*XWriteBitmapFile_dylibloader_wrapper_xlib)( Display*,const char*, Pixmap, unsigned int, unsigned int, int, int);
+extern int (*XSupportsLocale_dylibloader_wrapper_xlib)( void);
+extern char* (*XSetLocaleModifiers_dylibloader_wrapper_xlib)(const char*);
+extern XOM (*XOpenOM_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*,const char*,const char*);
+extern int (*XCloseOM_dylibloader_wrapper_xlib)( XOM);
+extern char* (*XSetOMValues_dylibloader_wrapper_xlib)( XOM,...);
+extern char* (*XGetOMValues_dylibloader_wrapper_xlib)( XOM,...);
+extern Display* (*XDisplayOfOM_dylibloader_wrapper_xlib)( XOM);
+extern char* (*XLocaleOfOM_dylibloader_wrapper_xlib)( XOM);
+extern XOC (*XCreateOC_dylibloader_wrapper_xlib)( XOM,...);
+extern void (*XDestroyOC_dylibloader_wrapper_xlib)( XOC);
+extern XOM (*XOMOfOC_dylibloader_wrapper_xlib)( XOC);
+extern char* (*XSetOCValues_dylibloader_wrapper_xlib)( XOC,...);
+extern char* (*XGetOCValues_dylibloader_wrapper_xlib)( XOC,...);
+extern XFontSet (*XCreateFontSet_dylibloader_wrapper_xlib)( Display*,const char*, char***, int*, char**);
+extern void (*XFreeFontSet_dylibloader_wrapper_xlib)( Display*, XFontSet);
+extern int (*XFontsOfFontSet_dylibloader_wrapper_xlib)( XFontSet, XFontStruct***, char***);
+extern char* (*XBaseFontNameListOfFontSet_dylibloader_wrapper_xlib)( XFontSet);
+extern char* (*XLocaleOfFontSet_dylibloader_wrapper_xlib)( XFontSet);
+extern int (*XContextDependentDrawing_dylibloader_wrapper_xlib)( XFontSet);
+extern int (*XDirectionalDependentDrawing_dylibloader_wrapper_xlib)( XFontSet);
+extern int (*XContextualDrawing_dylibloader_wrapper_xlib)( XFontSet);
+extern XFontSetExtents* (*XExtentsOfFontSet_dylibloader_wrapper_xlib)( XFontSet);
+extern int (*XmbTextEscapement_dylibloader_wrapper_xlib)( XFontSet,const char*, int);
+extern int (*XwcTextEscapement_dylibloader_wrapper_xlib)( XFontSet,const wchar_t*, int);
+extern int (*Xutf8TextEscapement_dylibloader_wrapper_xlib)( XFontSet,const char*, int);
+extern int (*XmbTextExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*);
+extern int (*XwcTextExtents_dylibloader_wrapper_xlib)( XFontSet,const wchar_t*, int, XRectangle*, XRectangle*);
+extern int (*Xutf8TextExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*);
+extern int (*XmbTextPerCharExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*, int, int*, XRectangle*, XRectangle*);
+extern int (*XwcTextPerCharExtents_dylibloader_wrapper_xlib)( XFontSet,const wchar_t*, int, XRectangle*, XRectangle*, int, int*, XRectangle*, XRectangle*);
+extern int (*Xutf8TextPerCharExtents_dylibloader_wrapper_xlib)( XFontSet,const char*, int, XRectangle*, XRectangle*, int, int*, XRectangle*, XRectangle*);
+extern void (*XmbDrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XmbTextItem*, int);
+extern void (*XwcDrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XwcTextItem*, int);
+extern void (*Xutf8DrawText_dylibloader_wrapper_xlib)( Display*, Drawable, GC, int, int, XmbTextItem*, int);
+extern void (*XmbDrawString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+extern void (*XwcDrawString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const wchar_t*, int);
+extern void (*Xutf8DrawString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+extern void (*XmbDrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+extern void (*XwcDrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const wchar_t*, int);
+extern void (*Xutf8DrawImageString_dylibloader_wrapper_xlib)( Display*, Drawable, XFontSet, GC, int, int,const char*, int);
+extern XIM (*XOpenIM_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*, char*, char*);
+extern int (*XCloseIM_dylibloader_wrapper_xlib)( XIM);
+extern char* (*XGetIMValues_dylibloader_wrapper_xlib)( XIM,...);
+extern char* (*XSetIMValues_dylibloader_wrapper_xlib)( XIM,...);
+extern Display* (*XDisplayOfIM_dylibloader_wrapper_xlib)( XIM);
+extern char* (*XLocaleOfIM_dylibloader_wrapper_xlib)( XIM);
+extern XIC (*XCreateIC_dylibloader_wrapper_xlib)( XIM,...);
+extern void (*XDestroyIC_dylibloader_wrapper_xlib)( XIC);
+extern void (*XSetICFocus_dylibloader_wrapper_xlib)( XIC);
+extern void (*XUnsetICFocus_dylibloader_wrapper_xlib)( XIC);
+extern wchar_t* (*XwcResetIC_dylibloader_wrapper_xlib)( XIC);
+extern char* (*XmbResetIC_dylibloader_wrapper_xlib)( XIC);
+extern char* (*Xutf8ResetIC_dylibloader_wrapper_xlib)( XIC);
+extern char* (*XSetICValues_dylibloader_wrapper_xlib)( XIC,...);
+extern char* (*XGetICValues_dylibloader_wrapper_xlib)( XIC,...);
+extern XIM (*XIMOfIC_dylibloader_wrapper_xlib)( XIC);
+extern int (*XFilterEvent_dylibloader_wrapper_xlib)( XEvent*, Window);
+extern int (*XmbLookupString_dylibloader_wrapper_xlib)( XIC, XKeyPressedEvent*, char*, int, KeySym*, int*);
+extern int (*XwcLookupString_dylibloader_wrapper_xlib)( XIC, XKeyPressedEvent*, wchar_t*, int, KeySym*, int*);
+extern int (*Xutf8LookupString_dylibloader_wrapper_xlib)( XIC, XKeyPressedEvent*, char*, int, KeySym*, int*);
+extern XVaNestedList (*XVaCreateNestedList_dylibloader_wrapper_xlib)( int,...);
+extern int (*XRegisterIMInstantiateCallback_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*, char*, char*, XIDProc, XPointer);
+extern int (*XUnregisterIMInstantiateCallback_dylibloader_wrapper_xlib)( Display*,struct _XrmHashBucketRec*, char*, char*, XIDProc, XPointer);
+extern int (*XInternalConnectionNumbers_dylibloader_wrapper_xlib)( Display*, int**, int*);
+extern void (*XProcessInternalConnection_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XAddConnectionWatch_dylibloader_wrapper_xlib)( Display*, XConnectionWatchProc, XPointer);
+extern void (*XRemoveConnectionWatch_dylibloader_wrapper_xlib)( Display*, XConnectionWatchProc, XPointer);
+extern void (*XSetAuthorization_dylibloader_wrapper_xlib)( char*, int, char*, int);
+extern int (*_Xmbtowc_dylibloader_wrapper_xlib)( wchar_t*, char*, int);
+extern int (*_Xwctomb_dylibloader_wrapper_xlib)( char*, wchar_t);
+extern int (*XGetEventData_dylibloader_wrapper_xlib)( Display*, XGenericEventCookie*);
+extern void (*XFreeEventData_dylibloader_wrapper_xlib)( Display*, XGenericEventCookie*);
+extern XClassHint* (*XAllocClassHint_dylibloader_wrapper_xlib)( void);
+extern XIconSize* (*XAllocIconSize_dylibloader_wrapper_xlib)( void);
+extern XSizeHints* (*XAllocSizeHints_dylibloader_wrapper_xlib)( void);
+extern XStandardColormap* (*XAllocStandardColormap_dylibloader_wrapper_xlib)( void);
+extern XWMHints* (*XAllocWMHints_dylibloader_wrapper_xlib)( void);
+extern int (*XClipBox_dylibloader_wrapper_xlib)( Region, XRectangle*);
+extern Region (*XCreateRegion_dylibloader_wrapper_xlib)( void);
+extern const char* (*XDefaultString_dylibloader_wrapper_xlib)( void);
+extern int (*XDeleteContext_dylibloader_wrapper_xlib)( Display*, XID, XContext);
+extern int (*XDestroyRegion_dylibloader_wrapper_xlib)( Region);
+extern int (*XEmptyRegion_dylibloader_wrapper_xlib)( Region);
+extern int (*XEqualRegion_dylibloader_wrapper_xlib)( Region, Region);
+extern int (*XFindContext_dylibloader_wrapper_xlib)( Display*, XID, XContext, XPointer*);
+extern int (*XGetClassHint_dylibloader_wrapper_xlib)( Display*, Window, XClassHint*);
+extern int (*XGetIconSizes_dylibloader_wrapper_xlib)( Display*, Window, XIconSize**, int*);
+extern int (*XGetNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+extern int (*XGetRGBColormaps_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap**, int*, Atom);
+extern int (*XGetSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, Atom);
+extern int (*XGetStandardColormap_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap*, Atom);
+extern int (*XGetTextProperty_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*, Atom);
+extern XVisualInfo* (*XGetVisualInfo_dylibloader_wrapper_xlib)( Display*, long, XVisualInfo*, int*);
+extern int (*XGetWMClientMachine_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+extern XWMHints* (*XGetWMHints_dylibloader_wrapper_xlib)( Display*, Window);
+extern int (*XGetWMIconName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+extern int (*XGetWMName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+extern int (*XGetWMNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, long*);
+extern int (*XGetWMSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, long*, Atom);
+extern int (*XGetZoomHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+extern int (*XIntersectRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+extern void (*XConvertCase_dylibloader_wrapper_xlib)( KeySym, KeySym*, KeySym*);
+extern int (*XLookupString_dylibloader_wrapper_xlib)( XKeyEvent*, char*, int, KeySym*, XComposeStatus*);
+extern int (*XMatchVisualInfo_dylibloader_wrapper_xlib)( Display*, int, int, int, XVisualInfo*);
+extern int (*XOffsetRegion_dylibloader_wrapper_xlib)( Region, int, int);
+extern int (*XPointInRegion_dylibloader_wrapper_xlib)( Region, int, int);
+extern Region (*XPolygonRegion_dylibloader_wrapper_xlib)( XPoint*, int, int);
+extern int (*XRectInRegion_dylibloader_wrapper_xlib)( Region, int, int, unsigned int, unsigned int);
+extern int (*XSaveContext_dylibloader_wrapper_xlib)( Display*, XID, XContext,const char*);
+extern int (*XSetClassHint_dylibloader_wrapper_xlib)( Display*, Window, XClassHint*);
+extern int (*XSetIconSizes_dylibloader_wrapper_xlib)( Display*, Window, XIconSize*, int);
+extern int (*XSetNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+extern void (*XSetRGBColormaps_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap*, int, Atom);
+extern int (*XSetSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, Atom);
+extern int (*XSetStandardProperties_dylibloader_wrapper_xlib)( Display*, Window,const char*,const char*, Pixmap, char**, int, XSizeHints*);
+extern void (*XSetTextProperty_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*, Atom);
+extern void (*XSetWMClientMachine_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+extern int (*XSetWMHints_dylibloader_wrapper_xlib)( Display*, Window, XWMHints*);
+extern void (*XSetWMIconName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+extern void (*XSetWMName_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*);
+extern void (*XSetWMNormalHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+extern void (*XSetWMProperties_dylibloader_wrapper_xlib)( Display*, Window, XTextProperty*, XTextProperty*, char**, int, XSizeHints*, XWMHints*, XClassHint*);
+extern void (*XmbSetWMProperties_dylibloader_wrapper_xlib)( Display*, Window,const char*,const char*, char**, int, XSizeHints*, XWMHints*, XClassHint*);
+extern void (*Xutf8SetWMProperties_dylibloader_wrapper_xlib)( Display*, Window,const char*,const char*, char**, int, XSizeHints*, XWMHints*, XClassHint*);
+extern void (*XSetWMSizeHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*, Atom);
+extern int (*XSetRegion_dylibloader_wrapper_xlib)( Display*, GC, Region);
+extern void (*XSetStandardColormap_dylibloader_wrapper_xlib)( Display*, Window, XStandardColormap*, Atom);
+extern int (*XSetZoomHints_dylibloader_wrapper_xlib)( Display*, Window, XSizeHints*);
+extern int (*XShrinkRegion_dylibloader_wrapper_xlib)( Region, int, int);
+extern int (*XStringListToTextProperty_dylibloader_wrapper_xlib)( char**, int, XTextProperty*);
+extern int (*XSubtractRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+extern int (*XmbTextListToTextProperty_dylibloader_wrapper_xlib)( Display*, char**, int, XICCEncodingStyle, XTextProperty*);
+extern int (*XwcTextListToTextProperty_dylibloader_wrapper_xlib)( Display*, wchar_t**, int, XICCEncodingStyle, XTextProperty*);
+extern int (*Xutf8TextListToTextProperty_dylibloader_wrapper_xlib)( Display*, char**, int, XICCEncodingStyle, XTextProperty*);
+extern void (*XwcFreeStringList_dylibloader_wrapper_xlib)( wchar_t**);
+extern int (*XTextPropertyToStringList_dylibloader_wrapper_xlib)( XTextProperty*, char***, int*);
+extern int (*XmbTextPropertyToTextList_dylibloader_wrapper_xlib)( Display*,const XTextProperty*, char***, int*);
+extern int (*XwcTextPropertyToTextList_dylibloader_wrapper_xlib)( Display*,const XTextProperty*, wchar_t***, int*);
+extern int (*Xutf8TextPropertyToTextList_dylibloader_wrapper_xlib)( Display*,const XTextProperty*, char***, int*);
+extern int (*XUnionRectWithRegion_dylibloader_wrapper_xlib)( XRectangle*, Region, Region);
+extern int (*XUnionRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+extern int (*XWMGeometry_dylibloader_wrapper_xlib)( Display*, int,const char*,const char*, unsigned int, XSizeHints*, int*, int*, int*, int*, int*);
+extern int (*XXorRegion_dylibloader_wrapper_xlib)( Region, Region, Region);
+extern int (*XkbIgnoreExtension_dylibloader_wrapper_xlib)( int);
+extern Display* (*XkbOpenDisplay_dylibloader_wrapper_xlib)( char*, int*, int*, int*, int*, int*);
+extern int (*XkbQueryExtension_dylibloader_wrapper_xlib)( Display*, int*, int*, int*, int*, int*);
+extern int (*XkbUseExtension_dylibloader_wrapper_xlib)( Display*, int*, int*);
+extern int (*XkbLibraryVersion_dylibloader_wrapper_xlib)( int*, int*);
+extern unsigned int (*XkbSetXlibControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+extern unsigned int (*XkbGetXlibControls_dylibloader_wrapper_xlib)( Display*);
+extern unsigned int (*XkbXlibControlsImplemented_dylibloader_wrapper_xlib)( void);
+extern void (*XkbSetAtomFuncs_dylibloader_wrapper_xlib)( XkbInternAtomFunc, XkbGetAtomNameFunc);
+extern KeySym (*XkbKeycodeToKeysym_dylibloader_wrapper_xlib)( Display*, KeyCode, int, int);
+extern unsigned int (*XkbKeysymToModifiers_dylibloader_wrapper_xlib)( Display*, KeySym);
+extern int (*XkbLookupKeySym_dylibloader_wrapper_xlib)( Display*, KeyCode, unsigned int, unsigned int*, KeySym*);
+extern int (*XkbLookupKeyBinding_dylibloader_wrapper_xlib)( Display*, KeySym, unsigned int, char*, int, int*);
+extern int (*XkbTranslateKeyCode_dylibloader_wrapper_xlib)( XkbDescPtr, KeyCode, unsigned int, unsigned int*, KeySym*);
+extern int (*XkbTranslateKeySym_dylibloader_wrapper_xlib)( Display*, KeySym*, unsigned int, char*, int, int*);
+extern int (*XkbSetAutoRepeatRate_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+extern int (*XkbGetAutoRepeatRate_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*, unsigned int*);
+extern int (*XkbChangeEnabledControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+extern int (*XkbDeviceBell_dylibloader_wrapper_xlib)( Display*, Window, int, int, int, int, Atom);
+extern int (*XkbForceDeviceBell_dylibloader_wrapper_xlib)( Display*, int, int, int, int);
+extern int (*XkbDeviceBellEvent_dylibloader_wrapper_xlib)( Display*, Window, int, int, int, int, Atom);
+extern int (*XkbBell_dylibloader_wrapper_xlib)( Display*, Window, int, Atom);
+extern int (*XkbForceBell_dylibloader_wrapper_xlib)( Display*, int);
+extern int (*XkbBellEvent_dylibloader_wrapper_xlib)( Display*, Window, int, Atom);
+extern int (*XkbSelectEvents_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+extern int (*XkbSelectEventDetails_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned long, unsigned long);
+extern void (*XkbNoteMapChanges_dylibloader_wrapper_xlib)( XkbMapChangesPtr, XkbMapNotifyEvent*, unsigned int);
+extern void (*XkbNoteNameChanges_dylibloader_wrapper_xlib)( XkbNameChangesPtr, XkbNamesNotifyEvent*, unsigned int);
+extern int (*XkbGetIndicatorState_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*);
+extern int (*XkbGetIndicatorMap_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+extern int (*XkbSetIndicatorMap_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+extern int (*XkbGetNamedIndicator_dylibloader_wrapper_xlib)( Display*, Atom, int*, int*, XkbIndicatorMapPtr, int*);
+extern int (*XkbGetNamedDeviceIndicator_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, Atom, int*, int*, XkbIndicatorMapPtr, int*);
+extern int (*XkbSetNamedIndicator_dylibloader_wrapper_xlib)( Display*, Atom, int, int, int, XkbIndicatorMapPtr);
+extern int (*XkbSetNamedDeviceIndicator_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, Atom, int, int, int, XkbIndicatorMapPtr);
+extern int (*XkbLockModifiers_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+extern int (*XkbLatchModifiers_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int);
+extern int (*XkbLockGroup_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+extern int (*XkbLatchGroup_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+extern int (*XkbSetServerInternalMods_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int);
+extern int (*XkbSetIgnoreLockMods_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, unsigned int, unsigned int);
+extern int (*XkbVirtualModsToReal_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int*);
+extern int (*XkbComputeEffectiveMap_dylibloader_wrapper_xlib)( XkbDescPtr, XkbKeyTypePtr, unsigned char*);
+extern int (*XkbInitCanonicalKeyTypes_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+extern XkbDescPtr (*XkbAllocKeyboard_dylibloader_wrapper_xlib)( void);
+extern void (*XkbFreeKeyboard_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+extern int (*XkbAllocClientMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int);
+extern int (*XkbAllocServerMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int);
+extern void (*XkbFreeClientMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+extern void (*XkbFreeServerMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+extern XkbKeyTypePtr (*XkbAddKeyType_dylibloader_wrapper_xlib)( XkbDescPtr, Atom, int, int, int);
+extern int (*XkbAllocIndicatorMaps_dylibloader_wrapper_xlib)( XkbDescPtr);
+extern void (*XkbFreeIndicatorMaps_dylibloader_wrapper_xlib)( XkbDescPtr);
+extern XkbDescPtr (*XkbGetMap_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+extern int (*XkbGetUpdatedMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+extern int (*XkbGetMapChanges_dylibloader_wrapper_xlib)( Display*, XkbDescPtr, XkbMapChangesPtr);
+extern int (*XkbRefreshKeyboardMapping_dylibloader_wrapper_xlib)( XkbMapNotifyEvent*);
+extern int (*XkbGetKeyTypes_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbGetKeySyms_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbGetKeyActions_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbGetKeyBehaviors_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbGetVirtualMods_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+extern int (*XkbGetKeyExplicitComponents_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbGetKeyModifierMap_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbGetKeyVirtualModMap_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbAllocControls_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int);
+extern void (*XkbFreeControls_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+extern int (*XkbGetControls_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+extern int (*XkbSetControls_dylibloader_wrapper_xlib)( Display*, unsigned long, XkbDescPtr);
+extern void (*XkbNoteControlsChanges_dylibloader_wrapper_xlib)( XkbControlsChangesPtr, XkbControlsNotifyEvent*, unsigned int);
+extern int (*XkbAllocCompatMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, unsigned int);
+extern void (*XkbFreeCompatMap_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+extern int (*XkbGetCompatMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+extern int (*XkbSetCompatMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr, int);
+extern int (*XkbAllocNames_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int, int);
+extern int (*XkbGetNames_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+extern int (*XkbSetNames_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, XkbDescPtr);
+extern int (*XkbChangeNames_dylibloader_wrapper_xlib)( Display*, XkbDescPtr, XkbNameChangesPtr);
+extern void (*XkbFreeNames_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, int);
+extern int (*XkbGetState_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbStatePtr);
+extern int (*XkbSetMap_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDescPtr);
+extern int (*XkbChangeMap_dylibloader_wrapper_xlib)( Display*, XkbDescPtr, XkbMapChangesPtr);
+extern int (*XkbSetDetectableAutoRepeat_dylibloader_wrapper_xlib)( Display*, int, int*);
+extern int (*XkbGetDetectableAutoRepeat_dylibloader_wrapper_xlib)( Display*, int*);
+extern int (*XkbSetAutoResetControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*, unsigned int*);
+extern int (*XkbGetAutoResetControls_dylibloader_wrapper_xlib)( Display*, unsigned int*, unsigned int*);
+extern int (*XkbSetPerClientControls_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int*);
+extern int (*XkbGetPerClientControls_dylibloader_wrapper_xlib)( Display*, unsigned int*);
+extern int (*XkbCopyKeyType_dylibloader_wrapper_xlib)( XkbKeyTypePtr, XkbKeyTypePtr);
+extern int (*XkbCopyKeyTypes_dylibloader_wrapper_xlib)( XkbKeyTypePtr, XkbKeyTypePtr, int);
+extern int (*XkbResizeKeyType_dylibloader_wrapper_xlib)( XkbDescPtr, int, int, int, int);
+extern KeySym* (*XkbResizeKeySyms_dylibloader_wrapper_xlib)( XkbDescPtr, int, int);
+extern XkbAction* (*XkbResizeKeyActions_dylibloader_wrapper_xlib)( XkbDescPtr, int, int);
+extern int (*XkbChangeTypesOfKey_dylibloader_wrapper_xlib)( XkbDescPtr, int, int, unsigned int, int*, XkbMapChangesPtr);
+extern int (*XkbChangeKeycodeRange_dylibloader_wrapper_xlib)( XkbDescPtr, int, int, XkbChangesPtr);
+extern XkbComponentListPtr (*XkbListComponents_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbComponentNamesPtr, int*);
+extern void (*XkbFreeComponentList_dylibloader_wrapper_xlib)( XkbComponentListPtr);
+extern XkbDescPtr (*XkbGetKeyboard_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int);
+extern XkbDescPtr (*XkbGetKeyboardByName_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbComponentNamesPtr, unsigned int, unsigned int, int);
+extern int (*XkbKeyTypesForCoreSymbols_dylibloader_wrapper_xlib)( XkbDescPtr, int, KeySym*, unsigned int, int*, KeySym*);
+extern int (*XkbApplyCompatMapToKey_dylibloader_wrapper_xlib)( XkbDescPtr, KeyCode, XkbChangesPtr);
+extern int (*XkbUpdateMapFromCore_dylibloader_wrapper_xlib)( XkbDescPtr, KeyCode, int, int, KeySym*, XkbChangesPtr);
+extern XkbDeviceLedInfoPtr (*XkbAddDeviceLedInfo_dylibloader_wrapper_xlib)( XkbDeviceInfoPtr, unsigned int, unsigned int);
+extern int (*XkbResizeDeviceButtonActions_dylibloader_wrapper_xlib)( XkbDeviceInfoPtr, unsigned int);
+extern XkbDeviceInfoPtr (*XkbAllocDeviceInfo_dylibloader_wrapper_xlib)( unsigned int, unsigned int, unsigned int);
+extern void (*XkbFreeDeviceInfo_dylibloader_wrapper_xlib)( XkbDeviceInfoPtr, unsigned int, int);
+extern void (*XkbNoteDeviceChanges_dylibloader_wrapper_xlib)( XkbDeviceChangesPtr, XkbExtensionDeviceNotifyEvent*, unsigned int);
+extern XkbDeviceInfoPtr (*XkbGetDeviceInfo_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, unsigned int, unsigned int);
+extern int (*XkbGetDeviceInfoChanges_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, XkbDeviceChangesPtr);
+extern int (*XkbGetDeviceButtonActions_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, int, unsigned int, unsigned int);
+extern int (*XkbGetDeviceLedInfo_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, unsigned int, unsigned int, unsigned int);
+extern int (*XkbSetDeviceInfo_dylibloader_wrapper_xlib)( Display*, unsigned int, XkbDeviceInfoPtr);
+extern int (*XkbChangeDeviceInfo_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, XkbDeviceChangesPtr);
+extern int (*XkbSetDeviceLedInfo_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, unsigned int, unsigned int, unsigned int);
+extern int (*XkbSetDeviceButtonActions_dylibloader_wrapper_xlib)( Display*, XkbDeviceInfoPtr, unsigned int, unsigned int);
+extern char (*XkbToControl_dylibloader_wrapper_xlib)( char);
+extern int (*XkbSetDebuggingFlags_dylibloader_wrapper_xlib)( Display*, unsigned int, unsigned int, char*, unsigned int, unsigned int, unsigned int*, unsigned int*);
+extern int (*XkbApplyVirtualModChanges_dylibloader_wrapper_xlib)( XkbDescPtr, unsigned int, XkbChangesPtr);
+extern int (*XkbUpdateActionVirtualMods_dylibloader_wrapper_xlib)( XkbDescPtr, XkbAction*, unsigned int);
+extern void (*XkbUpdateKeyTypeVirtualMods_dylibloader_wrapper_xlib)( XkbDescPtr, XkbKeyTypePtr, unsigned int, XkbChangesPtr);
+int initialize_xlib(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.c
new file mode 100644
index 0000000000..21e30a03de
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.c
@@ -0,0 +1,797 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:13:54
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/Xrandr.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xrandr.h" --soname libXrandr.so.2 --init-name xrandr --output-header ./platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.c
+//
+// NOTE: Generated from Xrandr 1.5.2.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11 and libXrender, but absent in libXrandr.so.2, were removed.
+#include <stdint.h>
+
+#define XRRQueryExtension XRRQueryExtension_dylibloader_orig_xrandr
+#define XRRQueryVersion XRRQueryVersion_dylibloader_orig_xrandr
+#define XRRGetScreenInfo XRRGetScreenInfo_dylibloader_orig_xrandr
+#define XRRFreeScreenConfigInfo XRRFreeScreenConfigInfo_dylibloader_orig_xrandr
+#define XRRSetScreenConfig XRRSetScreenConfig_dylibloader_orig_xrandr
+#define XRRSetScreenConfigAndRate XRRSetScreenConfigAndRate_dylibloader_orig_xrandr
+#define XRRConfigRotations XRRConfigRotations_dylibloader_orig_xrandr
+#define XRRConfigTimes XRRConfigTimes_dylibloader_orig_xrandr
+#define XRRConfigSizes XRRConfigSizes_dylibloader_orig_xrandr
+#define XRRConfigRates XRRConfigRates_dylibloader_orig_xrandr
+#define XRRConfigCurrentConfiguration XRRConfigCurrentConfiguration_dylibloader_orig_xrandr
+#define XRRConfigCurrentRate XRRConfigCurrentRate_dylibloader_orig_xrandr
+#define XRRRootToScreen XRRRootToScreen_dylibloader_orig_xrandr
+#define XRRSelectInput XRRSelectInput_dylibloader_orig_xrandr
+#define XRRRotations XRRRotations_dylibloader_orig_xrandr
+#define XRRSizes XRRSizes_dylibloader_orig_xrandr
+#define XRRRates XRRRates_dylibloader_orig_xrandr
+#define XRRTimes XRRTimes_dylibloader_orig_xrandr
+#define XRRGetScreenSizeRange XRRGetScreenSizeRange_dylibloader_orig_xrandr
+#define XRRSetScreenSize XRRSetScreenSize_dylibloader_orig_xrandr
+#define XRRGetScreenResources XRRGetScreenResources_dylibloader_orig_xrandr
+#define XRRFreeScreenResources XRRFreeScreenResources_dylibloader_orig_xrandr
+#define XRRGetOutputInfo XRRGetOutputInfo_dylibloader_orig_xrandr
+#define XRRFreeOutputInfo XRRFreeOutputInfo_dylibloader_orig_xrandr
+#define XRRListOutputProperties XRRListOutputProperties_dylibloader_orig_xrandr
+#define XRRQueryOutputProperty XRRQueryOutputProperty_dylibloader_orig_xrandr
+#define XRRConfigureOutputProperty XRRConfigureOutputProperty_dylibloader_orig_xrandr
+#define XRRChangeOutputProperty XRRChangeOutputProperty_dylibloader_orig_xrandr
+#define XRRDeleteOutputProperty XRRDeleteOutputProperty_dylibloader_orig_xrandr
+#define XRRGetOutputProperty XRRGetOutputProperty_dylibloader_orig_xrandr
+#define XRRAllocModeInfo XRRAllocModeInfo_dylibloader_orig_xrandr
+#define XRRCreateMode XRRCreateMode_dylibloader_orig_xrandr
+#define XRRDestroyMode XRRDestroyMode_dylibloader_orig_xrandr
+#define XRRAddOutputMode XRRAddOutputMode_dylibloader_orig_xrandr
+#define XRRDeleteOutputMode XRRDeleteOutputMode_dylibloader_orig_xrandr
+#define XRRFreeModeInfo XRRFreeModeInfo_dylibloader_orig_xrandr
+#define XRRGetCrtcInfo XRRGetCrtcInfo_dylibloader_orig_xrandr
+#define XRRFreeCrtcInfo XRRFreeCrtcInfo_dylibloader_orig_xrandr
+#define XRRSetCrtcConfig XRRSetCrtcConfig_dylibloader_orig_xrandr
+#define XRRGetCrtcGammaSize XRRGetCrtcGammaSize_dylibloader_orig_xrandr
+#define XRRGetCrtcGamma XRRGetCrtcGamma_dylibloader_orig_xrandr
+#define XRRAllocGamma XRRAllocGamma_dylibloader_orig_xrandr
+#define XRRSetCrtcGamma XRRSetCrtcGamma_dylibloader_orig_xrandr
+#define XRRFreeGamma XRRFreeGamma_dylibloader_orig_xrandr
+#define XRRGetScreenResourcesCurrent XRRGetScreenResourcesCurrent_dylibloader_orig_xrandr
+#define XRRSetCrtcTransform XRRSetCrtcTransform_dylibloader_orig_xrandr
+#define XRRGetCrtcTransform XRRGetCrtcTransform_dylibloader_orig_xrandr
+#define XRRUpdateConfiguration XRRUpdateConfiguration_dylibloader_orig_xrandr
+#define XRRGetPanning XRRGetPanning_dylibloader_orig_xrandr
+#define XRRFreePanning XRRFreePanning_dylibloader_orig_xrandr
+#define XRRSetPanning XRRSetPanning_dylibloader_orig_xrandr
+#define XRRSetOutputPrimary XRRSetOutputPrimary_dylibloader_orig_xrandr
+#define XRRGetOutputPrimary XRRGetOutputPrimary_dylibloader_orig_xrandr
+#define XRRGetProviderResources XRRGetProviderResources_dylibloader_orig_xrandr
+#define XRRFreeProviderResources XRRFreeProviderResources_dylibloader_orig_xrandr
+#define XRRGetProviderInfo XRRGetProviderInfo_dylibloader_orig_xrandr
+#define XRRFreeProviderInfo XRRFreeProviderInfo_dylibloader_orig_xrandr
+#define XRRSetProviderOutputSource XRRSetProviderOutputSource_dylibloader_orig_xrandr
+#define XRRSetProviderOffloadSink XRRSetProviderOffloadSink_dylibloader_orig_xrandr
+#define XRRListProviderProperties XRRListProviderProperties_dylibloader_orig_xrandr
+#define XRRQueryProviderProperty XRRQueryProviderProperty_dylibloader_orig_xrandr
+#define XRRConfigureProviderProperty XRRConfigureProviderProperty_dylibloader_orig_xrandr
+#define XRRChangeProviderProperty XRRChangeProviderProperty_dylibloader_orig_xrandr
+#define XRRDeleteProviderProperty XRRDeleteProviderProperty_dylibloader_orig_xrandr
+#define XRRGetProviderProperty XRRGetProviderProperty_dylibloader_orig_xrandr
+#define XRRAllocateMonitor XRRAllocateMonitor_dylibloader_orig_xrandr
+#define XRRGetMonitors XRRGetMonitors_dylibloader_orig_xrandr
+#define XRRSetMonitor XRRSetMonitor_dylibloader_orig_xrandr
+#define XRRDeleteMonitor XRRDeleteMonitor_dylibloader_orig_xrandr
+#define XRRFreeMonitors XRRFreeMonitors_dylibloader_orig_xrandr
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xrandr.h"
+#undef XRRQueryExtension
+#undef XRRQueryVersion
+#undef XRRGetScreenInfo
+#undef XRRFreeScreenConfigInfo
+#undef XRRSetScreenConfig
+#undef XRRSetScreenConfigAndRate
+#undef XRRConfigRotations
+#undef XRRConfigTimes
+#undef XRRConfigSizes
+#undef XRRConfigRates
+#undef XRRConfigCurrentConfiguration
+#undef XRRConfigCurrentRate
+#undef XRRRootToScreen
+#undef XRRSelectInput
+#undef XRRRotations
+#undef XRRSizes
+#undef XRRRates
+#undef XRRTimes
+#undef XRRGetScreenSizeRange
+#undef XRRSetScreenSize
+#undef XRRGetScreenResources
+#undef XRRFreeScreenResources
+#undef XRRGetOutputInfo
+#undef XRRFreeOutputInfo
+#undef XRRListOutputProperties
+#undef XRRQueryOutputProperty
+#undef XRRConfigureOutputProperty
+#undef XRRChangeOutputProperty
+#undef XRRDeleteOutputProperty
+#undef XRRGetOutputProperty
+#undef XRRAllocModeInfo
+#undef XRRCreateMode
+#undef XRRDestroyMode
+#undef XRRAddOutputMode
+#undef XRRDeleteOutputMode
+#undef XRRFreeModeInfo
+#undef XRRGetCrtcInfo
+#undef XRRFreeCrtcInfo
+#undef XRRSetCrtcConfig
+#undef XRRGetCrtcGammaSize
+#undef XRRGetCrtcGamma
+#undef XRRAllocGamma
+#undef XRRSetCrtcGamma
+#undef XRRFreeGamma
+#undef XRRGetScreenResourcesCurrent
+#undef XRRSetCrtcTransform
+#undef XRRGetCrtcTransform
+#undef XRRUpdateConfiguration
+#undef XRRGetPanning
+#undef XRRFreePanning
+#undef XRRSetPanning
+#undef XRRSetOutputPrimary
+#undef XRRGetOutputPrimary
+#undef XRRGetProviderResources
+#undef XRRFreeProviderResources
+#undef XRRGetProviderInfo
+#undef XRRFreeProviderInfo
+#undef XRRSetProviderOutputSource
+#undef XRRSetProviderOffloadSink
+#undef XRRListProviderProperties
+#undef XRRQueryProviderProperty
+#undef XRRConfigureProviderProperty
+#undef XRRChangeProviderProperty
+#undef XRRDeleteProviderProperty
+#undef XRRGetProviderProperty
+#undef XRRAllocateMonitor
+#undef XRRGetMonitors
+#undef XRRSetMonitor
+#undef XRRDeleteMonitor
+#undef XRRFreeMonitors
+#include <dlfcn.h>
+#include <stdio.h>
+int (*XRRQueryExtension_dylibloader_wrapper_xrandr)( Display*, int*, int*);
+int (*XRRQueryVersion_dylibloader_wrapper_xrandr)( Display*, int*, int*);
+XRRScreenConfiguration* (*XRRGetScreenInfo_dylibloader_wrapper_xrandr)( Display*, Window);
+void (*XRRFreeScreenConfigInfo_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*);
+int (*XRRSetScreenConfig_dylibloader_wrapper_xrandr)( Display*, XRRScreenConfiguration*, Drawable, int, Rotation, Time);
+int (*XRRSetScreenConfigAndRate_dylibloader_wrapper_xrandr)( Display*, XRRScreenConfiguration*, Drawable, int, Rotation, short, Time);
+Rotation (*XRRConfigRotations_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, Rotation*);
+Time (*XRRConfigTimes_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, Time*);
+XRRScreenSize* (*XRRConfigSizes_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, int*);
+short* (*XRRConfigRates_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, int, int*);
+SizeID (*XRRConfigCurrentConfiguration_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, Rotation*);
+short (*XRRConfigCurrentRate_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*);
+int (*XRRRootToScreen_dylibloader_wrapper_xrandr)( Display*, Window);
+void (*XRRSelectInput_dylibloader_wrapper_xrandr)( Display*, Window, int);
+Rotation (*XRRRotations_dylibloader_wrapper_xrandr)( Display*, int, Rotation*);
+XRRScreenSize* (*XRRSizes_dylibloader_wrapper_xrandr)( Display*, int, int*);
+short* (*XRRRates_dylibloader_wrapper_xrandr)( Display*, int, int, int*);
+Time (*XRRTimes_dylibloader_wrapper_xrandr)( Display*, int, Time*);
+int (*XRRGetScreenSizeRange_dylibloader_wrapper_xrandr)( Display*, Window, int*, int*, int*, int*);
+void (*XRRSetScreenSize_dylibloader_wrapper_xrandr)( Display*, Window, int, int, int, int);
+XRRScreenResources* (*XRRGetScreenResources_dylibloader_wrapper_xrandr)( Display*, Window);
+void (*XRRFreeScreenResources_dylibloader_wrapper_xrandr)( XRRScreenResources*);
+XRROutputInfo* (*XRRGetOutputInfo_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RROutput);
+void (*XRRFreeOutputInfo_dylibloader_wrapper_xrandr)( XRROutputInfo*);
+Atom* (*XRRListOutputProperties_dylibloader_wrapper_xrandr)( Display*, RROutput, int*);
+XRRPropertyInfo* (*XRRQueryOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom);
+void (*XRRConfigureOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom, int, int, int, long*);
+void (*XRRChangeOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom, Atom, int, int,const unsigned char*, int);
+void (*XRRDeleteOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom);
+int (*XRRGetOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom, long, long, int, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+XRRModeInfo* (*XRRAllocModeInfo_dylibloader_wrapper_xrandr)(const char*, int);
+RRMode (*XRRCreateMode_dylibloader_wrapper_xrandr)( Display*, Window, XRRModeInfo*);
+void (*XRRDestroyMode_dylibloader_wrapper_xrandr)( Display*, RRMode);
+void (*XRRAddOutputMode_dylibloader_wrapper_xrandr)( Display*, RROutput, RRMode);
+void (*XRRDeleteOutputMode_dylibloader_wrapper_xrandr)( Display*, RROutput, RRMode);
+void (*XRRFreeModeInfo_dylibloader_wrapper_xrandr)( XRRModeInfo*);
+XRRCrtcInfo* (*XRRGetCrtcInfo_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc);
+void (*XRRFreeCrtcInfo_dylibloader_wrapper_xrandr)( XRRCrtcInfo*);
+int (*XRRSetCrtcConfig_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc, Time, int, int, RRMode, Rotation, RROutput*, int);
+int (*XRRGetCrtcGammaSize_dylibloader_wrapper_xrandr)( Display*, RRCrtc);
+XRRCrtcGamma* (*XRRGetCrtcGamma_dylibloader_wrapper_xrandr)( Display*, RRCrtc);
+XRRCrtcGamma* (*XRRAllocGamma_dylibloader_wrapper_xrandr)( int);
+void (*XRRSetCrtcGamma_dylibloader_wrapper_xrandr)( Display*, RRCrtc, XRRCrtcGamma*);
+void (*XRRFreeGamma_dylibloader_wrapper_xrandr)( XRRCrtcGamma*);
+XRRScreenResources* (*XRRGetScreenResourcesCurrent_dylibloader_wrapper_xrandr)( Display*, Window);
+void (*XRRSetCrtcTransform_dylibloader_wrapper_xrandr)( Display*, RRCrtc, XTransform*,const char*, XFixed*, int);
+int (*XRRGetCrtcTransform_dylibloader_wrapper_xrandr)( Display*, RRCrtc, XRRCrtcTransformAttributes**);
+int (*XRRUpdateConfiguration_dylibloader_wrapper_xrandr)( XEvent*);
+XRRPanning* (*XRRGetPanning_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc);
+void (*XRRFreePanning_dylibloader_wrapper_xrandr)( XRRPanning*);
+int (*XRRSetPanning_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc, XRRPanning*);
+void (*XRRSetOutputPrimary_dylibloader_wrapper_xrandr)( Display*, Window, RROutput);
+RROutput (*XRRGetOutputPrimary_dylibloader_wrapper_xrandr)( Display*, Window);
+XRRProviderResources* (*XRRGetProviderResources_dylibloader_wrapper_xrandr)( Display*, Window);
+void (*XRRFreeProviderResources_dylibloader_wrapper_xrandr)( XRRProviderResources*);
+XRRProviderInfo* (*XRRGetProviderInfo_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRProvider);
+void (*XRRFreeProviderInfo_dylibloader_wrapper_xrandr)( XRRProviderInfo*);
+int (*XRRSetProviderOutputSource_dylibloader_wrapper_xrandr)( Display*, XID, XID);
+int (*XRRSetProviderOffloadSink_dylibloader_wrapper_xrandr)( Display*, XID, XID);
+Atom* (*XRRListProviderProperties_dylibloader_wrapper_xrandr)( Display*, RRProvider, int*);
+XRRPropertyInfo* (*XRRQueryProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom);
+void (*XRRConfigureProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom, int, int, int, long*);
+void (*XRRChangeProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom, Atom, int, int,const unsigned char*, int);
+void (*XRRDeleteProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom);
+int (*XRRGetProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom, long, long, int, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+XRRMonitorInfo* (*XRRAllocateMonitor_dylibloader_wrapper_xrandr)( Display*, int);
+XRRMonitorInfo* (*XRRGetMonitors_dylibloader_wrapper_xrandr)( Display*, Window, int, int*);
+void (*XRRSetMonitor_dylibloader_wrapper_xrandr)( Display*, Window, XRRMonitorInfo*);
+void (*XRRDeleteMonitor_dylibloader_wrapper_xrandr)( Display*, Window, Atom);
+void (*XRRFreeMonitors_dylibloader_wrapper_xrandr)( XRRMonitorInfo*);
+int initialize_xrandr(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libXrandr.so.2", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// XRRQueryExtension
+ *(void **) (&XRRQueryExtension_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRQueryExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRQueryVersion
+ *(void **) (&XRRQueryVersion_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRQueryVersion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetScreenInfo
+ *(void **) (&XRRGetScreenInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetScreenInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeScreenConfigInfo
+ *(void **) (&XRRFreeScreenConfigInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeScreenConfigInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetScreenConfig
+ *(void **) (&XRRSetScreenConfig_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetScreenConfig");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetScreenConfigAndRate
+ *(void **) (&XRRSetScreenConfigAndRate_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetScreenConfigAndRate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigRotations
+ *(void **) (&XRRConfigRotations_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigRotations");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigTimes
+ *(void **) (&XRRConfigTimes_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigTimes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigSizes
+ *(void **) (&XRRConfigSizes_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigSizes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigRates
+ *(void **) (&XRRConfigRates_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigRates");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigCurrentConfiguration
+ *(void **) (&XRRConfigCurrentConfiguration_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigCurrentConfiguration");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigCurrentRate
+ *(void **) (&XRRConfigCurrentRate_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigCurrentRate");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRRootToScreen
+ *(void **) (&XRRRootToScreen_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRRootToScreen");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSelectInput
+ *(void **) (&XRRSelectInput_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSelectInput");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRRotations
+ *(void **) (&XRRRotations_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRRotations");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSizes
+ *(void **) (&XRRSizes_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSizes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRRates
+ *(void **) (&XRRRates_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRRates");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRTimes
+ *(void **) (&XRRTimes_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRTimes");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetScreenSizeRange
+ *(void **) (&XRRGetScreenSizeRange_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetScreenSizeRange");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetScreenSize
+ *(void **) (&XRRSetScreenSize_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetScreenSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetScreenResources
+ *(void **) (&XRRGetScreenResources_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetScreenResources");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeScreenResources
+ *(void **) (&XRRFreeScreenResources_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeScreenResources");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetOutputInfo
+ *(void **) (&XRRGetOutputInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetOutputInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeOutputInfo
+ *(void **) (&XRRFreeOutputInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeOutputInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRListOutputProperties
+ *(void **) (&XRRListOutputProperties_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRListOutputProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRQueryOutputProperty
+ *(void **) (&XRRQueryOutputProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRQueryOutputProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigureOutputProperty
+ *(void **) (&XRRConfigureOutputProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigureOutputProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRChangeOutputProperty
+ *(void **) (&XRRChangeOutputProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRChangeOutputProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRDeleteOutputProperty
+ *(void **) (&XRRDeleteOutputProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRDeleteOutputProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetOutputProperty
+ *(void **) (&XRRGetOutputProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetOutputProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRAllocModeInfo
+ *(void **) (&XRRAllocModeInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRAllocModeInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRCreateMode
+ *(void **) (&XRRCreateMode_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRCreateMode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRDestroyMode
+ *(void **) (&XRRDestroyMode_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRDestroyMode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRAddOutputMode
+ *(void **) (&XRRAddOutputMode_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRAddOutputMode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRDeleteOutputMode
+ *(void **) (&XRRDeleteOutputMode_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRDeleteOutputMode");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeModeInfo
+ *(void **) (&XRRFreeModeInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeModeInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetCrtcInfo
+ *(void **) (&XRRGetCrtcInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetCrtcInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeCrtcInfo
+ *(void **) (&XRRFreeCrtcInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeCrtcInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetCrtcConfig
+ *(void **) (&XRRSetCrtcConfig_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetCrtcConfig");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetCrtcGammaSize
+ *(void **) (&XRRGetCrtcGammaSize_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetCrtcGammaSize");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetCrtcGamma
+ *(void **) (&XRRGetCrtcGamma_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetCrtcGamma");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRAllocGamma
+ *(void **) (&XRRAllocGamma_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRAllocGamma");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetCrtcGamma
+ *(void **) (&XRRSetCrtcGamma_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetCrtcGamma");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeGamma
+ *(void **) (&XRRFreeGamma_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeGamma");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetScreenResourcesCurrent
+ *(void **) (&XRRGetScreenResourcesCurrent_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetScreenResourcesCurrent");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetCrtcTransform
+ *(void **) (&XRRSetCrtcTransform_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetCrtcTransform");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetCrtcTransform
+ *(void **) (&XRRGetCrtcTransform_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetCrtcTransform");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRUpdateConfiguration
+ *(void **) (&XRRUpdateConfiguration_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRUpdateConfiguration");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetPanning
+ *(void **) (&XRRGetPanning_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetPanning");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreePanning
+ *(void **) (&XRRFreePanning_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreePanning");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetPanning
+ *(void **) (&XRRSetPanning_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetPanning");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetOutputPrimary
+ *(void **) (&XRRSetOutputPrimary_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetOutputPrimary");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetOutputPrimary
+ *(void **) (&XRRGetOutputPrimary_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetOutputPrimary");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetProviderResources
+ *(void **) (&XRRGetProviderResources_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetProviderResources");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeProviderResources
+ *(void **) (&XRRFreeProviderResources_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeProviderResources");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetProviderInfo
+ *(void **) (&XRRGetProviderInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetProviderInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeProviderInfo
+ *(void **) (&XRRFreeProviderInfo_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeProviderInfo");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetProviderOutputSource
+ *(void **) (&XRRSetProviderOutputSource_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetProviderOutputSource");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetProviderOffloadSink
+ *(void **) (&XRRSetProviderOffloadSink_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetProviderOffloadSink");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRListProviderProperties
+ *(void **) (&XRRListProviderProperties_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRListProviderProperties");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRQueryProviderProperty
+ *(void **) (&XRRQueryProviderProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRQueryProviderProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRConfigureProviderProperty
+ *(void **) (&XRRConfigureProviderProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRConfigureProviderProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRChangeProviderProperty
+ *(void **) (&XRRChangeProviderProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRChangeProviderProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRDeleteProviderProperty
+ *(void **) (&XRRDeleteProviderProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRDeleteProviderProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetProviderProperty
+ *(void **) (&XRRGetProviderProperty_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetProviderProperty");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRAllocateMonitor
+ *(void **) (&XRRAllocateMonitor_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRAllocateMonitor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRGetMonitors
+ *(void **) (&XRRGetMonitors_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRGetMonitors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRSetMonitor
+ *(void **) (&XRRSetMonitor_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRSetMonitor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRDeleteMonitor
+ *(void **) (&XRRDeleteMonitor_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRDeleteMonitor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRRFreeMonitors
+ *(void **) (&XRRFreeMonitors_dylibloader_wrapper_xrandr) = dlsym(handle, "XRRFreeMonitors");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.h
new file mode 100644
index 0000000000..f301234b53
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.h
@@ -0,0 +1,302 @@
+#ifndef DYLIBLOAD_WRAPPER_XRANDR
+#define DYLIBLOAD_WRAPPER_XRANDR
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:13:54
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/Xrandr.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xrandr.h" --soname libXrandr.so.2 --init-name xrandr --output-header ./platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xrandr-so_wrap.c
+//
+// NOTE: Generated from Xrandr 1.5.2.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11 and libXrender, but absent in libXrandr.so.2, were removed.
+#include <stdint.h>
+
+#define XRRQueryExtension XRRQueryExtension_dylibloader_orig_xrandr
+#define XRRQueryVersion XRRQueryVersion_dylibloader_orig_xrandr
+#define XRRGetScreenInfo XRRGetScreenInfo_dylibloader_orig_xrandr
+#define XRRFreeScreenConfigInfo XRRFreeScreenConfigInfo_dylibloader_orig_xrandr
+#define XRRSetScreenConfig XRRSetScreenConfig_dylibloader_orig_xrandr
+#define XRRSetScreenConfigAndRate XRRSetScreenConfigAndRate_dylibloader_orig_xrandr
+#define XRRConfigRotations XRRConfigRotations_dylibloader_orig_xrandr
+#define XRRConfigTimes XRRConfigTimes_dylibloader_orig_xrandr
+#define XRRConfigSizes XRRConfigSizes_dylibloader_orig_xrandr
+#define XRRConfigRates XRRConfigRates_dylibloader_orig_xrandr
+#define XRRConfigCurrentConfiguration XRRConfigCurrentConfiguration_dylibloader_orig_xrandr
+#define XRRConfigCurrentRate XRRConfigCurrentRate_dylibloader_orig_xrandr
+#define XRRRootToScreen XRRRootToScreen_dylibloader_orig_xrandr
+#define XRRSelectInput XRRSelectInput_dylibloader_orig_xrandr
+#define XRRRotations XRRRotations_dylibloader_orig_xrandr
+#define XRRSizes XRRSizes_dylibloader_orig_xrandr
+#define XRRRates XRRRates_dylibloader_orig_xrandr
+#define XRRTimes XRRTimes_dylibloader_orig_xrandr
+#define XRRGetScreenSizeRange XRRGetScreenSizeRange_dylibloader_orig_xrandr
+#define XRRSetScreenSize XRRSetScreenSize_dylibloader_orig_xrandr
+#define XRRGetScreenResources XRRGetScreenResources_dylibloader_orig_xrandr
+#define XRRFreeScreenResources XRRFreeScreenResources_dylibloader_orig_xrandr
+#define XRRGetOutputInfo XRRGetOutputInfo_dylibloader_orig_xrandr
+#define XRRFreeOutputInfo XRRFreeOutputInfo_dylibloader_orig_xrandr
+#define XRRListOutputProperties XRRListOutputProperties_dylibloader_orig_xrandr
+#define XRRQueryOutputProperty XRRQueryOutputProperty_dylibloader_orig_xrandr
+#define XRRConfigureOutputProperty XRRConfigureOutputProperty_dylibloader_orig_xrandr
+#define XRRChangeOutputProperty XRRChangeOutputProperty_dylibloader_orig_xrandr
+#define XRRDeleteOutputProperty XRRDeleteOutputProperty_dylibloader_orig_xrandr
+#define XRRGetOutputProperty XRRGetOutputProperty_dylibloader_orig_xrandr
+#define XRRAllocModeInfo XRRAllocModeInfo_dylibloader_orig_xrandr
+#define XRRCreateMode XRRCreateMode_dylibloader_orig_xrandr
+#define XRRDestroyMode XRRDestroyMode_dylibloader_orig_xrandr
+#define XRRAddOutputMode XRRAddOutputMode_dylibloader_orig_xrandr
+#define XRRDeleteOutputMode XRRDeleteOutputMode_dylibloader_orig_xrandr
+#define XRRFreeModeInfo XRRFreeModeInfo_dylibloader_orig_xrandr
+#define XRRGetCrtcInfo XRRGetCrtcInfo_dylibloader_orig_xrandr
+#define XRRFreeCrtcInfo XRRFreeCrtcInfo_dylibloader_orig_xrandr
+#define XRRSetCrtcConfig XRRSetCrtcConfig_dylibloader_orig_xrandr
+#define XRRGetCrtcGammaSize XRRGetCrtcGammaSize_dylibloader_orig_xrandr
+#define XRRGetCrtcGamma XRRGetCrtcGamma_dylibloader_orig_xrandr
+#define XRRAllocGamma XRRAllocGamma_dylibloader_orig_xrandr
+#define XRRSetCrtcGamma XRRSetCrtcGamma_dylibloader_orig_xrandr
+#define XRRFreeGamma XRRFreeGamma_dylibloader_orig_xrandr
+#define XRRGetScreenResourcesCurrent XRRGetScreenResourcesCurrent_dylibloader_orig_xrandr
+#define XRRSetCrtcTransform XRRSetCrtcTransform_dylibloader_orig_xrandr
+#define XRRGetCrtcTransform XRRGetCrtcTransform_dylibloader_orig_xrandr
+#define XRRUpdateConfiguration XRRUpdateConfiguration_dylibloader_orig_xrandr
+#define XRRGetPanning XRRGetPanning_dylibloader_orig_xrandr
+#define XRRFreePanning XRRFreePanning_dylibloader_orig_xrandr
+#define XRRSetPanning XRRSetPanning_dylibloader_orig_xrandr
+#define XRRSetOutputPrimary XRRSetOutputPrimary_dylibloader_orig_xrandr
+#define XRRGetOutputPrimary XRRGetOutputPrimary_dylibloader_orig_xrandr
+#define XRRGetProviderResources XRRGetProviderResources_dylibloader_orig_xrandr
+#define XRRFreeProviderResources XRRFreeProviderResources_dylibloader_orig_xrandr
+#define XRRGetProviderInfo XRRGetProviderInfo_dylibloader_orig_xrandr
+#define XRRFreeProviderInfo XRRFreeProviderInfo_dylibloader_orig_xrandr
+#define XRRSetProviderOutputSource XRRSetProviderOutputSource_dylibloader_orig_xrandr
+#define XRRSetProviderOffloadSink XRRSetProviderOffloadSink_dylibloader_orig_xrandr
+#define XRRListProviderProperties XRRListProviderProperties_dylibloader_orig_xrandr
+#define XRRQueryProviderProperty XRRQueryProviderProperty_dylibloader_orig_xrandr
+#define XRRConfigureProviderProperty XRRConfigureProviderProperty_dylibloader_orig_xrandr
+#define XRRChangeProviderProperty XRRChangeProviderProperty_dylibloader_orig_xrandr
+#define XRRDeleteProviderProperty XRRDeleteProviderProperty_dylibloader_orig_xrandr
+#define XRRGetProviderProperty XRRGetProviderProperty_dylibloader_orig_xrandr
+#define XRRAllocateMonitor XRRAllocateMonitor_dylibloader_orig_xrandr
+#define XRRGetMonitors XRRGetMonitors_dylibloader_orig_xrandr
+#define XRRSetMonitor XRRSetMonitor_dylibloader_orig_xrandr
+#define XRRDeleteMonitor XRRDeleteMonitor_dylibloader_orig_xrandr
+#define XRRFreeMonitors XRRFreeMonitors_dylibloader_orig_xrandr
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xrandr.h"
+#undef XRRQueryExtension
+#undef XRRQueryVersion
+#undef XRRGetScreenInfo
+#undef XRRFreeScreenConfigInfo
+#undef XRRSetScreenConfig
+#undef XRRSetScreenConfigAndRate
+#undef XRRConfigRotations
+#undef XRRConfigTimes
+#undef XRRConfigSizes
+#undef XRRConfigRates
+#undef XRRConfigCurrentConfiguration
+#undef XRRConfigCurrentRate
+#undef XRRRootToScreen
+#undef XRRSelectInput
+#undef XRRRotations
+#undef XRRSizes
+#undef XRRRates
+#undef XRRTimes
+#undef XRRGetScreenSizeRange
+#undef XRRSetScreenSize
+#undef XRRGetScreenResources
+#undef XRRFreeScreenResources
+#undef XRRGetOutputInfo
+#undef XRRFreeOutputInfo
+#undef XRRListOutputProperties
+#undef XRRQueryOutputProperty
+#undef XRRConfigureOutputProperty
+#undef XRRChangeOutputProperty
+#undef XRRDeleteOutputProperty
+#undef XRRGetOutputProperty
+#undef XRRAllocModeInfo
+#undef XRRCreateMode
+#undef XRRDestroyMode
+#undef XRRAddOutputMode
+#undef XRRDeleteOutputMode
+#undef XRRFreeModeInfo
+#undef XRRGetCrtcInfo
+#undef XRRFreeCrtcInfo
+#undef XRRSetCrtcConfig
+#undef XRRGetCrtcGammaSize
+#undef XRRGetCrtcGamma
+#undef XRRAllocGamma
+#undef XRRSetCrtcGamma
+#undef XRRFreeGamma
+#undef XRRGetScreenResourcesCurrent
+#undef XRRSetCrtcTransform
+#undef XRRGetCrtcTransform
+#undef XRRUpdateConfiguration
+#undef XRRGetPanning
+#undef XRRFreePanning
+#undef XRRSetPanning
+#undef XRRSetOutputPrimary
+#undef XRRGetOutputPrimary
+#undef XRRGetProviderResources
+#undef XRRFreeProviderResources
+#undef XRRGetProviderInfo
+#undef XRRFreeProviderInfo
+#undef XRRSetProviderOutputSource
+#undef XRRSetProviderOffloadSink
+#undef XRRListProviderProperties
+#undef XRRQueryProviderProperty
+#undef XRRConfigureProviderProperty
+#undef XRRChangeProviderProperty
+#undef XRRDeleteProviderProperty
+#undef XRRGetProviderProperty
+#undef XRRAllocateMonitor
+#undef XRRGetMonitors
+#undef XRRSetMonitor
+#undef XRRDeleteMonitor
+#undef XRRFreeMonitors
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define XRRQueryExtension XRRQueryExtension_dylibloader_wrapper_xrandr
+#define XRRQueryVersion XRRQueryVersion_dylibloader_wrapper_xrandr
+#define XRRGetScreenInfo XRRGetScreenInfo_dylibloader_wrapper_xrandr
+#define XRRFreeScreenConfigInfo XRRFreeScreenConfigInfo_dylibloader_wrapper_xrandr
+#define XRRSetScreenConfig XRRSetScreenConfig_dylibloader_wrapper_xrandr
+#define XRRSetScreenConfigAndRate XRRSetScreenConfigAndRate_dylibloader_wrapper_xrandr
+#define XRRConfigRotations XRRConfigRotations_dylibloader_wrapper_xrandr
+#define XRRConfigTimes XRRConfigTimes_dylibloader_wrapper_xrandr
+#define XRRConfigSizes XRRConfigSizes_dylibloader_wrapper_xrandr
+#define XRRConfigRates XRRConfigRates_dylibloader_wrapper_xrandr
+#define XRRConfigCurrentConfiguration XRRConfigCurrentConfiguration_dylibloader_wrapper_xrandr
+#define XRRConfigCurrentRate XRRConfigCurrentRate_dylibloader_wrapper_xrandr
+#define XRRRootToScreen XRRRootToScreen_dylibloader_wrapper_xrandr
+#define XRRSelectInput XRRSelectInput_dylibloader_wrapper_xrandr
+#define XRRRotations XRRRotations_dylibloader_wrapper_xrandr
+#define XRRSizes XRRSizes_dylibloader_wrapper_xrandr
+#define XRRRates XRRRates_dylibloader_wrapper_xrandr
+#define XRRTimes XRRTimes_dylibloader_wrapper_xrandr
+#define XRRGetScreenSizeRange XRRGetScreenSizeRange_dylibloader_wrapper_xrandr
+#define XRRSetScreenSize XRRSetScreenSize_dylibloader_wrapper_xrandr
+#define XRRGetScreenResources XRRGetScreenResources_dylibloader_wrapper_xrandr
+#define XRRFreeScreenResources XRRFreeScreenResources_dylibloader_wrapper_xrandr
+#define XRRGetOutputInfo XRRGetOutputInfo_dylibloader_wrapper_xrandr
+#define XRRFreeOutputInfo XRRFreeOutputInfo_dylibloader_wrapper_xrandr
+#define XRRListOutputProperties XRRListOutputProperties_dylibloader_wrapper_xrandr
+#define XRRQueryOutputProperty XRRQueryOutputProperty_dylibloader_wrapper_xrandr
+#define XRRConfigureOutputProperty XRRConfigureOutputProperty_dylibloader_wrapper_xrandr
+#define XRRChangeOutputProperty XRRChangeOutputProperty_dylibloader_wrapper_xrandr
+#define XRRDeleteOutputProperty XRRDeleteOutputProperty_dylibloader_wrapper_xrandr
+#define XRRGetOutputProperty XRRGetOutputProperty_dylibloader_wrapper_xrandr
+#define XRRAllocModeInfo XRRAllocModeInfo_dylibloader_wrapper_xrandr
+#define XRRCreateMode XRRCreateMode_dylibloader_wrapper_xrandr
+#define XRRDestroyMode XRRDestroyMode_dylibloader_wrapper_xrandr
+#define XRRAddOutputMode XRRAddOutputMode_dylibloader_wrapper_xrandr
+#define XRRDeleteOutputMode XRRDeleteOutputMode_dylibloader_wrapper_xrandr
+#define XRRFreeModeInfo XRRFreeModeInfo_dylibloader_wrapper_xrandr
+#define XRRGetCrtcInfo XRRGetCrtcInfo_dylibloader_wrapper_xrandr
+#define XRRFreeCrtcInfo XRRFreeCrtcInfo_dylibloader_wrapper_xrandr
+#define XRRSetCrtcConfig XRRSetCrtcConfig_dylibloader_wrapper_xrandr
+#define XRRGetCrtcGammaSize XRRGetCrtcGammaSize_dylibloader_wrapper_xrandr
+#define XRRGetCrtcGamma XRRGetCrtcGamma_dylibloader_wrapper_xrandr
+#define XRRAllocGamma XRRAllocGamma_dylibloader_wrapper_xrandr
+#define XRRSetCrtcGamma XRRSetCrtcGamma_dylibloader_wrapper_xrandr
+#define XRRFreeGamma XRRFreeGamma_dylibloader_wrapper_xrandr
+#define XRRGetScreenResourcesCurrent XRRGetScreenResourcesCurrent_dylibloader_wrapper_xrandr
+#define XRRSetCrtcTransform XRRSetCrtcTransform_dylibloader_wrapper_xrandr
+#define XRRGetCrtcTransform XRRGetCrtcTransform_dylibloader_wrapper_xrandr
+#define XRRUpdateConfiguration XRRUpdateConfiguration_dylibloader_wrapper_xrandr
+#define XRRGetPanning XRRGetPanning_dylibloader_wrapper_xrandr
+#define XRRFreePanning XRRFreePanning_dylibloader_wrapper_xrandr
+#define XRRSetPanning XRRSetPanning_dylibloader_wrapper_xrandr
+#define XRRSetOutputPrimary XRRSetOutputPrimary_dylibloader_wrapper_xrandr
+#define XRRGetOutputPrimary XRRGetOutputPrimary_dylibloader_wrapper_xrandr
+#define XRRGetProviderResources XRRGetProviderResources_dylibloader_wrapper_xrandr
+#define XRRFreeProviderResources XRRFreeProviderResources_dylibloader_wrapper_xrandr
+#define XRRGetProviderInfo XRRGetProviderInfo_dylibloader_wrapper_xrandr
+#define XRRFreeProviderInfo XRRFreeProviderInfo_dylibloader_wrapper_xrandr
+#define XRRSetProviderOutputSource XRRSetProviderOutputSource_dylibloader_wrapper_xrandr
+#define XRRSetProviderOffloadSink XRRSetProviderOffloadSink_dylibloader_wrapper_xrandr
+#define XRRListProviderProperties XRRListProviderProperties_dylibloader_wrapper_xrandr
+#define XRRQueryProviderProperty XRRQueryProviderProperty_dylibloader_wrapper_xrandr
+#define XRRConfigureProviderProperty XRRConfigureProviderProperty_dylibloader_wrapper_xrandr
+#define XRRChangeProviderProperty XRRChangeProviderProperty_dylibloader_wrapper_xrandr
+#define XRRDeleteProviderProperty XRRDeleteProviderProperty_dylibloader_wrapper_xrandr
+#define XRRGetProviderProperty XRRGetProviderProperty_dylibloader_wrapper_xrandr
+#define XRRAllocateMonitor XRRAllocateMonitor_dylibloader_wrapper_xrandr
+#define XRRGetMonitors XRRGetMonitors_dylibloader_wrapper_xrandr
+#define XRRSetMonitor XRRSetMonitor_dylibloader_wrapper_xrandr
+#define XRRDeleteMonitor XRRDeleteMonitor_dylibloader_wrapper_xrandr
+#define XRRFreeMonitors XRRFreeMonitors_dylibloader_wrapper_xrandr
+extern int (*XRRQueryExtension_dylibloader_wrapper_xrandr)( Display*, int*, int*);
+extern int (*XRRQueryVersion_dylibloader_wrapper_xrandr)( Display*, int*, int*);
+extern XRRScreenConfiguration* (*XRRGetScreenInfo_dylibloader_wrapper_xrandr)( Display*, Window);
+extern void (*XRRFreeScreenConfigInfo_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*);
+extern int (*XRRSetScreenConfig_dylibloader_wrapper_xrandr)( Display*, XRRScreenConfiguration*, Drawable, int, Rotation, Time);
+extern int (*XRRSetScreenConfigAndRate_dylibloader_wrapper_xrandr)( Display*, XRRScreenConfiguration*, Drawable, int, Rotation, short, Time);
+extern Rotation (*XRRConfigRotations_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, Rotation*);
+extern Time (*XRRConfigTimes_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, Time*);
+extern XRRScreenSize* (*XRRConfigSizes_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, int*);
+extern short* (*XRRConfigRates_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, int, int*);
+extern SizeID (*XRRConfigCurrentConfiguration_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*, Rotation*);
+extern short (*XRRConfigCurrentRate_dylibloader_wrapper_xrandr)( XRRScreenConfiguration*);
+extern int (*XRRRootToScreen_dylibloader_wrapper_xrandr)( Display*, Window);
+extern void (*XRRSelectInput_dylibloader_wrapper_xrandr)( Display*, Window, int);
+extern Rotation (*XRRRotations_dylibloader_wrapper_xrandr)( Display*, int, Rotation*);
+extern XRRScreenSize* (*XRRSizes_dylibloader_wrapper_xrandr)( Display*, int, int*);
+extern short* (*XRRRates_dylibloader_wrapper_xrandr)( Display*, int, int, int*);
+extern Time (*XRRTimes_dylibloader_wrapper_xrandr)( Display*, int, Time*);
+extern int (*XRRGetScreenSizeRange_dylibloader_wrapper_xrandr)( Display*, Window, int*, int*, int*, int*);
+extern void (*XRRSetScreenSize_dylibloader_wrapper_xrandr)( Display*, Window, int, int, int, int);
+extern XRRScreenResources* (*XRRGetScreenResources_dylibloader_wrapper_xrandr)( Display*, Window);
+extern void (*XRRFreeScreenResources_dylibloader_wrapper_xrandr)( XRRScreenResources*);
+extern XRROutputInfo* (*XRRGetOutputInfo_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RROutput);
+extern void (*XRRFreeOutputInfo_dylibloader_wrapper_xrandr)( XRROutputInfo*);
+extern Atom* (*XRRListOutputProperties_dylibloader_wrapper_xrandr)( Display*, RROutput, int*);
+extern XRRPropertyInfo* (*XRRQueryOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom);
+extern void (*XRRConfigureOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom, int, int, int, long*);
+extern void (*XRRChangeOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom, Atom, int, int,const unsigned char*, int);
+extern void (*XRRDeleteOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom);
+extern int (*XRRGetOutputProperty_dylibloader_wrapper_xrandr)( Display*, RROutput, Atom, long, long, int, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+extern XRRModeInfo* (*XRRAllocModeInfo_dylibloader_wrapper_xrandr)(const char*, int);
+extern RRMode (*XRRCreateMode_dylibloader_wrapper_xrandr)( Display*, Window, XRRModeInfo*);
+extern void (*XRRDestroyMode_dylibloader_wrapper_xrandr)( Display*, RRMode);
+extern void (*XRRAddOutputMode_dylibloader_wrapper_xrandr)( Display*, RROutput, RRMode);
+extern void (*XRRDeleteOutputMode_dylibloader_wrapper_xrandr)( Display*, RROutput, RRMode);
+extern void (*XRRFreeModeInfo_dylibloader_wrapper_xrandr)( XRRModeInfo*);
+extern XRRCrtcInfo* (*XRRGetCrtcInfo_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc);
+extern void (*XRRFreeCrtcInfo_dylibloader_wrapper_xrandr)( XRRCrtcInfo*);
+extern int (*XRRSetCrtcConfig_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc, Time, int, int, RRMode, Rotation, RROutput*, int);
+extern int (*XRRGetCrtcGammaSize_dylibloader_wrapper_xrandr)( Display*, RRCrtc);
+extern XRRCrtcGamma* (*XRRGetCrtcGamma_dylibloader_wrapper_xrandr)( Display*, RRCrtc);
+extern XRRCrtcGamma* (*XRRAllocGamma_dylibloader_wrapper_xrandr)( int);
+extern void (*XRRSetCrtcGamma_dylibloader_wrapper_xrandr)( Display*, RRCrtc, XRRCrtcGamma*);
+extern void (*XRRFreeGamma_dylibloader_wrapper_xrandr)( XRRCrtcGamma*);
+extern XRRScreenResources* (*XRRGetScreenResourcesCurrent_dylibloader_wrapper_xrandr)( Display*, Window);
+extern void (*XRRSetCrtcTransform_dylibloader_wrapper_xrandr)( Display*, RRCrtc, XTransform*,const char*, XFixed*, int);
+extern int (*XRRGetCrtcTransform_dylibloader_wrapper_xrandr)( Display*, RRCrtc, XRRCrtcTransformAttributes**);
+extern int (*XRRUpdateConfiguration_dylibloader_wrapper_xrandr)( XEvent*);
+extern XRRPanning* (*XRRGetPanning_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc);
+extern void (*XRRFreePanning_dylibloader_wrapper_xrandr)( XRRPanning*);
+extern int (*XRRSetPanning_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRCrtc, XRRPanning*);
+extern void (*XRRSetOutputPrimary_dylibloader_wrapper_xrandr)( Display*, Window, RROutput);
+extern RROutput (*XRRGetOutputPrimary_dylibloader_wrapper_xrandr)( Display*, Window);
+extern XRRProviderResources* (*XRRGetProviderResources_dylibloader_wrapper_xrandr)( Display*, Window);
+extern void (*XRRFreeProviderResources_dylibloader_wrapper_xrandr)( XRRProviderResources*);
+extern XRRProviderInfo* (*XRRGetProviderInfo_dylibloader_wrapper_xrandr)( Display*, XRRScreenResources*, RRProvider);
+extern void (*XRRFreeProviderInfo_dylibloader_wrapper_xrandr)( XRRProviderInfo*);
+extern int (*XRRSetProviderOutputSource_dylibloader_wrapper_xrandr)( Display*, XID, XID);
+extern int (*XRRSetProviderOffloadSink_dylibloader_wrapper_xrandr)( Display*, XID, XID);
+extern Atom* (*XRRListProviderProperties_dylibloader_wrapper_xrandr)( Display*, RRProvider, int*);
+extern XRRPropertyInfo* (*XRRQueryProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom);
+extern void (*XRRConfigureProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom, int, int, int, long*);
+extern void (*XRRChangeProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom, Atom, int, int,const unsigned char*, int);
+extern void (*XRRDeleteProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom);
+extern int (*XRRGetProviderProperty_dylibloader_wrapper_xrandr)( Display*, RRProvider, Atom, long, long, int, int, Atom, Atom*, int*, unsigned long*, unsigned long*, unsigned char**);
+extern XRRMonitorInfo* (*XRRAllocateMonitor_dylibloader_wrapper_xrandr)( Display*, int);
+extern XRRMonitorInfo* (*XRRGetMonitors_dylibloader_wrapper_xrandr)( Display*, Window, int, int*);
+extern void (*XRRSetMonitor_dylibloader_wrapper_xrandr)( Display*, Window, XRRMonitorInfo*);
+extern void (*XRRDeleteMonitor_dylibloader_wrapper_xrandr)( Display*, Window, Atom);
+extern void (*XRRFreeMonitors_dylibloader_wrapper_xrandr)( XRRMonitorInfo*);
+int initialize_xrandr(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.c b/platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.c
new file mode 100644
index 0000000000..5c720bee21
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.c
@@ -0,0 +1,511 @@
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:14:14
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/Xrender.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xrender.h" --soname libXrender.so.1 --init-name xrender --output-header ./platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.c~
+//
+// NOTE: Generated from Xrender 0.9.10.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXrender.so.1, were removed.
+#include <stdint.h>
+
+#define XRenderQueryExtension XRenderQueryExtension_dylibloader_orig_xrender
+#define XRenderQueryVersion XRenderQueryVersion_dylibloader_orig_xrender
+#define XRenderQueryFormats XRenderQueryFormats_dylibloader_orig_xrender
+#define XRenderQuerySubpixelOrder XRenderQuerySubpixelOrder_dylibloader_orig_xrender
+#define XRenderSetSubpixelOrder XRenderSetSubpixelOrder_dylibloader_orig_xrender
+#define XRenderFindVisualFormat XRenderFindVisualFormat_dylibloader_orig_xrender
+#define XRenderFindFormat XRenderFindFormat_dylibloader_orig_xrender
+#define XRenderFindStandardFormat XRenderFindStandardFormat_dylibloader_orig_xrender
+#define XRenderQueryPictIndexValues XRenderQueryPictIndexValues_dylibloader_orig_xrender
+#define XRenderCreatePicture XRenderCreatePicture_dylibloader_orig_xrender
+#define XRenderChangePicture XRenderChangePicture_dylibloader_orig_xrender
+#define XRenderSetPictureClipRectangles XRenderSetPictureClipRectangles_dylibloader_orig_xrender
+#define XRenderSetPictureClipRegion XRenderSetPictureClipRegion_dylibloader_orig_xrender
+#define XRenderSetPictureTransform XRenderSetPictureTransform_dylibloader_orig_xrender
+#define XRenderFreePicture XRenderFreePicture_dylibloader_orig_xrender
+#define XRenderComposite XRenderComposite_dylibloader_orig_xrender
+#define XRenderCreateGlyphSet XRenderCreateGlyphSet_dylibloader_orig_xrender
+#define XRenderReferenceGlyphSet XRenderReferenceGlyphSet_dylibloader_orig_xrender
+#define XRenderFreeGlyphSet XRenderFreeGlyphSet_dylibloader_orig_xrender
+#define XRenderAddGlyphs XRenderAddGlyphs_dylibloader_orig_xrender
+#define XRenderFreeGlyphs XRenderFreeGlyphs_dylibloader_orig_xrender
+#define XRenderCompositeString8 XRenderCompositeString8_dylibloader_orig_xrender
+#define XRenderCompositeString16 XRenderCompositeString16_dylibloader_orig_xrender
+#define XRenderCompositeString32 XRenderCompositeString32_dylibloader_orig_xrender
+#define XRenderCompositeText8 XRenderCompositeText8_dylibloader_orig_xrender
+#define XRenderCompositeText16 XRenderCompositeText16_dylibloader_orig_xrender
+#define XRenderCompositeText32 XRenderCompositeText32_dylibloader_orig_xrender
+#define XRenderFillRectangle XRenderFillRectangle_dylibloader_orig_xrender
+#define XRenderFillRectangles XRenderFillRectangles_dylibloader_orig_xrender
+#define XRenderCompositeTrapezoids XRenderCompositeTrapezoids_dylibloader_orig_xrender
+#define XRenderCompositeTriangles XRenderCompositeTriangles_dylibloader_orig_xrender
+#define XRenderCompositeTriStrip XRenderCompositeTriStrip_dylibloader_orig_xrender
+#define XRenderCompositeTriFan XRenderCompositeTriFan_dylibloader_orig_xrender
+#define XRenderCompositeDoublePoly XRenderCompositeDoublePoly_dylibloader_orig_xrender
+#define XRenderParseColor XRenderParseColor_dylibloader_orig_xrender
+#define XRenderCreateCursor XRenderCreateCursor_dylibloader_orig_xrender
+#define XRenderQueryFilters XRenderQueryFilters_dylibloader_orig_xrender
+#define XRenderSetPictureFilter XRenderSetPictureFilter_dylibloader_orig_xrender
+#define XRenderCreateAnimCursor XRenderCreateAnimCursor_dylibloader_orig_xrender
+#define XRenderAddTraps XRenderAddTraps_dylibloader_orig_xrender
+#define XRenderCreateSolidFill XRenderCreateSolidFill_dylibloader_orig_xrender
+#define XRenderCreateLinearGradient XRenderCreateLinearGradient_dylibloader_orig_xrender
+#define XRenderCreateRadialGradient XRenderCreateRadialGradient_dylibloader_orig_xrender
+#define XRenderCreateConicalGradient XRenderCreateConicalGradient_dylibloader_orig_xrender
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xrender.h"
+#undef XRenderQueryExtension
+#undef XRenderQueryVersion
+#undef XRenderQueryFormats
+#undef XRenderQuerySubpixelOrder
+#undef XRenderSetSubpixelOrder
+#undef XRenderFindVisualFormat
+#undef XRenderFindFormat
+#undef XRenderFindStandardFormat
+#undef XRenderQueryPictIndexValues
+#undef XRenderCreatePicture
+#undef XRenderChangePicture
+#undef XRenderSetPictureClipRectangles
+#undef XRenderSetPictureClipRegion
+#undef XRenderSetPictureTransform
+#undef XRenderFreePicture
+#undef XRenderComposite
+#undef XRenderCreateGlyphSet
+#undef XRenderReferenceGlyphSet
+#undef XRenderFreeGlyphSet
+#undef XRenderAddGlyphs
+#undef XRenderFreeGlyphs
+#undef XRenderCompositeString8
+#undef XRenderCompositeString16
+#undef XRenderCompositeString32
+#undef XRenderCompositeText8
+#undef XRenderCompositeText16
+#undef XRenderCompositeText32
+#undef XRenderFillRectangle
+#undef XRenderFillRectangles
+#undef XRenderCompositeTrapezoids
+#undef XRenderCompositeTriangles
+#undef XRenderCompositeTriStrip
+#undef XRenderCompositeTriFan
+#undef XRenderCompositeDoublePoly
+#undef XRenderParseColor
+#undef XRenderCreateCursor
+#undef XRenderQueryFilters
+#undef XRenderSetPictureFilter
+#undef XRenderCreateAnimCursor
+#undef XRenderAddTraps
+#undef XRenderCreateSolidFill
+#undef XRenderCreateLinearGradient
+#undef XRenderCreateRadialGradient
+#undef XRenderCreateConicalGradient
+#include <dlfcn.h>
+#include <stdio.h>
+int (*XRenderQueryExtension_dylibloader_wrapper_xrender)( Display*, int*, int*);
+int (*XRenderQueryVersion_dylibloader_wrapper_xrender)( Display*, int*, int*);
+int (*XRenderQueryFormats_dylibloader_wrapper_xrender)( Display*);
+int (*XRenderQuerySubpixelOrder_dylibloader_wrapper_xrender)( Display*, int);
+int (*XRenderSetSubpixelOrder_dylibloader_wrapper_xrender)( Display*, int, int);
+XRenderPictFormat* (*XRenderFindVisualFormat_dylibloader_wrapper_xrender)( Display*,const Visual*);
+XRenderPictFormat* (*XRenderFindFormat_dylibloader_wrapper_xrender)( Display*, unsigned long,const XRenderPictFormat*, int);
+XRenderPictFormat* (*XRenderFindStandardFormat_dylibloader_wrapper_xrender)( Display*, int);
+XIndexValue* (*XRenderQueryPictIndexValues_dylibloader_wrapper_xrender)( Display*,const XRenderPictFormat*, int*);
+Picture (*XRenderCreatePicture_dylibloader_wrapper_xrender)( Display*, Drawable,const XRenderPictFormat*, unsigned long,const XRenderPictureAttributes*);
+void (*XRenderChangePicture_dylibloader_wrapper_xrender)( Display*, Picture, unsigned long,const XRenderPictureAttributes*);
+void (*XRenderSetPictureClipRectangles_dylibloader_wrapper_xrender)( Display*, Picture, int, int,const XRectangle*, int);
+void (*XRenderSetPictureClipRegion_dylibloader_wrapper_xrender)( Display*, Picture, Region);
+void (*XRenderSetPictureTransform_dylibloader_wrapper_xrender)( Display*, Picture, XTransform*);
+void (*XRenderFreePicture_dylibloader_wrapper_xrender)( Display*, Picture);
+void (*XRenderComposite_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture, Picture, int, int, int, int, int, int, unsigned int, unsigned int);
+GlyphSet (*XRenderCreateGlyphSet_dylibloader_wrapper_xrender)( Display*,const XRenderPictFormat*);
+GlyphSet (*XRenderReferenceGlyphSet_dylibloader_wrapper_xrender)( Display*, GlyphSet);
+void (*XRenderFreeGlyphSet_dylibloader_wrapper_xrender)( Display*, GlyphSet);
+void (*XRenderAddGlyphs_dylibloader_wrapper_xrender)( Display*, GlyphSet,const Glyph*,const XGlyphInfo*, int,const char*, int);
+void (*XRenderFreeGlyphs_dylibloader_wrapper_xrender)( Display*, GlyphSet,const Glyph*, int);
+void (*XRenderCompositeString8_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, GlyphSet, int, int, int, int,const char*, int);
+void (*XRenderCompositeString16_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, GlyphSet, int, int, int, int,const unsigned short*, int);
+void (*XRenderCompositeString32_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, GlyphSet, int, int, int, int,const unsigned int*, int);
+void (*XRenderCompositeText8_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XGlyphElt8*, int);
+void (*XRenderCompositeText16_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XGlyphElt16*, int);
+void (*XRenderCompositeText32_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XGlyphElt32*, int);
+void (*XRenderFillRectangle_dylibloader_wrapper_xrender)( Display*, int, Picture,const XRenderColor*, int, int, unsigned int, unsigned int);
+void (*XRenderFillRectangles_dylibloader_wrapper_xrender)( Display*, int, Picture,const XRenderColor*,const XRectangle*, int);
+void (*XRenderCompositeTrapezoids_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XTrapezoid*, int);
+void (*XRenderCompositeTriangles_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XTriangle*, int);
+void (*XRenderCompositeTriStrip_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XPointFixed*, int);
+void (*XRenderCompositeTriFan_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XPointFixed*, int);
+void (*XRenderCompositeDoublePoly_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XPointDouble*, int, int);
+int (*XRenderParseColor_dylibloader_wrapper_xrender)( Display*, char*, XRenderColor*);
+Cursor (*XRenderCreateCursor_dylibloader_wrapper_xrender)( Display*, Picture, unsigned int, unsigned int);
+XFilters* (*XRenderQueryFilters_dylibloader_wrapper_xrender)( Display*, Drawable);
+void (*XRenderSetPictureFilter_dylibloader_wrapper_xrender)( Display*, Picture,const char*, XFixed*, int);
+Cursor (*XRenderCreateAnimCursor_dylibloader_wrapper_xrender)( Display*, int, XAnimCursor*);
+void (*XRenderAddTraps_dylibloader_wrapper_xrender)( Display*, Picture, int, int,const XTrap*, int);
+Picture (*XRenderCreateSolidFill_dylibloader_wrapper_xrender)( Display*,const XRenderColor*);
+Picture (*XRenderCreateLinearGradient_dylibloader_wrapper_xrender)( Display*,const XLinearGradient*,const XFixed*,const XRenderColor*, int);
+Picture (*XRenderCreateRadialGradient_dylibloader_wrapper_xrender)( Display*,const XRadialGradient*,const XFixed*,const XRenderColor*, int);
+Picture (*XRenderCreateConicalGradient_dylibloader_wrapper_xrender)( Display*,const XConicalGradient*,const XFixed*,const XRenderColor*, int);
+int initialize_xrender(int verbose) {
+ void *handle;
+ char *error;
+ handle = dlopen("libXrender.so.1", RTLD_LAZY);
+ if (!handle) {
+ if (verbose) {
+ fprintf(stderr, "%s\n", dlerror());
+ }
+ return(1);
+ }
+ dlerror();
+// XRenderQueryExtension
+ *(void **) (&XRenderQueryExtension_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderQueryExtension");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderQueryVersion
+ *(void **) (&XRenderQueryVersion_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderQueryVersion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderQueryFormats
+ *(void **) (&XRenderQueryFormats_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderQueryFormats");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderQuerySubpixelOrder
+ *(void **) (&XRenderQuerySubpixelOrder_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderQuerySubpixelOrder");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderSetSubpixelOrder
+ *(void **) (&XRenderSetSubpixelOrder_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderSetSubpixelOrder");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFindVisualFormat
+ *(void **) (&XRenderFindVisualFormat_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFindVisualFormat");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFindFormat
+ *(void **) (&XRenderFindFormat_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFindFormat");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFindStandardFormat
+ *(void **) (&XRenderFindStandardFormat_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFindStandardFormat");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderQueryPictIndexValues
+ *(void **) (&XRenderQueryPictIndexValues_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderQueryPictIndexValues");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreatePicture
+ *(void **) (&XRenderCreatePicture_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreatePicture");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderChangePicture
+ *(void **) (&XRenderChangePicture_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderChangePicture");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderSetPictureClipRectangles
+ *(void **) (&XRenderSetPictureClipRectangles_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderSetPictureClipRectangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderSetPictureClipRegion
+ *(void **) (&XRenderSetPictureClipRegion_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderSetPictureClipRegion");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderSetPictureTransform
+ *(void **) (&XRenderSetPictureTransform_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderSetPictureTransform");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFreePicture
+ *(void **) (&XRenderFreePicture_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFreePicture");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderComposite
+ *(void **) (&XRenderComposite_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderComposite");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreateGlyphSet
+ *(void **) (&XRenderCreateGlyphSet_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreateGlyphSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderReferenceGlyphSet
+ *(void **) (&XRenderReferenceGlyphSet_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderReferenceGlyphSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFreeGlyphSet
+ *(void **) (&XRenderFreeGlyphSet_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFreeGlyphSet");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderAddGlyphs
+ *(void **) (&XRenderAddGlyphs_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderAddGlyphs");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFreeGlyphs
+ *(void **) (&XRenderFreeGlyphs_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFreeGlyphs");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeString8
+ *(void **) (&XRenderCompositeString8_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeString8");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeString16
+ *(void **) (&XRenderCompositeString16_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeString16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeString32
+ *(void **) (&XRenderCompositeString32_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeString32");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeText8
+ *(void **) (&XRenderCompositeText8_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeText8");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeText16
+ *(void **) (&XRenderCompositeText16_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeText16");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeText32
+ *(void **) (&XRenderCompositeText32_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeText32");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFillRectangle
+ *(void **) (&XRenderFillRectangle_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFillRectangle");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderFillRectangles
+ *(void **) (&XRenderFillRectangles_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderFillRectangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeTrapezoids
+ *(void **) (&XRenderCompositeTrapezoids_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeTrapezoids");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeTriangles
+ *(void **) (&XRenderCompositeTriangles_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeTriangles");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeTriStrip
+ *(void **) (&XRenderCompositeTriStrip_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeTriStrip");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeTriFan
+ *(void **) (&XRenderCompositeTriFan_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeTriFan");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCompositeDoublePoly
+ *(void **) (&XRenderCompositeDoublePoly_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCompositeDoublePoly");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderParseColor
+ *(void **) (&XRenderParseColor_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderParseColor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreateCursor
+ *(void **) (&XRenderCreateCursor_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreateCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderQueryFilters
+ *(void **) (&XRenderQueryFilters_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderQueryFilters");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderSetPictureFilter
+ *(void **) (&XRenderSetPictureFilter_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderSetPictureFilter");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreateAnimCursor
+ *(void **) (&XRenderCreateAnimCursor_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreateAnimCursor");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderAddTraps
+ *(void **) (&XRenderAddTraps_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderAddTraps");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreateSolidFill
+ *(void **) (&XRenderCreateSolidFill_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreateSolidFill");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreateLinearGradient
+ *(void **) (&XRenderCreateLinearGradient_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreateLinearGradient");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreateRadialGradient
+ *(void **) (&XRenderCreateRadialGradient_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreateRadialGradient");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+// XRenderCreateConicalGradient
+ *(void **) (&XRenderCreateConicalGradient_dylibloader_wrapper_xrender) = dlsym(handle, "XRenderCreateConicalGradient");
+ if (verbose) {
+ error = dlerror();
+ if (error != NULL) {
+ fprintf(stderr, "%s\n", error);
+ }
+ }
+return 0;
+}
diff --git a/platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.h b/platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.h
new file mode 100644
index 0000000000..29a8430476
--- /dev/null
+++ b/platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.h
@@ -0,0 +1,198 @@
+#ifndef DYLIBLOAD_WRAPPER_XRENDER
+#define DYLIBLOAD_WRAPPER_XRENDER
+// This file is generated. Do not edit!
+// see https://github.com/hpvb/dynload-wrapper for details
+// generated by ../dynload-wrapper/generate-wrapper.py 0.3 on 2023-01-23 15:14:14
+// flags: ../dynload-wrapper/generate-wrapper.py --include ./thirdparty/linuxbsd_headers/X11/extensions/Xrender.h --sys-include "thirdparty/linuxbsd_headers/X11/extensions/Xrender.h" --soname libXrender.so.1 --init-name xrender --output-header ./platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.h --output-implementation ./platform/linuxbsd/x11/dynwrappers/xrender-so_wrap.c~
+//
+// NOTE: Generated from Xrender 0.9.10.
+// This has been handpatched to workaround some issues with the generator that
+// will be eventually fixed. In this case, non-existent symbols inherited from
+// libX11, but absent in libXrender.so.1, were removed.
+#include <stdint.h>
+
+#define XRenderQueryExtension XRenderQueryExtension_dylibloader_orig_xrender
+#define XRenderQueryVersion XRenderQueryVersion_dylibloader_orig_xrender
+#define XRenderQueryFormats XRenderQueryFormats_dylibloader_orig_xrender
+#define XRenderQuerySubpixelOrder XRenderQuerySubpixelOrder_dylibloader_orig_xrender
+#define XRenderSetSubpixelOrder XRenderSetSubpixelOrder_dylibloader_orig_xrender
+#define XRenderFindVisualFormat XRenderFindVisualFormat_dylibloader_orig_xrender
+#define XRenderFindFormat XRenderFindFormat_dylibloader_orig_xrender
+#define XRenderFindStandardFormat XRenderFindStandardFormat_dylibloader_orig_xrender
+#define XRenderQueryPictIndexValues XRenderQueryPictIndexValues_dylibloader_orig_xrender
+#define XRenderCreatePicture XRenderCreatePicture_dylibloader_orig_xrender
+#define XRenderChangePicture XRenderChangePicture_dylibloader_orig_xrender
+#define XRenderSetPictureClipRectangles XRenderSetPictureClipRectangles_dylibloader_orig_xrender
+#define XRenderSetPictureClipRegion XRenderSetPictureClipRegion_dylibloader_orig_xrender
+#define XRenderSetPictureTransform XRenderSetPictureTransform_dylibloader_orig_xrender
+#define XRenderFreePicture XRenderFreePicture_dylibloader_orig_xrender
+#define XRenderComposite XRenderComposite_dylibloader_orig_xrender
+#define XRenderCreateGlyphSet XRenderCreateGlyphSet_dylibloader_orig_xrender
+#define XRenderReferenceGlyphSet XRenderReferenceGlyphSet_dylibloader_orig_xrender
+#define XRenderFreeGlyphSet XRenderFreeGlyphSet_dylibloader_orig_xrender
+#define XRenderAddGlyphs XRenderAddGlyphs_dylibloader_orig_xrender
+#define XRenderFreeGlyphs XRenderFreeGlyphs_dylibloader_orig_xrender
+#define XRenderCompositeString8 XRenderCompositeString8_dylibloader_orig_xrender
+#define XRenderCompositeString16 XRenderCompositeString16_dylibloader_orig_xrender
+#define XRenderCompositeString32 XRenderCompositeString32_dylibloader_orig_xrender
+#define XRenderCompositeText8 XRenderCompositeText8_dylibloader_orig_xrender
+#define XRenderCompositeText16 XRenderCompositeText16_dylibloader_orig_xrender
+#define XRenderCompositeText32 XRenderCompositeText32_dylibloader_orig_xrender
+#define XRenderFillRectangle XRenderFillRectangle_dylibloader_orig_xrender
+#define XRenderFillRectangles XRenderFillRectangles_dylibloader_orig_xrender
+#define XRenderCompositeTrapezoids XRenderCompositeTrapezoids_dylibloader_orig_xrender
+#define XRenderCompositeTriangles XRenderCompositeTriangles_dylibloader_orig_xrender
+#define XRenderCompositeTriStrip XRenderCompositeTriStrip_dylibloader_orig_xrender
+#define XRenderCompositeTriFan XRenderCompositeTriFan_dylibloader_orig_xrender
+#define XRenderCompositeDoublePoly XRenderCompositeDoublePoly_dylibloader_orig_xrender
+#define XRenderParseColor XRenderParseColor_dylibloader_orig_xrender
+#define XRenderCreateCursor XRenderCreateCursor_dylibloader_orig_xrender
+#define XRenderQueryFilters XRenderQueryFilters_dylibloader_orig_xrender
+#define XRenderSetPictureFilter XRenderSetPictureFilter_dylibloader_orig_xrender
+#define XRenderCreateAnimCursor XRenderCreateAnimCursor_dylibloader_orig_xrender
+#define XRenderAddTraps XRenderAddTraps_dylibloader_orig_xrender
+#define XRenderCreateSolidFill XRenderCreateSolidFill_dylibloader_orig_xrender
+#define XRenderCreateLinearGradient XRenderCreateLinearGradient_dylibloader_orig_xrender
+#define XRenderCreateRadialGradient XRenderCreateRadialGradient_dylibloader_orig_xrender
+#define XRenderCreateConicalGradient XRenderCreateConicalGradient_dylibloader_orig_xrender
+#include "thirdparty/linuxbsd_headers/X11/extensions/Xrender.h"
+#undef XRenderQueryExtension
+#undef XRenderQueryVersion
+#undef XRenderQueryFormats
+#undef XRenderQuerySubpixelOrder
+#undef XRenderSetSubpixelOrder
+#undef XRenderFindVisualFormat
+#undef XRenderFindFormat
+#undef XRenderFindStandardFormat
+#undef XRenderQueryPictIndexValues
+#undef XRenderCreatePicture
+#undef XRenderChangePicture
+#undef XRenderSetPictureClipRectangles
+#undef XRenderSetPictureClipRegion
+#undef XRenderSetPictureTransform
+#undef XRenderFreePicture
+#undef XRenderComposite
+#undef XRenderCreateGlyphSet
+#undef XRenderReferenceGlyphSet
+#undef XRenderFreeGlyphSet
+#undef XRenderAddGlyphs
+#undef XRenderFreeGlyphs
+#undef XRenderCompositeString8
+#undef XRenderCompositeString16
+#undef XRenderCompositeString32
+#undef XRenderCompositeText8
+#undef XRenderCompositeText16
+#undef XRenderCompositeText32
+#undef XRenderFillRectangle
+#undef XRenderFillRectangles
+#undef XRenderCompositeTrapezoids
+#undef XRenderCompositeTriangles
+#undef XRenderCompositeTriStrip
+#undef XRenderCompositeTriFan
+#undef XRenderCompositeDoublePoly
+#undef XRenderParseColor
+#undef XRenderCreateCursor
+#undef XRenderQueryFilters
+#undef XRenderSetPictureFilter
+#undef XRenderCreateAnimCursor
+#undef XRenderAddTraps
+#undef XRenderCreateSolidFill
+#undef XRenderCreateLinearGradient
+#undef XRenderCreateRadialGradient
+#undef XRenderCreateConicalGradient
+#ifdef __cplusplus
+extern "C" {
+#endif
+#define XRenderQueryExtension XRenderQueryExtension_dylibloader_wrapper_xrender
+#define XRenderQueryVersion XRenderQueryVersion_dylibloader_wrapper_xrender
+#define XRenderQueryFormats XRenderQueryFormats_dylibloader_wrapper_xrender
+#define XRenderQuerySubpixelOrder XRenderQuerySubpixelOrder_dylibloader_wrapper_xrender
+#define XRenderSetSubpixelOrder XRenderSetSubpixelOrder_dylibloader_wrapper_xrender
+#define XRenderFindVisualFormat XRenderFindVisualFormat_dylibloader_wrapper_xrender
+#define XRenderFindFormat XRenderFindFormat_dylibloader_wrapper_xrender
+#define XRenderFindStandardFormat XRenderFindStandardFormat_dylibloader_wrapper_xrender
+#define XRenderQueryPictIndexValues XRenderQueryPictIndexValues_dylibloader_wrapper_xrender
+#define XRenderCreatePicture XRenderCreatePicture_dylibloader_wrapper_xrender
+#define XRenderChangePicture XRenderChangePicture_dylibloader_wrapper_xrender
+#define XRenderSetPictureClipRectangles XRenderSetPictureClipRectangles_dylibloader_wrapper_xrender
+#define XRenderSetPictureClipRegion XRenderSetPictureClipRegion_dylibloader_wrapper_xrender
+#define XRenderSetPictureTransform XRenderSetPictureTransform_dylibloader_wrapper_xrender
+#define XRenderFreePicture XRenderFreePicture_dylibloader_wrapper_xrender
+#define XRenderComposite XRenderComposite_dylibloader_wrapper_xrender
+#define XRenderCreateGlyphSet XRenderCreateGlyphSet_dylibloader_wrapper_xrender
+#define XRenderReferenceGlyphSet XRenderReferenceGlyphSet_dylibloader_wrapper_xrender
+#define XRenderFreeGlyphSet XRenderFreeGlyphSet_dylibloader_wrapper_xrender
+#define XRenderAddGlyphs XRenderAddGlyphs_dylibloader_wrapper_xrender
+#define XRenderFreeGlyphs XRenderFreeGlyphs_dylibloader_wrapper_xrender
+#define XRenderCompositeString8 XRenderCompositeString8_dylibloader_wrapper_xrender
+#define XRenderCompositeString16 XRenderCompositeString16_dylibloader_wrapper_xrender
+#define XRenderCompositeString32 XRenderCompositeString32_dylibloader_wrapper_xrender
+#define XRenderCompositeText8 XRenderCompositeText8_dylibloader_wrapper_xrender
+#define XRenderCompositeText16 XRenderCompositeText16_dylibloader_wrapper_xrender
+#define XRenderCompositeText32 XRenderCompositeText32_dylibloader_wrapper_xrender
+#define XRenderFillRectangle XRenderFillRectangle_dylibloader_wrapper_xrender
+#define XRenderFillRectangles XRenderFillRectangles_dylibloader_wrapper_xrender
+#define XRenderCompositeTrapezoids XRenderCompositeTrapezoids_dylibloader_wrapper_xrender
+#define XRenderCompositeTriangles XRenderCompositeTriangles_dylibloader_wrapper_xrender
+#define XRenderCompositeTriStrip XRenderCompositeTriStrip_dylibloader_wrapper_xrender
+#define XRenderCompositeTriFan XRenderCompositeTriFan_dylibloader_wrapper_xrender
+#define XRenderCompositeDoublePoly XRenderCompositeDoublePoly_dylibloader_wrapper_xrender
+#define XRenderParseColor XRenderParseColor_dylibloader_wrapper_xrender
+#define XRenderCreateCursor XRenderCreateCursor_dylibloader_wrapper_xrender
+#define XRenderQueryFilters XRenderQueryFilters_dylibloader_wrapper_xrender
+#define XRenderSetPictureFilter XRenderSetPictureFilter_dylibloader_wrapper_xrender
+#define XRenderCreateAnimCursor XRenderCreateAnimCursor_dylibloader_wrapper_xrender
+#define XRenderAddTraps XRenderAddTraps_dylibloader_wrapper_xrender
+#define XRenderCreateSolidFill XRenderCreateSolidFill_dylibloader_wrapper_xrender
+#define XRenderCreateLinearGradient XRenderCreateLinearGradient_dylibloader_wrapper_xrender
+#define XRenderCreateRadialGradient XRenderCreateRadialGradient_dylibloader_wrapper_xrender
+#define XRenderCreateConicalGradient XRenderCreateConicalGradient_dylibloader_wrapper_xrender
+extern int (*XRenderQueryExtension_dylibloader_wrapper_xrender)( Display*, int*, int*);
+extern int (*XRenderQueryVersion_dylibloader_wrapper_xrender)( Display*, int*, int*);
+extern int (*XRenderQueryFormats_dylibloader_wrapper_xrender)( Display*);
+extern int (*XRenderQuerySubpixelOrder_dylibloader_wrapper_xrender)( Display*, int);
+extern int (*XRenderSetSubpixelOrder_dylibloader_wrapper_xrender)( Display*, int, int);
+extern XRenderPictFormat* (*XRenderFindVisualFormat_dylibloader_wrapper_xrender)( Display*,const Visual*);
+extern XRenderPictFormat* (*XRenderFindFormat_dylibloader_wrapper_xrender)( Display*, unsigned long,const XRenderPictFormat*, int);
+extern XRenderPictFormat* (*XRenderFindStandardFormat_dylibloader_wrapper_xrender)( Display*, int);
+extern XIndexValue* (*XRenderQueryPictIndexValues_dylibloader_wrapper_xrender)( Display*,const XRenderPictFormat*, int*);
+extern Picture (*XRenderCreatePicture_dylibloader_wrapper_xrender)( Display*, Drawable,const XRenderPictFormat*, unsigned long,const XRenderPictureAttributes*);
+extern void (*XRenderChangePicture_dylibloader_wrapper_xrender)( Display*, Picture, unsigned long,const XRenderPictureAttributes*);
+extern void (*XRenderSetPictureClipRectangles_dylibloader_wrapper_xrender)( Display*, Picture, int, int,const XRectangle*, int);
+extern void (*XRenderSetPictureClipRegion_dylibloader_wrapper_xrender)( Display*, Picture, Region);
+extern void (*XRenderSetPictureTransform_dylibloader_wrapper_xrender)( Display*, Picture, XTransform*);
+extern void (*XRenderFreePicture_dylibloader_wrapper_xrender)( Display*, Picture);
+extern void (*XRenderComposite_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture, Picture, int, int, int, int, int, int, unsigned int, unsigned int);
+extern GlyphSet (*XRenderCreateGlyphSet_dylibloader_wrapper_xrender)( Display*,const XRenderPictFormat*);
+extern GlyphSet (*XRenderReferenceGlyphSet_dylibloader_wrapper_xrender)( Display*, GlyphSet);
+extern void (*XRenderFreeGlyphSet_dylibloader_wrapper_xrender)( Display*, GlyphSet);
+extern void (*XRenderAddGlyphs_dylibloader_wrapper_xrender)( Display*, GlyphSet,const Glyph*,const XGlyphInfo*, int,const char*, int);
+extern void (*XRenderFreeGlyphs_dylibloader_wrapper_xrender)( Display*, GlyphSet,const Glyph*, int);
+extern void (*XRenderCompositeString8_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, GlyphSet, int, int, int, int,const char*, int);
+extern void (*XRenderCompositeString16_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, GlyphSet, int, int, int, int,const unsigned short*, int);
+extern void (*XRenderCompositeString32_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, GlyphSet, int, int, int, int,const unsigned int*, int);
+extern void (*XRenderCompositeText8_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XGlyphElt8*, int);
+extern void (*XRenderCompositeText16_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XGlyphElt16*, int);
+extern void (*XRenderCompositeText32_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XGlyphElt32*, int);
+extern void (*XRenderFillRectangle_dylibloader_wrapper_xrender)( Display*, int, Picture,const XRenderColor*, int, int, unsigned int, unsigned int);
+extern void (*XRenderFillRectangles_dylibloader_wrapper_xrender)( Display*, int, Picture,const XRenderColor*,const XRectangle*, int);
+extern void (*XRenderCompositeTrapezoids_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XTrapezoid*, int);
+extern void (*XRenderCompositeTriangles_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XTriangle*, int);
+extern void (*XRenderCompositeTriStrip_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XPointFixed*, int);
+extern void (*XRenderCompositeTriFan_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int,const XPointFixed*, int);
+extern void (*XRenderCompositeDoublePoly_dylibloader_wrapper_xrender)( Display*, int, Picture, Picture,const XRenderPictFormat*, int, int, int, int,const XPointDouble*, int, int);
+extern int (*XRenderParseColor_dylibloader_wrapper_xrender)( Display*, char*, XRenderColor*);
+extern Cursor (*XRenderCreateCursor_dylibloader_wrapper_xrender)( Display*, Picture, unsigned int, unsigned int);
+extern XFilters* (*XRenderQueryFilters_dylibloader_wrapper_xrender)( Display*, Drawable);
+extern void (*XRenderSetPictureFilter_dylibloader_wrapper_xrender)( Display*, Picture,const char*, XFixed*, int);
+extern Cursor (*XRenderCreateAnimCursor_dylibloader_wrapper_xrender)( Display*, int, XAnimCursor*);
+extern void (*XRenderAddTraps_dylibloader_wrapper_xrender)( Display*, Picture, int, int,const XTrap*, int);
+extern Picture (*XRenderCreateSolidFill_dylibloader_wrapper_xrender)( Display*,const XRenderColor*);
+extern Picture (*XRenderCreateLinearGradient_dylibloader_wrapper_xrender)( Display*,const XLinearGradient*,const XFixed*,const XRenderColor*, int);
+extern Picture (*XRenderCreateRadialGradient_dylibloader_wrapper_xrender)( Display*,const XRadialGradient*,const XFixed*,const XRenderColor*, int);
+extern Picture (*XRenderCreateConicalGradient_dylibloader_wrapper_xrender)( Display*,const XConicalGradient*,const XFixed*,const XRenderColor*, int);
+int initialize_xrender(int verbose);
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/platform/linuxbsd/gl_manager_x11.cpp b/platform/linuxbsd/x11/gl_manager_x11.cpp
index 04c1df71fb..03ba95f475 100644
--- a/platform/linuxbsd/gl_manager_x11.cpp
+++ b/platform/linuxbsd/x11/gl_manager_x11.cpp
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* gl_manager_x11.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* gl_manager_x11.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#include "gl_manager_x11.h"
@@ -37,9 +37,7 @@
#include <stdlib.h>
#include <unistd.h>
-#define GLX_GLXEXT_PROTOTYPES
-#include <GL/glx.h>
-#include <GL/glxext.h>
+#include "thirdparty/glad/glad/glx.h"
#define GLX_CONTEXT_MAJOR_VERSION_ARB 0x2091
#define GLX_CONTEXT_MINOR_VERSION_ARB 0x2092
@@ -256,7 +254,11 @@ void GLManager_X11::release_current() {
if (!_current_window) {
return;
}
- glXMakeCurrent(_x_windisp.x11_display, None, nullptr);
+
+ if (!glXMakeCurrent(_x_windisp.x11_display, None, nullptr)) {
+ ERR_PRINT("glXMakeCurrent failed");
+ }
+ _current_window = nullptr;
}
void GLManager_X11::window_make_current(DisplayServer::WindowID p_window_id) {
@@ -276,7 +278,9 @@ void GLManager_X11::window_make_current(DisplayServer::WindowID p_window_id) {
const GLDisplay &disp = get_display(win.gldisplay_id);
- glXMakeCurrent(disp.x11_display, win.x11_window, disp.context->glx_context);
+ if (!glXMakeCurrent(disp.x11_display, win.x11_window, disp.context->glx_context)) {
+ ERR_PRINT("glXMakeCurrent failed");
+ }
_internal_set_current_window(&win);
}
@@ -290,13 +294,12 @@ void GLManager_X11::make_current() {
return;
}
const GLDisplay &disp = get_current_display();
- glXMakeCurrent(_x_windisp.x11_display, _x_windisp.x11_window, disp.context->glx_context);
+ if (!glXMakeCurrent(_x_windisp.x11_display, _x_windisp.x11_window, disp.context->glx_context)) {
+ ERR_PRINT("glXMakeCurrent failed");
+ }
}
void GLManager_X11::swap_buffers() {
- // NO NEED TO CALL SWAP BUFFERS for each window...
- // see https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/glXSwapBuffers.xml
-
if (!_current_window) {
return;
}
@@ -305,7 +308,7 @@ void GLManager_X11::swap_buffers() {
return;
}
- // On X11, when enabled, transparancy is always active, so clear alpha manually.
+ // On X11, when enabled, transparency is always active, so clear alpha manually.
if (OS::get_singleton()->is_layered_allowed()) {
if (!DisplayServer::get_singleton()->window_get_flag(DisplayServer::WINDOW_FLAG_TRANSPARENT, _current_window->window_id)) {
glColorMask(false, false, false, true);
@@ -315,26 +318,18 @@ void GLManager_X11::swap_buffers() {
}
}
- // print_line("\tswap_buffers");
-
- // only for debugging without drawing anything
- // glClearColor(Math::randf(), 0, 1, 1);
- //glClear(GL_COLOR_BUFFER_BIT);
-
- //const GLDisplay &disp = get_current_display();
glXSwapBuffers(_x_windisp.x11_display, _x_windisp.x11_window);
}
-Error GLManager_X11::initialize() {
+Error GLManager_X11::initialize(Display *p_display) {
+ if (!gladLoaderLoadGLX(p_display, XScreenNumberOfScreen(XDefaultScreenOfDisplay(p_display)))) {
+ return ERR_CANT_CREATE;
+ }
+
return OK;
}
void GLManager_X11::set_use_vsync(bool p_use) {
- static bool setup = false;
- static PFNGLXSWAPINTERVALEXTPROC glXSwapIntervalEXT = nullptr;
- static PFNGLXSWAPINTERVALSGIPROC glXSwapIntervalMESA = nullptr;
- static PFNGLXSWAPINTERVALSGIPROC glXSwapIntervalSGI = nullptr;
-
// force vsync in the editor for now, as a safety measure
bool is_editor = Engine::get_singleton()->is_editor_hint();
if (is_editor) {
@@ -347,25 +342,12 @@ void GLManager_X11::set_use_vsync(bool p_use) {
}
const GLDisplay &disp = get_current_display();
- if (!setup) {
- setup = true;
- String extensions = glXQueryExtensionsString(disp.x11_display, DefaultScreen(disp.x11_display));
- if (extensions.find("GLX_EXT_swap_control") != -1) {
- glXSwapIntervalEXT = (PFNGLXSWAPINTERVALEXTPROC)glXGetProcAddressARB((const GLubyte *)"glXSwapIntervalEXT");
- }
- if (extensions.find("GLX_MESA_swap_control") != -1) {
- glXSwapIntervalMESA = (PFNGLXSWAPINTERVALSGIPROC)glXGetProcAddressARB((const GLubyte *)"glXSwapIntervalMESA");
- }
- if (extensions.find("GLX_SGI_swap_control") != -1) {
- glXSwapIntervalSGI = (PFNGLXSWAPINTERVALSGIPROC)glXGetProcAddressARB((const GLubyte *)"glXSwapIntervalSGI");
- }
- }
int val = p_use ? 1 : 0;
- if (glXSwapIntervalMESA) {
+ if (GLAD_GLX_MESA_swap_control) {
glXSwapIntervalMESA(val);
- } else if (glXSwapIntervalSGI) {
+ } else if (GLAD_GLX_SGI_swap_control) {
glXSwapIntervalSGI(val);
- } else if (glXSwapIntervalEXT) {
+ } else if (GLAD_GLX_EXT_swap_control) {
GLXDrawable drawable = glXGetCurrentDrawable();
glXSwapIntervalEXT(disp.x11_display, drawable, val);
} else {
@@ -378,6 +360,17 @@ bool GLManager_X11::is_using_vsync() const {
return use_vsync;
}
+void *GLManager_X11::get_glx_context(DisplayServer::WindowID p_window_id) {
+ if (p_window_id == -1) {
+ return nullptr;
+ }
+
+ const GLWindow &win = _windows[p_window_id];
+ const GLDisplay &disp = get_display(win.gldisplay_id);
+
+ return (void *)disp.context->glx_context;
+}
+
GLManager_X11::GLManager_X11(const Vector2i &p_size, ContextType p_context_type) {
context_type = p_context_type;
diff --git a/platform/linuxbsd/gl_manager_x11.h b/platform/linuxbsd/x11/gl_manager_x11.h
index 4f78c45c88..713b13376c 100644
--- a/platform/linuxbsd/gl_manager_x11.h
+++ b/platform/linuxbsd/x11/gl_manager_x11.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* gl_manager_x11.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* gl_manager_x11.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef GL_MANAGER_X11_H
#define GL_MANAGER_X11_H
@@ -37,9 +37,10 @@
#include "core/os/os.h"
#include "core/templates/local_vector.h"
+#include "dynwrappers/xext-so_wrap.h"
+#include "dynwrappers/xlib-so_wrap.h"
+#include "dynwrappers/xrender-so_wrap.h"
#include "servers/display_server.h"
-#include <X11/Xlib.h>
-#include <X11/extensions/Xrender.h>
struct GLManager_X11_Private;
@@ -111,11 +112,13 @@ public:
void window_make_current(DisplayServer::WindowID p_window_id);
- Error initialize();
+ Error initialize(Display *p_display);
void set_use_vsync(bool p_use);
bool is_using_vsync() const;
+ void *get_glx_context(DisplayServer::WindowID p_window_id);
+
GLManager_X11(const Vector2i &p_size, ContextType p_context_type);
~GLManager_X11();
};
diff --git a/platform/linuxbsd/x11/key_mapping_x11.cpp b/platform/linuxbsd/x11/key_mapping_x11.cpp
new file mode 100644
index 0000000000..506372292d
--- /dev/null
+++ b/platform/linuxbsd/x11/key_mapping_x11.cpp
@@ -0,0 +1,1165 @@
+/**************************************************************************/
+/* key_mapping_x11.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
+
+#include "key_mapping_x11.h"
+
+#include "core/templates/hash_map.h"
+
+struct HashMapHasherKeys {
+ static _FORCE_INLINE_ uint32_t hash(const Key p_key) { return hash_fmix32(static_cast<uint32_t>(p_key)); }
+ static _FORCE_INLINE_ uint32_t hash(const char32_t p_uchar) { return hash_fmix32(p_uchar); }
+ static _FORCE_INLINE_ uint32_t hash(const unsigned p_key) { return hash_fmix32(p_key); }
+ static _FORCE_INLINE_ uint32_t hash(const KeySym p_key) { return hash_fmix32(p_key); }
+};
+
+HashMap<KeySym, Key, HashMapHasherKeys> xkeysym_map;
+HashMap<unsigned int, Key, HashMapHasherKeys> scancode_map;
+HashMap<Key, unsigned int, HashMapHasherKeys> scancode_map_inv;
+HashMap<KeySym, char32_t, HashMapHasherKeys> xkeysym_unicode_map;
+
+void KeyMappingX11::initialize() {
+ // X11 Keysym to Godot Key map.
+
+ xkeysym_map[XK_Escape] = Key::ESCAPE;
+ xkeysym_map[XK_Tab] = Key::TAB;
+ xkeysym_map[XK_ISO_Left_Tab] = Key::BACKTAB;
+ xkeysym_map[XK_BackSpace] = Key::BACKSPACE;
+ xkeysym_map[XK_Return] = Key::ENTER;
+ xkeysym_map[XK_Insert] = Key::INSERT;
+ xkeysym_map[XK_Delete] = Key::KEY_DELETE;
+ xkeysym_map[XK_Clear] = Key::KEY_DELETE;
+ xkeysym_map[XK_Pause] = Key::PAUSE;
+ xkeysym_map[XK_Print] = Key::PRINT;
+ xkeysym_map[XK_Home] = Key::HOME;
+ xkeysym_map[XK_End] = Key::END;
+ xkeysym_map[XK_Left] = Key::LEFT;
+ xkeysym_map[XK_Up] = Key::UP;
+ xkeysym_map[XK_Right] = Key::RIGHT;
+ xkeysym_map[XK_Down] = Key::DOWN;
+ xkeysym_map[XK_Prior] = Key::PAGEUP;
+ xkeysym_map[XK_Next] = Key::PAGEDOWN;
+ xkeysym_map[XK_Shift_L] = Key::SHIFT;
+ xkeysym_map[XK_Shift_R] = Key::SHIFT;
+ xkeysym_map[XK_Shift_Lock] = Key::SHIFT;
+ xkeysym_map[XK_Control_L] = Key::CTRL;
+ xkeysym_map[XK_Control_R] = Key::CTRL;
+ xkeysym_map[XK_Meta_L] = Key::META;
+ xkeysym_map[XK_Meta_R] = Key::META;
+ xkeysym_map[XK_Alt_L] = Key::ALT;
+ xkeysym_map[XK_Alt_R] = Key::ALT;
+ xkeysym_map[XK_Caps_Lock] = Key::CAPSLOCK;
+ xkeysym_map[XK_Num_Lock] = Key::NUMLOCK;
+ xkeysym_map[XK_Scroll_Lock] = Key::SCROLLLOCK;
+ xkeysym_map[XK_less] = Key::QUOTELEFT;
+ xkeysym_map[XK_grave] = Key::SECTION;
+ xkeysym_map[XK_Super_L] = Key::META;
+ xkeysym_map[XK_Super_R] = Key::META;
+ xkeysym_map[XK_Menu] = Key::MENU;
+ xkeysym_map[XK_Hyper_L] = Key::HYPER;
+ xkeysym_map[XK_Hyper_R] = Key::HYPER;
+ xkeysym_map[XK_Help] = Key::HELP;
+ xkeysym_map[XK_KP_Space] = Key::SPACE;
+ xkeysym_map[XK_KP_Tab] = Key::TAB;
+ xkeysym_map[XK_KP_Enter] = Key::KP_ENTER;
+ xkeysym_map[XK_Home] = Key::HOME;
+ xkeysym_map[XK_Left] = Key::LEFT;
+ xkeysym_map[XK_Up] = Key::UP;
+ xkeysym_map[XK_Right] = Key::RIGHT;
+ xkeysym_map[XK_Down] = Key::DOWN;
+ xkeysym_map[XK_Prior] = Key::PAGEUP;
+ xkeysym_map[XK_Next] = Key::PAGEDOWN;
+ xkeysym_map[XK_End] = Key::END;
+ xkeysym_map[XK_Begin] = Key::CLEAR;
+ xkeysym_map[XK_Insert] = Key::INSERT;
+ xkeysym_map[XK_Delete] = Key::KEY_DELETE;
+ //xkeysym_map[XK_KP_Equal]
+ //xkeysym_map[XK_KP_Separator]
+ xkeysym_map[XK_KP_Decimal] = Key::KP_PERIOD;
+ xkeysym_map[XK_KP_Delete] = Key::KP_PERIOD;
+ xkeysym_map[XK_KP_Multiply] = Key::KP_MULTIPLY;
+ xkeysym_map[XK_KP_Divide] = Key::KP_DIVIDE;
+ xkeysym_map[XK_KP_Subtract] = Key::KP_SUBTRACT;
+ xkeysym_map[XK_KP_Add] = Key::KP_ADD;
+ xkeysym_map[XK_KP_0] = Key::KP_0;
+ xkeysym_map[XK_KP_1] = Key::KP_1;
+ xkeysym_map[XK_KP_2] = Key::KP_2;
+ xkeysym_map[XK_KP_3] = Key::KP_3;
+ xkeysym_map[XK_KP_4] = Key::KP_4;
+ xkeysym_map[XK_KP_5] = Key::KP_5;
+ xkeysym_map[XK_KP_6] = Key::KP_6;
+ xkeysym_map[XK_KP_7] = Key::KP_7;
+ xkeysym_map[XK_KP_8] = Key::KP_8;
+ xkeysym_map[XK_KP_9] = Key::KP_9;
+ // Same keys but with numlock off.
+ xkeysym_map[XK_KP_Insert] = Key::INSERT;
+ xkeysym_map[XK_KP_End] = Key::END;
+ xkeysym_map[XK_KP_Down] = Key::DOWN;
+ xkeysym_map[XK_KP_Page_Down] = Key::PAGEDOWN;
+ xkeysym_map[XK_KP_Left] = Key::LEFT;
+ // X11 documents this (numpad 5) as "begin of line" but no toolkit seems to interpret it this way.
+ // On Windows this is emitting Key::Clear so for consistency it will be mapped to Key::Clear
+ xkeysym_map[XK_KP_Begin] = Key::CLEAR;
+ xkeysym_map[XK_KP_Right] = Key::RIGHT;
+ xkeysym_map[XK_KP_Home] = Key::HOME;
+ xkeysym_map[XK_KP_Up] = Key::UP;
+ xkeysym_map[XK_KP_Page_Up] = Key::PAGEUP;
+ xkeysym_map[XK_F1] = Key::F1;
+ xkeysym_map[XK_F2] = Key::F2;
+ xkeysym_map[XK_F3] = Key::F3;
+ xkeysym_map[XK_F4] = Key::F4;
+ xkeysym_map[XK_F5] = Key::F5;
+ xkeysym_map[XK_F6] = Key::F6;
+ xkeysym_map[XK_F7] = Key::F7;
+ xkeysym_map[XK_F8] = Key::F8;
+ xkeysym_map[XK_F9] = Key::F9;
+ xkeysym_map[XK_F10] = Key::F10;
+ xkeysym_map[XK_F11] = Key::F11;
+ xkeysym_map[XK_F12] = Key::F12;
+ xkeysym_map[XK_F13] = Key::F13;
+ xkeysym_map[XK_F14] = Key::F14;
+ xkeysym_map[XK_F15] = Key::F15;
+ xkeysym_map[XK_F16] = Key::F16;
+ xkeysym_map[XK_F17] = Key::F17;
+ xkeysym_map[XK_F18] = Key::F18;
+ xkeysym_map[XK_F19] = Key::F19;
+ xkeysym_map[XK_F20] = Key::F20;
+ xkeysym_map[XK_F21] = Key::F21;
+ xkeysym_map[XK_F22] = Key::F22;
+ xkeysym_map[XK_F23] = Key::F23;
+ xkeysym_map[XK_F24] = Key::F24;
+ xkeysym_map[XK_F25] = Key::F25;
+ xkeysym_map[XK_F26] = Key::F26;
+ xkeysym_map[XK_F27] = Key::F27;
+ xkeysym_map[XK_F28] = Key::F28;
+ xkeysym_map[XK_F29] = Key::F29;
+ xkeysym_map[XK_F30] = Key::F30;
+ xkeysym_map[XK_F31] = Key::F31;
+ xkeysym_map[XK_F32] = Key::F32;
+ xkeysym_map[XK_F33] = Key::F33;
+ xkeysym_map[XK_F34] = Key::F34;
+ xkeysym_map[XK_F35] = Key::F35;
+ xkeysym_map[XK_yen] = Key::YEN;
+ xkeysym_map[XK_section] = Key::SECTION;
+ // Media keys.
+ xkeysym_map[XF86XK_Back] = Key::BACK;
+ xkeysym_map[XF86XK_Forward] = Key::FORWARD;
+ xkeysym_map[XF86XK_Stop] = Key::STOP;
+ xkeysym_map[XF86XK_Refresh] = Key::REFRESH;
+ xkeysym_map[XF86XK_Favorites] = Key::FAVORITES;
+ xkeysym_map[XF86XK_OpenURL] = Key::OPENURL;
+ xkeysym_map[XF86XK_HomePage] = Key::HOMEPAGE;
+ xkeysym_map[XF86XK_Search] = Key::SEARCH;
+ xkeysym_map[XF86XK_AudioLowerVolume] = Key::VOLUMEDOWN;
+ xkeysym_map[XF86XK_AudioMute] = Key::VOLUMEMUTE;
+ xkeysym_map[XF86XK_AudioRaiseVolume] = Key::VOLUMEUP;
+ xkeysym_map[XF86XK_AudioPlay] = Key::MEDIAPLAY;
+ xkeysym_map[XF86XK_AudioStop] = Key::MEDIASTOP;
+ xkeysym_map[XF86XK_AudioPrev] = Key::MEDIAPREVIOUS;
+ xkeysym_map[XF86XK_AudioNext] = Key::MEDIANEXT;
+ xkeysym_map[XF86XK_AudioRecord] = Key::MEDIARECORD;
+ xkeysym_map[XF86XK_Standby] = Key::STANDBY;
+ // Launch keys.
+ xkeysym_map[XF86XK_Mail] = Key::LAUNCHMAIL;
+ xkeysym_map[XF86XK_AudioMedia] = Key::LAUNCHMEDIA;
+ xkeysym_map[XF86XK_MyComputer] = Key::LAUNCH0;
+ xkeysym_map[XF86XK_Calculator] = Key::LAUNCH1;
+ xkeysym_map[XF86XK_Launch0] = Key::LAUNCH2;
+ xkeysym_map[XF86XK_Launch1] = Key::LAUNCH3;
+ xkeysym_map[XF86XK_Launch2] = Key::LAUNCH4;
+ xkeysym_map[XF86XK_Launch3] = Key::LAUNCH5;
+ xkeysym_map[XF86XK_Launch4] = Key::LAUNCH6;
+ xkeysym_map[XF86XK_Launch5] = Key::LAUNCH7;
+ xkeysym_map[XF86XK_Launch6] = Key::LAUNCH8;
+ xkeysym_map[XF86XK_Launch7] = Key::LAUNCH9;
+ xkeysym_map[XF86XK_Launch8] = Key::LAUNCHA;
+ xkeysym_map[XF86XK_Launch9] = Key::LAUNCHB;
+ xkeysym_map[XF86XK_LaunchA] = Key::LAUNCHC;
+ xkeysym_map[XF86XK_LaunchB] = Key::LAUNCHD;
+ xkeysym_map[XF86XK_LaunchC] = Key::LAUNCHE;
+ xkeysym_map[XF86XK_LaunchD] = Key::LAUNCHF;
+
+ // Scancode to Godot Key map.
+ scancode_map[0x09] = Key::ESCAPE;
+ scancode_map[0x0A] = Key::KEY_1;
+ scancode_map[0x0B] = Key::KEY_2;
+ scancode_map[0x0C] = Key::KEY_3;
+ scancode_map[0x0D] = Key::KEY_4;
+ scancode_map[0x0E] = Key::KEY_5;
+ scancode_map[0x0F] = Key::KEY_6;
+ scancode_map[0x10] = Key::KEY_7;
+ scancode_map[0x11] = Key::KEY_8;
+ scancode_map[0x12] = Key::KEY_9;
+ scancode_map[0x13] = Key::KEY_0;
+ scancode_map[0x14] = Key::MINUS;
+ scancode_map[0x15] = Key::EQUAL;
+ scancode_map[0x16] = Key::BACKSPACE;
+ scancode_map[0x17] = Key::TAB;
+ scancode_map[0x18] = Key::Q;
+ scancode_map[0x19] = Key::W;
+ scancode_map[0x1A] = Key::E;
+ scancode_map[0x1B] = Key::R;
+ scancode_map[0x1C] = Key::T;
+ scancode_map[0x1D] = Key::Y;
+ scancode_map[0x1E] = Key::U;
+ scancode_map[0x1F] = Key::I;
+ scancode_map[0x20] = Key::O;
+ scancode_map[0x21] = Key::P;
+ scancode_map[0x22] = Key::BRACELEFT;
+ scancode_map[0x23] = Key::BRACERIGHT;
+ scancode_map[0x24] = Key::ENTER;
+ scancode_map[0x25] = Key::CTRL;
+ scancode_map[0x26] = Key::A;
+ scancode_map[0x27] = Key::S;
+ scancode_map[0x28] = Key::D;
+ scancode_map[0x29] = Key::F;
+ scancode_map[0x2A] = Key::G;
+ scancode_map[0x2B] = Key::H;
+ scancode_map[0x2C] = Key::J;
+ scancode_map[0x2D] = Key::K;
+ scancode_map[0x2E] = Key::L;
+ scancode_map[0x2F] = Key::SEMICOLON;
+ scancode_map[0x30] = Key::APOSTROPHE;
+ scancode_map[0x31] = Key::SECTION;
+ scancode_map[0x32] = Key::SHIFT;
+ scancode_map[0x33] = Key::BACKSLASH;
+ scancode_map[0x34] = Key::Z;
+ scancode_map[0x35] = Key::X;
+ scancode_map[0x36] = Key::C;
+ scancode_map[0x37] = Key::V;
+ scancode_map[0x38] = Key::B;
+ scancode_map[0x39] = Key::N;
+ scancode_map[0x3A] = Key::M;
+ scancode_map[0x3B] = Key::COMMA;
+ scancode_map[0x3C] = Key::PERIOD;
+ scancode_map[0x3D] = Key::SLASH;
+ scancode_map[0x3E] = Key::SHIFT;
+ scancode_map[0x3F] = Key::KP_MULTIPLY;
+ scancode_map[0x40] = Key::ALT;
+ scancode_map[0x41] = Key::SPACE;
+ scancode_map[0x42] = Key::CAPSLOCK;
+ scancode_map[0x43] = Key::F1;
+ scancode_map[0x44] = Key::F2;
+ scancode_map[0x45] = Key::F3;
+ scancode_map[0x46] = Key::F4;
+ scancode_map[0x47] = Key::F5;
+ scancode_map[0x48] = Key::F6;
+ scancode_map[0x49] = Key::F7;
+ scancode_map[0x4A] = Key::F8;
+ scancode_map[0x4B] = Key::F9;
+ scancode_map[0x4C] = Key::F10;
+ scancode_map[0x4D] = Key::NUMLOCK;
+ scancode_map[0x4E] = Key::SCROLLLOCK;
+ scancode_map[0x4F] = Key::KP_7;
+ scancode_map[0x50] = Key::KP_8;
+ scancode_map[0x51] = Key::KP_9;
+ scancode_map[0x52] = Key::KP_SUBTRACT;
+ scancode_map[0x53] = Key::KP_4;
+ scancode_map[0x54] = Key::KP_5;
+ scancode_map[0x55] = Key::KP_6;
+ scancode_map[0x56] = Key::KP_ADD;
+ scancode_map[0x57] = Key::KP_1;
+ scancode_map[0x58] = Key::KP_2;
+ scancode_map[0x59] = Key::KP_3;
+ scancode_map[0x5A] = Key::KP_0;
+ scancode_map[0x5B] = Key::KP_PERIOD;
+ scancode_map[0x5E] = Key::QUOTELEFT;
+ scancode_map[0x5F] = Key::F11;
+ scancode_map[0x60] = Key::F12;
+ scancode_map[0x68] = Key::KP_ENTER;
+ scancode_map[0x69] = Key::CTRL;
+ scancode_map[0x6A] = Key::KP_DIVIDE;
+ scancode_map[0x6B] = Key::PRINT;
+ scancode_map[0x6C] = Key::ALT;
+ scancode_map[0x6D] = Key::ENTER;
+ scancode_map[0x6E] = Key::HOME;
+ scancode_map[0x6F] = Key::UP;
+ scancode_map[0x70] = Key::PAGEUP;
+ scancode_map[0x71] = Key::LEFT;
+ scancode_map[0x72] = Key::RIGHT;
+ scancode_map[0x73] = Key::END;
+ scancode_map[0x74] = Key::DOWN;
+ scancode_map[0x75] = Key::PAGEDOWN;
+ scancode_map[0x76] = Key::INSERT;
+ scancode_map[0x77] = Key::KEY_DELETE;
+ scancode_map[0x79] = Key::VOLUMEMUTE;
+ scancode_map[0x7A] = Key::VOLUMEDOWN;
+ scancode_map[0x7B] = Key::VOLUMEUP;
+ scancode_map[0x7F] = Key::PAUSE;
+ scancode_map[0x85] = Key::META;
+ scancode_map[0x86] = Key::META;
+ scancode_map[0x87] = Key::MENU;
+ scancode_map[0xBF] = Key::F13;
+ scancode_map[0xC0] = Key::F14;
+ scancode_map[0xC1] = Key::F15;
+ scancode_map[0xC2] = Key::F16;
+ scancode_map[0xC3] = Key::F17;
+ scancode_map[0xC4] = Key::F18;
+ scancode_map[0xC5] = Key::F19;
+ scancode_map[0xC6] = Key::F20;
+ scancode_map[0xC7] = Key::F21;
+ scancode_map[0xC8] = Key::F22;
+ scancode_map[0xC9] = Key::F23;
+ scancode_map[0xCA] = Key::F24;
+ scancode_map[0xCB] = Key::F25;
+ scancode_map[0xCC] = Key::F26;
+ scancode_map[0xCD] = Key::F27;
+ scancode_map[0xCE] = Key::F28;
+ scancode_map[0xCF] = Key::F29;
+ scancode_map[0xD0] = Key::F30;
+ scancode_map[0xD1] = Key::F31;
+ scancode_map[0xD2] = Key::F32;
+ scancode_map[0xD3] = Key::F33;
+ scancode_map[0xD4] = Key::F34;
+ scancode_map[0xD5] = Key::F35;
+
+ // Godot to scancode map.
+ for (const KeyValue<unsigned int, Key> &E : scancode_map) {
+ scancode_map_inv[E.value] = E.key;
+ }
+
+ // Keysym to Unicode map, tables taken from FOX toolkit.
+ xkeysym_unicode_map[0x01A1] = 0x0104;
+ xkeysym_unicode_map[0x01A2] = 0x02D8;
+ xkeysym_unicode_map[0x01A3] = 0x0141;
+ xkeysym_unicode_map[0x01A5] = 0x013D;
+ xkeysym_unicode_map[0x01A6] = 0x015A;
+ xkeysym_unicode_map[0x01A9] = 0x0160;
+ xkeysym_unicode_map[0x01AA] = 0x015E;
+ xkeysym_unicode_map[0x01AB] = 0x0164;
+ xkeysym_unicode_map[0x01AC] = 0x0179;
+ xkeysym_unicode_map[0x01AE] = 0x017D;
+ xkeysym_unicode_map[0x01AF] = 0x017B;
+ xkeysym_unicode_map[0x01B1] = 0x0105;
+ xkeysym_unicode_map[0x01B2] = 0x02DB;
+ xkeysym_unicode_map[0x01B3] = 0x0142;
+ xkeysym_unicode_map[0x01B5] = 0x013E;
+ xkeysym_unicode_map[0x01B6] = 0x015B;
+ xkeysym_unicode_map[0x01B7] = 0x02C7;
+ xkeysym_unicode_map[0x01B9] = 0x0161;
+ xkeysym_unicode_map[0x01BA] = 0x015F;
+ xkeysym_unicode_map[0x01BB] = 0x0165;
+ xkeysym_unicode_map[0x01BC] = 0x017A;
+ xkeysym_unicode_map[0x01BD] = 0x02DD;
+ xkeysym_unicode_map[0x01BE] = 0x017E;
+ xkeysym_unicode_map[0x01BF] = 0x017C;
+ xkeysym_unicode_map[0x01C0] = 0x0154;
+ xkeysym_unicode_map[0x01C3] = 0x0102;
+ xkeysym_unicode_map[0x01C5] = 0x0139;
+ xkeysym_unicode_map[0x01C6] = 0x0106;
+ xkeysym_unicode_map[0x01C8] = 0x010C;
+ xkeysym_unicode_map[0x01CA] = 0x0118;
+ xkeysym_unicode_map[0x01CC] = 0x011A;
+ xkeysym_unicode_map[0x01CF] = 0x010E;
+ xkeysym_unicode_map[0x01D0] = 0x0110;
+ xkeysym_unicode_map[0x01D1] = 0x0143;
+ xkeysym_unicode_map[0x01D2] = 0x0147;
+ xkeysym_unicode_map[0x01D5] = 0x0150;
+ xkeysym_unicode_map[0x01D8] = 0x0158;
+ xkeysym_unicode_map[0x01D9] = 0x016E;
+ xkeysym_unicode_map[0x01DB] = 0x0170;
+ xkeysym_unicode_map[0x01DE] = 0x0162;
+ xkeysym_unicode_map[0x01E0] = 0x0155;
+ xkeysym_unicode_map[0x01E3] = 0x0103;
+ xkeysym_unicode_map[0x01E5] = 0x013A;
+ xkeysym_unicode_map[0x01E6] = 0x0107;
+ xkeysym_unicode_map[0x01E8] = 0x010D;
+ xkeysym_unicode_map[0x01EA] = 0x0119;
+ xkeysym_unicode_map[0x01EC] = 0x011B;
+ xkeysym_unicode_map[0x01EF] = 0x010F;
+ xkeysym_unicode_map[0x01F0] = 0x0111;
+ xkeysym_unicode_map[0x01F1] = 0x0144;
+ xkeysym_unicode_map[0x01F2] = 0x0148;
+ xkeysym_unicode_map[0x01F5] = 0x0151;
+ xkeysym_unicode_map[0x01F8] = 0x0159;
+ xkeysym_unicode_map[0x01F9] = 0x016F;
+ xkeysym_unicode_map[0x01FB] = 0x0171;
+ xkeysym_unicode_map[0x01FE] = 0x0163;
+ xkeysym_unicode_map[0x01FF] = 0x02D9;
+ xkeysym_unicode_map[0x02A1] = 0x0126;
+ xkeysym_unicode_map[0x02A6] = 0x0124;
+ xkeysym_unicode_map[0x02A9] = 0x0130;
+ xkeysym_unicode_map[0x02AB] = 0x011E;
+ xkeysym_unicode_map[0x02AC] = 0x0134;
+ xkeysym_unicode_map[0x02B1] = 0x0127;
+ xkeysym_unicode_map[0x02B6] = 0x0125;
+ xkeysym_unicode_map[0x02B9] = 0x0131;
+ xkeysym_unicode_map[0x02BB] = 0x011F;
+ xkeysym_unicode_map[0x02BC] = 0x0135;
+ xkeysym_unicode_map[0x02C5] = 0x010A;
+ xkeysym_unicode_map[0x02C6] = 0x0108;
+ xkeysym_unicode_map[0x02D5] = 0x0120;
+ xkeysym_unicode_map[0x02D8] = 0x011C;
+ xkeysym_unicode_map[0x02DD] = 0x016C;
+ xkeysym_unicode_map[0x02DE] = 0x015C;
+ xkeysym_unicode_map[0x02E5] = 0x010B;
+ xkeysym_unicode_map[0x02E6] = 0x0109;
+ xkeysym_unicode_map[0x02F5] = 0x0121;
+ xkeysym_unicode_map[0x02F8] = 0x011D;
+ xkeysym_unicode_map[0x02FD] = 0x016D;
+ xkeysym_unicode_map[0x02FE] = 0x015D;
+ xkeysym_unicode_map[0x03A2] = 0x0138;
+ xkeysym_unicode_map[0x03A3] = 0x0156;
+ xkeysym_unicode_map[0x03A5] = 0x0128;
+ xkeysym_unicode_map[0x03A6] = 0x013B;
+ xkeysym_unicode_map[0x03AA] = 0x0112;
+ xkeysym_unicode_map[0x03AB] = 0x0122;
+ xkeysym_unicode_map[0x03AC] = 0x0166;
+ xkeysym_unicode_map[0x03B3] = 0x0157;
+ xkeysym_unicode_map[0x03B5] = 0x0129;
+ xkeysym_unicode_map[0x03B6] = 0x013C;
+ xkeysym_unicode_map[0x03BA] = 0x0113;
+ xkeysym_unicode_map[0x03BB] = 0x0123;
+ xkeysym_unicode_map[0x03BC] = 0x0167;
+ xkeysym_unicode_map[0x03BD] = 0x014A;
+ xkeysym_unicode_map[0x03BF] = 0x014B;
+ xkeysym_unicode_map[0x03C0] = 0x0100;
+ xkeysym_unicode_map[0x03C7] = 0x012E;
+ xkeysym_unicode_map[0x03CC] = 0x0116;
+ xkeysym_unicode_map[0x03CF] = 0x012A;
+ xkeysym_unicode_map[0x03D1] = 0x0145;
+ xkeysym_unicode_map[0x03D2] = 0x014C;
+ xkeysym_unicode_map[0x03D3] = 0x0136;
+ xkeysym_unicode_map[0x03D9] = 0x0172;
+ xkeysym_unicode_map[0x03DD] = 0x0168;
+ xkeysym_unicode_map[0x03DE] = 0x016A;
+ xkeysym_unicode_map[0x03E0] = 0x0101;
+ xkeysym_unicode_map[0x03E7] = 0x012F;
+ xkeysym_unicode_map[0x03EC] = 0x0117;
+ xkeysym_unicode_map[0x03EF] = 0x012B;
+ xkeysym_unicode_map[0x03F1] = 0x0146;
+ xkeysym_unicode_map[0x03F2] = 0x014D;
+ xkeysym_unicode_map[0x03F3] = 0x0137;
+ xkeysym_unicode_map[0x03F9] = 0x0173;
+ xkeysym_unicode_map[0x03FD] = 0x0169;
+ xkeysym_unicode_map[0x03FE] = 0x016B;
+ xkeysym_unicode_map[0x047E] = 0x203E;
+ xkeysym_unicode_map[0x04A1] = 0x3002;
+ xkeysym_unicode_map[0x04A2] = 0x300C;
+ xkeysym_unicode_map[0x04A3] = 0x300D;
+ xkeysym_unicode_map[0x04A4] = 0x3001;
+ xkeysym_unicode_map[0x04A5] = 0x30FB;
+ xkeysym_unicode_map[0x04A6] = 0x30F2;
+ xkeysym_unicode_map[0x04A7] = 0x30A1;
+ xkeysym_unicode_map[0x04A8] = 0x30A3;
+ xkeysym_unicode_map[0x04A9] = 0x30A5;
+ xkeysym_unicode_map[0x04AA] = 0x30A7;
+ xkeysym_unicode_map[0x04AB] = 0x30A9;
+ xkeysym_unicode_map[0x04AC] = 0x30E3;
+ xkeysym_unicode_map[0x04AD] = 0x30E5;
+ xkeysym_unicode_map[0x04AE] = 0x30E7;
+ xkeysym_unicode_map[0x04AF] = 0x30C3;
+ xkeysym_unicode_map[0x04B0] = 0x30FC;
+ xkeysym_unicode_map[0x04B1] = 0x30A2;
+ xkeysym_unicode_map[0x04B2] = 0x30A4;
+ xkeysym_unicode_map[0x04B3] = 0x30A6;
+ xkeysym_unicode_map[0x04B4] = 0x30A8;
+ xkeysym_unicode_map[0x04B5] = 0x30AA;
+ xkeysym_unicode_map[0x04B6] = 0x30AB;
+ xkeysym_unicode_map[0x04B7] = 0x30AD;
+ xkeysym_unicode_map[0x04B8] = 0x30AF;
+ xkeysym_unicode_map[0x04B9] = 0x30B1;
+ xkeysym_unicode_map[0x04BA] = 0x30B3;
+ xkeysym_unicode_map[0x04BB] = 0x30B5;
+ xkeysym_unicode_map[0x04BC] = 0x30B7;
+ xkeysym_unicode_map[0x04BD] = 0x30B9;
+ xkeysym_unicode_map[0x04BE] = 0x30BB;
+ xkeysym_unicode_map[0x04BF] = 0x30BD;
+ xkeysym_unicode_map[0x04C0] = 0x30BF;
+ xkeysym_unicode_map[0x04C1] = 0x30C1;
+ xkeysym_unicode_map[0x04C2] = 0x30C4;
+ xkeysym_unicode_map[0x04C3] = 0x30C6;
+ xkeysym_unicode_map[0x04C4] = 0x30C8;
+ xkeysym_unicode_map[0x04C5] = 0x30CA;
+ xkeysym_unicode_map[0x04C6] = 0x30CB;
+ xkeysym_unicode_map[0x04C7] = 0x30CC;
+ xkeysym_unicode_map[0x04C8] = 0x30CD;
+ xkeysym_unicode_map[0x04C9] = 0x30CE;
+ xkeysym_unicode_map[0x04CA] = 0x30CF;
+ xkeysym_unicode_map[0x04CB] = 0x30D2;
+ xkeysym_unicode_map[0x04CC] = 0x30D5;
+ xkeysym_unicode_map[0x04CD] = 0x30D8;
+ xkeysym_unicode_map[0x04CE] = 0x30DB;
+ xkeysym_unicode_map[0x04CF] = 0x30DE;
+ xkeysym_unicode_map[0x04D0] = 0x30DF;
+ xkeysym_unicode_map[0x04D1] = 0x30E0;
+ xkeysym_unicode_map[0x04D2] = 0x30E1;
+ xkeysym_unicode_map[0x04D3] = 0x30E2;
+ xkeysym_unicode_map[0x04D4] = 0x30E4;
+ xkeysym_unicode_map[0x04D5] = 0x30E6;
+ xkeysym_unicode_map[0x04D6] = 0x30E8;
+ xkeysym_unicode_map[0x04D7] = 0x30E9;
+ xkeysym_unicode_map[0x04D8] = 0x30EA;
+ xkeysym_unicode_map[0x04D9] = 0x30EB;
+ xkeysym_unicode_map[0x04DA] = 0x30EC;
+ xkeysym_unicode_map[0x04DB] = 0x30ED;
+ xkeysym_unicode_map[0x04DC] = 0x30EF;
+ xkeysym_unicode_map[0x04DD] = 0x30F3;
+ xkeysym_unicode_map[0x04DE] = 0x309B;
+ xkeysym_unicode_map[0x04DF] = 0x309C;
+ xkeysym_unicode_map[0x05AC] = 0x060C;
+ xkeysym_unicode_map[0x05BB] = 0x061B;
+ xkeysym_unicode_map[0x05BF] = 0x061F;
+ xkeysym_unicode_map[0x05C1] = 0x0621;
+ xkeysym_unicode_map[0x05C2] = 0x0622;
+ xkeysym_unicode_map[0x05C3] = 0x0623;
+ xkeysym_unicode_map[0x05C4] = 0x0624;
+ xkeysym_unicode_map[0x05C5] = 0x0625;
+ xkeysym_unicode_map[0x05C6] = 0x0626;
+ xkeysym_unicode_map[0x05C7] = 0x0627;
+ xkeysym_unicode_map[0x05C8] = 0x0628;
+ xkeysym_unicode_map[0x05C9] = 0x0629;
+ xkeysym_unicode_map[0x05CA] = 0x062A;
+ xkeysym_unicode_map[0x05CB] = 0x062B;
+ xkeysym_unicode_map[0x05CC] = 0x062C;
+ xkeysym_unicode_map[0x05CD] = 0x062D;
+ xkeysym_unicode_map[0x05CE] = 0x062E;
+ xkeysym_unicode_map[0x05CF] = 0x062F;
+ xkeysym_unicode_map[0x05D0] = 0x0630;
+ xkeysym_unicode_map[0x05D1] = 0x0631;
+ xkeysym_unicode_map[0x05D2] = 0x0632;
+ xkeysym_unicode_map[0x05D3] = 0x0633;
+ xkeysym_unicode_map[0x05D4] = 0x0634;
+ xkeysym_unicode_map[0x05D5] = 0x0635;
+ xkeysym_unicode_map[0x05D6] = 0x0636;
+ xkeysym_unicode_map[0x05D7] = 0x0637;
+ xkeysym_unicode_map[0x05D8] = 0x0638;
+ xkeysym_unicode_map[0x05D9] = 0x0639;
+ xkeysym_unicode_map[0x05DA] = 0x063A;
+ xkeysym_unicode_map[0x05E0] = 0x0640;
+ xkeysym_unicode_map[0x05E1] = 0x0641;
+ xkeysym_unicode_map[0x05E2] = 0x0642;
+ xkeysym_unicode_map[0x05E3] = 0x0643;
+ xkeysym_unicode_map[0x05E4] = 0x0644;
+ xkeysym_unicode_map[0x05E5] = 0x0645;
+ xkeysym_unicode_map[0x05E6] = 0x0646;
+ xkeysym_unicode_map[0x05E7] = 0x0647;
+ xkeysym_unicode_map[0x05E8] = 0x0648;
+ xkeysym_unicode_map[0x05E9] = 0x0649;
+ xkeysym_unicode_map[0x05EA] = 0x064A;
+ xkeysym_unicode_map[0x05EB] = 0x064B;
+ xkeysym_unicode_map[0x05EC] = 0x064C;
+ xkeysym_unicode_map[0x05ED] = 0x064D;
+ xkeysym_unicode_map[0x05EE] = 0x064E;
+ xkeysym_unicode_map[0x05EF] = 0x064F;
+ xkeysym_unicode_map[0x05F0] = 0x0650;
+ xkeysym_unicode_map[0x05F1] = 0x0651;
+ xkeysym_unicode_map[0x05F2] = 0x0652;
+ xkeysym_unicode_map[0x06A1] = 0x0452;
+ xkeysym_unicode_map[0x06A2] = 0x0453;
+ xkeysym_unicode_map[0x06A3] = 0x0451;
+ xkeysym_unicode_map[0x06A4] = 0x0454;
+ xkeysym_unicode_map[0x06A5] = 0x0455;
+ xkeysym_unicode_map[0x06A6] = 0x0456;
+ xkeysym_unicode_map[0x06A7] = 0x0457;
+ xkeysym_unicode_map[0x06A8] = 0x0458;
+ xkeysym_unicode_map[0x06A9] = 0x0459;
+ xkeysym_unicode_map[0x06AA] = 0x045A;
+ xkeysym_unicode_map[0x06AB] = 0x045B;
+ xkeysym_unicode_map[0x06AC] = 0x045C;
+ xkeysym_unicode_map[0x06AE] = 0x045E;
+ xkeysym_unicode_map[0x06AF] = 0x045F;
+ xkeysym_unicode_map[0x06B0] = 0x2116;
+ xkeysym_unicode_map[0x06B1] = 0x0402;
+ xkeysym_unicode_map[0x06B2] = 0x0403;
+ xkeysym_unicode_map[0x06B3] = 0x0401;
+ xkeysym_unicode_map[0x06B4] = 0x0404;
+ xkeysym_unicode_map[0x06B5] = 0x0405;
+ xkeysym_unicode_map[0x06B6] = 0x0406;
+ xkeysym_unicode_map[0x06B7] = 0x0407;
+ xkeysym_unicode_map[0x06B8] = 0x0408;
+ xkeysym_unicode_map[0x06B9] = 0x0409;
+ xkeysym_unicode_map[0x06BA] = 0x040A;
+ xkeysym_unicode_map[0x06BB] = 0x040B;
+ xkeysym_unicode_map[0x06BC] = 0x040C;
+ xkeysym_unicode_map[0x06BE] = 0x040E;
+ xkeysym_unicode_map[0x06BF] = 0x040F;
+ xkeysym_unicode_map[0x06C0] = 0x044E;
+ xkeysym_unicode_map[0x06C1] = 0x0430;
+ xkeysym_unicode_map[0x06C2] = 0x0431;
+ xkeysym_unicode_map[0x06C3] = 0x0446;
+ xkeysym_unicode_map[0x06C4] = 0x0434;
+ xkeysym_unicode_map[0x06C5] = 0x0435;
+ xkeysym_unicode_map[0x06C6] = 0x0444;
+ xkeysym_unicode_map[0x06C7] = 0x0433;
+ xkeysym_unicode_map[0x06C8] = 0x0445;
+ xkeysym_unicode_map[0x06C9] = 0x0438;
+ xkeysym_unicode_map[0x06CA] = 0x0439;
+ xkeysym_unicode_map[0x06CB] = 0x043A;
+ xkeysym_unicode_map[0x06CC] = 0x043B;
+ xkeysym_unicode_map[0x06CD] = 0x043C;
+ xkeysym_unicode_map[0x06CE] = 0x043D;
+ xkeysym_unicode_map[0x06CF] = 0x043E;
+ xkeysym_unicode_map[0x06D0] = 0x043F;
+ xkeysym_unicode_map[0x06D1] = 0x044F;
+ xkeysym_unicode_map[0x06D2] = 0x0440;
+ xkeysym_unicode_map[0x06D3] = 0x0441;
+ xkeysym_unicode_map[0x06D4] = 0x0442;
+ xkeysym_unicode_map[0x06D5] = 0x0443;
+ xkeysym_unicode_map[0x06D6] = 0x0436;
+ xkeysym_unicode_map[0x06D7] = 0x0432;
+ xkeysym_unicode_map[0x06D8] = 0x044C;
+ xkeysym_unicode_map[0x06D9] = 0x044B;
+ xkeysym_unicode_map[0x06DA] = 0x0437;
+ xkeysym_unicode_map[0x06DB] = 0x0448;
+ xkeysym_unicode_map[0x06DC] = 0x044D;
+ xkeysym_unicode_map[0x06DD] = 0x0449;
+ xkeysym_unicode_map[0x06DE] = 0x0447;
+ xkeysym_unicode_map[0x06DF] = 0x044A;
+ xkeysym_unicode_map[0x06E0] = 0x042E;
+ xkeysym_unicode_map[0x06E1] = 0x0410;
+ xkeysym_unicode_map[0x06E2] = 0x0411;
+ xkeysym_unicode_map[0x06E3] = 0x0426;
+ xkeysym_unicode_map[0x06E4] = 0x0414;
+ xkeysym_unicode_map[0x06E5] = 0x0415;
+ xkeysym_unicode_map[0x06E6] = 0x0424;
+ xkeysym_unicode_map[0x06E7] = 0x0413;
+ xkeysym_unicode_map[0x06E8] = 0x0425;
+ xkeysym_unicode_map[0x06E9] = 0x0418;
+ xkeysym_unicode_map[0x06EA] = 0x0419;
+ xkeysym_unicode_map[0x06EB] = 0x041A;
+ xkeysym_unicode_map[0x06EC] = 0x041B;
+ xkeysym_unicode_map[0x06ED] = 0x041C;
+ xkeysym_unicode_map[0x06EE] = 0x041D;
+ xkeysym_unicode_map[0x06EF] = 0x041E;
+ xkeysym_unicode_map[0x06F0] = 0x041F;
+ xkeysym_unicode_map[0x06F1] = 0x042F;
+ xkeysym_unicode_map[0x06F2] = 0x0420;
+ xkeysym_unicode_map[0x06F3] = 0x0421;
+ xkeysym_unicode_map[0x06F4] = 0x0422;
+ xkeysym_unicode_map[0x06F5] = 0x0423;
+ xkeysym_unicode_map[0x06F6] = 0x0416;
+ xkeysym_unicode_map[0x06F7] = 0x0412;
+ xkeysym_unicode_map[0x06F8] = 0x042C;
+ xkeysym_unicode_map[0x06F9] = 0x042B;
+ xkeysym_unicode_map[0x06FA] = 0x0417;
+ xkeysym_unicode_map[0x06FB] = 0x0428;
+ xkeysym_unicode_map[0x06FC] = 0x042D;
+ xkeysym_unicode_map[0x06FD] = 0x0429;
+ xkeysym_unicode_map[0x06FE] = 0x0427;
+ xkeysym_unicode_map[0x06FF] = 0x042A;
+ xkeysym_unicode_map[0x07A1] = 0x0386;
+ xkeysym_unicode_map[0x07A2] = 0x0388;
+ xkeysym_unicode_map[0x07A3] = 0x0389;
+ xkeysym_unicode_map[0x07A4] = 0x038A;
+ xkeysym_unicode_map[0x07A5] = 0x03AA;
+ xkeysym_unicode_map[0x07A7] = 0x038C;
+ xkeysym_unicode_map[0x07A8] = 0x038E;
+ xkeysym_unicode_map[0x07A9] = 0x03AB;
+ xkeysym_unicode_map[0x07AB] = 0x038F;
+ xkeysym_unicode_map[0x07AE] = 0x0385;
+ xkeysym_unicode_map[0x07AF] = 0x2015;
+ xkeysym_unicode_map[0x07B1] = 0x03AC;
+ xkeysym_unicode_map[0x07B2] = 0x03AD;
+ xkeysym_unicode_map[0x07B3] = 0x03AE;
+ xkeysym_unicode_map[0x07B4] = 0x03AF;
+ xkeysym_unicode_map[0x07B5] = 0x03CA;
+ xkeysym_unicode_map[0x07B6] = 0x0390;
+ xkeysym_unicode_map[0x07B7] = 0x03CC;
+ xkeysym_unicode_map[0x07B8] = 0x03CD;
+ xkeysym_unicode_map[0x07B9] = 0x03CB;
+ xkeysym_unicode_map[0x07BA] = 0x03B0;
+ xkeysym_unicode_map[0x07BB] = 0x03CE;
+ xkeysym_unicode_map[0x07C1] = 0x0391;
+ xkeysym_unicode_map[0x07C2] = 0x0392;
+ xkeysym_unicode_map[0x07C3] = 0x0393;
+ xkeysym_unicode_map[0x07C4] = 0x0394;
+ xkeysym_unicode_map[0x07C5] = 0x0395;
+ xkeysym_unicode_map[0x07C6] = 0x0396;
+ xkeysym_unicode_map[0x07C7] = 0x0397;
+ xkeysym_unicode_map[0x07C8] = 0x0398;
+ xkeysym_unicode_map[0x07C9] = 0x0399;
+ xkeysym_unicode_map[0x07CA] = 0x039A;
+ xkeysym_unicode_map[0x07CB] = 0x039B;
+ xkeysym_unicode_map[0x07CC] = 0x039C;
+ xkeysym_unicode_map[0x07CD] = 0x039D;
+ xkeysym_unicode_map[0x07CE] = 0x039E;
+ xkeysym_unicode_map[0x07CF] = 0x039F;
+ xkeysym_unicode_map[0x07D0] = 0x03A0;
+ xkeysym_unicode_map[0x07D1] = 0x03A1;
+ xkeysym_unicode_map[0x07D2] = 0x03A3;
+ xkeysym_unicode_map[0x07D4] = 0x03A4;
+ xkeysym_unicode_map[0x07D5] = 0x03A5;
+ xkeysym_unicode_map[0x07D6] = 0x03A6;
+ xkeysym_unicode_map[0x07D7] = 0x03A7;
+ xkeysym_unicode_map[0x07D8] = 0x03A8;
+ xkeysym_unicode_map[0x07D9] = 0x03A9;
+ xkeysym_unicode_map[0x07E1] = 0x03B1;
+ xkeysym_unicode_map[0x07E2] = 0x03B2;
+ xkeysym_unicode_map[0x07E3] = 0x03B3;
+ xkeysym_unicode_map[0x07E4] = 0x03B4;
+ xkeysym_unicode_map[0x07E5] = 0x03B5;
+ xkeysym_unicode_map[0x07E6] = 0x03B6;
+ xkeysym_unicode_map[0x07E7] = 0x03B7;
+ xkeysym_unicode_map[0x07E8] = 0x03B8;
+ xkeysym_unicode_map[0x07E9] = 0x03B9;
+ xkeysym_unicode_map[0x07EA] = 0x03BA;
+ xkeysym_unicode_map[0x07EB] = 0x03BB;
+ xkeysym_unicode_map[0x07EC] = 0x03BC;
+ xkeysym_unicode_map[0x07ED] = 0x03BD;
+ xkeysym_unicode_map[0x07EE] = 0x03BE;
+ xkeysym_unicode_map[0x07EF] = 0x03BF;
+ xkeysym_unicode_map[0x07F0] = 0x03C0;
+ xkeysym_unicode_map[0x07F1] = 0x03C1;
+ xkeysym_unicode_map[0x07F2] = 0x03C3;
+ xkeysym_unicode_map[0x07F3] = 0x03C2;
+ xkeysym_unicode_map[0x07F4] = 0x03C4;
+ xkeysym_unicode_map[0x07F5] = 0x03C5;
+ xkeysym_unicode_map[0x07F6] = 0x03C6;
+ xkeysym_unicode_map[0x07F7] = 0x03C7;
+ xkeysym_unicode_map[0x07F8] = 0x03C8;
+ xkeysym_unicode_map[0x07F9] = 0x03C9;
+ xkeysym_unicode_map[0x08A1] = 0x23B7;
+ xkeysym_unicode_map[0x08A2] = 0x250C;
+ xkeysym_unicode_map[0x08A3] = 0x2500;
+ xkeysym_unicode_map[0x08A4] = 0x2320;
+ xkeysym_unicode_map[0x08A5] = 0x2321;
+ xkeysym_unicode_map[0x08A6] = 0x2502;
+ xkeysym_unicode_map[0x08A7] = 0x23A1;
+ xkeysym_unicode_map[0x08A8] = 0x23A3;
+ xkeysym_unicode_map[0x08A9] = 0x23A4;
+ xkeysym_unicode_map[0x08AA] = 0x23A6;
+ xkeysym_unicode_map[0x08AB] = 0x239B;
+ xkeysym_unicode_map[0x08AC] = 0x239D;
+ xkeysym_unicode_map[0x08AD] = 0x239E;
+ xkeysym_unicode_map[0x08AE] = 0x23A0;
+ xkeysym_unicode_map[0x08AF] = 0x23A8;
+ xkeysym_unicode_map[0x08B0] = 0x23AC;
+ xkeysym_unicode_map[0x08BC] = 0x2264;
+ xkeysym_unicode_map[0x08BD] = 0x2260;
+ xkeysym_unicode_map[0x08BE] = 0x2265;
+ xkeysym_unicode_map[0x08BF] = 0x222B;
+ xkeysym_unicode_map[0x08C0] = 0x2234;
+ xkeysym_unicode_map[0x08C1] = 0x221D;
+ xkeysym_unicode_map[0x08C2] = 0x221E;
+ xkeysym_unicode_map[0x08C5] = 0x2207;
+ xkeysym_unicode_map[0x08C8] = 0x223C;
+ xkeysym_unicode_map[0x08C9] = 0x2243;
+ xkeysym_unicode_map[0x08CD] = 0x21D4;
+ xkeysym_unicode_map[0x08CE] = 0x21D2;
+ xkeysym_unicode_map[0x08CF] = 0x2261;
+ xkeysym_unicode_map[0x08D6] = 0x221A;
+ xkeysym_unicode_map[0x08DA] = 0x2282;
+ xkeysym_unicode_map[0x08DB] = 0x2283;
+ xkeysym_unicode_map[0x08DC] = 0x2229;
+ xkeysym_unicode_map[0x08DD] = 0x222A;
+ xkeysym_unicode_map[0x08DE] = 0x2227;
+ xkeysym_unicode_map[0x08DF] = 0x2228;
+ xkeysym_unicode_map[0x08EF] = 0x2202;
+ xkeysym_unicode_map[0x08F6] = 0x0192;
+ xkeysym_unicode_map[0x08FB] = 0x2190;
+ xkeysym_unicode_map[0x08FC] = 0x2191;
+ xkeysym_unicode_map[0x08FD] = 0x2192;
+ xkeysym_unicode_map[0x08FE] = 0x2193;
+ xkeysym_unicode_map[0x09E0] = 0x25C6;
+ xkeysym_unicode_map[0x09E1] = 0x2592;
+ xkeysym_unicode_map[0x09E2] = 0x2409;
+ xkeysym_unicode_map[0x09E3] = 0x240C;
+ xkeysym_unicode_map[0x09E4] = 0x240D;
+ xkeysym_unicode_map[0x09E5] = 0x240A;
+ xkeysym_unicode_map[0x09E8] = 0x2424;
+ xkeysym_unicode_map[0x09E9] = 0x240B;
+ xkeysym_unicode_map[0x09EA] = 0x2518;
+ xkeysym_unicode_map[0x09EB] = 0x2510;
+ xkeysym_unicode_map[0x09EC] = 0x250C;
+ xkeysym_unicode_map[0x09ED] = 0x2514;
+ xkeysym_unicode_map[0x09EE] = 0x253C;
+ xkeysym_unicode_map[0x09EF] = 0x23BA;
+ xkeysym_unicode_map[0x09F0] = 0x23BB;
+ xkeysym_unicode_map[0x09F1] = 0x2500;
+ xkeysym_unicode_map[0x09F2] = 0x23BC;
+ xkeysym_unicode_map[0x09F3] = 0x23BD;
+ xkeysym_unicode_map[0x09F4] = 0x251C;
+ xkeysym_unicode_map[0x09F5] = 0x2524;
+ xkeysym_unicode_map[0x09F6] = 0x2534;
+ xkeysym_unicode_map[0x09F7] = 0x252C;
+ xkeysym_unicode_map[0x09F8] = 0x2502;
+ xkeysym_unicode_map[0x0AA1] = 0x2003;
+ xkeysym_unicode_map[0x0AA2] = 0x2002;
+ xkeysym_unicode_map[0x0AA3] = 0x2004;
+ xkeysym_unicode_map[0x0AA4] = 0x2005;
+ xkeysym_unicode_map[0x0AA5] = 0x2007;
+ xkeysym_unicode_map[0x0AA6] = 0x2008;
+ xkeysym_unicode_map[0x0AA7] = 0x2009;
+ xkeysym_unicode_map[0x0AA8] = 0x200A;
+ xkeysym_unicode_map[0x0AA9] = 0x2014;
+ xkeysym_unicode_map[0x0AAA] = 0x2013;
+ xkeysym_unicode_map[0x0AAE] = 0x2026;
+ xkeysym_unicode_map[0x0AAF] = 0x2025;
+ xkeysym_unicode_map[0x0AB0] = 0x2153;
+ xkeysym_unicode_map[0x0AB1] = 0x2154;
+ xkeysym_unicode_map[0x0AB2] = 0x2155;
+ xkeysym_unicode_map[0x0AB3] = 0x2156;
+ xkeysym_unicode_map[0x0AB4] = 0x2157;
+ xkeysym_unicode_map[0x0AB5] = 0x2158;
+ xkeysym_unicode_map[0x0AB6] = 0x2159;
+ xkeysym_unicode_map[0x0AB7] = 0x215A;
+ xkeysym_unicode_map[0x0AB8] = 0x2105;
+ xkeysym_unicode_map[0x0ABB] = 0x2012;
+ xkeysym_unicode_map[0x0ABC] = 0x2329;
+ xkeysym_unicode_map[0x0ABE] = 0x232A;
+ xkeysym_unicode_map[0x0AC3] = 0x215B;
+ xkeysym_unicode_map[0x0AC4] = 0x215C;
+ xkeysym_unicode_map[0x0AC5] = 0x215D;
+ xkeysym_unicode_map[0x0AC6] = 0x215E;
+ xkeysym_unicode_map[0x0AC9] = 0x2122;
+ xkeysym_unicode_map[0x0ACA] = 0x2613;
+ xkeysym_unicode_map[0x0ACC] = 0x25C1;
+ xkeysym_unicode_map[0x0ACD] = 0x25B7;
+ xkeysym_unicode_map[0x0ACE] = 0x25CB;
+ xkeysym_unicode_map[0x0ACF] = 0x25AF;
+ xkeysym_unicode_map[0x0AD0] = 0x2018;
+ xkeysym_unicode_map[0x0AD1] = 0x2019;
+ xkeysym_unicode_map[0x0AD2] = 0x201C;
+ xkeysym_unicode_map[0x0AD3] = 0x201D;
+ xkeysym_unicode_map[0x0AD4] = 0x211E;
+ xkeysym_unicode_map[0x0AD6] = 0x2032;
+ xkeysym_unicode_map[0x0AD7] = 0x2033;
+ xkeysym_unicode_map[0x0AD9] = 0x271D;
+ xkeysym_unicode_map[0x0ADB] = 0x25AC;
+ xkeysym_unicode_map[0x0ADC] = 0x25C0;
+ xkeysym_unicode_map[0x0ADD] = 0x25B6;
+ xkeysym_unicode_map[0x0ADE] = 0x25CF;
+ xkeysym_unicode_map[0x0ADF] = 0x25AE;
+ xkeysym_unicode_map[0x0AE0] = 0x25E6;
+ xkeysym_unicode_map[0x0AE1] = 0x25AB;
+ xkeysym_unicode_map[0x0AE2] = 0x25AD;
+ xkeysym_unicode_map[0x0AE3] = 0x25B3;
+ xkeysym_unicode_map[0x0AE4] = 0x25BD;
+ xkeysym_unicode_map[0x0AE5] = 0x2606;
+ xkeysym_unicode_map[0x0AE6] = 0x2022;
+ xkeysym_unicode_map[0x0AE7] = 0x25AA;
+ xkeysym_unicode_map[0x0AE8] = 0x25B2;
+ xkeysym_unicode_map[0x0AE9] = 0x25BC;
+ xkeysym_unicode_map[0x0AEA] = 0x261C;
+ xkeysym_unicode_map[0x0AEB] = 0x261E;
+ xkeysym_unicode_map[0x0AEC] = 0x2663;
+ xkeysym_unicode_map[0x0AED] = 0x2666;
+ xkeysym_unicode_map[0x0AEE] = 0x2665;
+ xkeysym_unicode_map[0x0AF0] = 0x2720;
+ xkeysym_unicode_map[0x0AF1] = 0x2020;
+ xkeysym_unicode_map[0x0AF2] = 0x2021;
+ xkeysym_unicode_map[0x0AF3] = 0x2713;
+ xkeysym_unicode_map[0x0AF4] = 0x2717;
+ xkeysym_unicode_map[0x0AF5] = 0x266F;
+ xkeysym_unicode_map[0x0AF6] = 0x266D;
+ xkeysym_unicode_map[0x0AF7] = 0x2642;
+ xkeysym_unicode_map[0x0AF8] = 0x2640;
+ xkeysym_unicode_map[0x0AF9] = 0x260E;
+ xkeysym_unicode_map[0x0AFA] = 0x2315;
+ xkeysym_unicode_map[0x0AFB] = 0x2117;
+ xkeysym_unicode_map[0x0AFC] = 0x2038;
+ xkeysym_unicode_map[0x0AFD] = 0x201A;
+ xkeysym_unicode_map[0x0AFE] = 0x201E;
+ xkeysym_unicode_map[0x0BA3] = 0x003C;
+ xkeysym_unicode_map[0x0BA6] = 0x003E;
+ xkeysym_unicode_map[0x0BA8] = 0x2228;
+ xkeysym_unicode_map[0x0BA9] = 0x2227;
+ xkeysym_unicode_map[0x0BC0] = 0x00AF;
+ xkeysym_unicode_map[0x0BC2] = 0x22A5;
+ xkeysym_unicode_map[0x0BC3] = 0x2229;
+ xkeysym_unicode_map[0x0BC4] = 0x230A;
+ xkeysym_unicode_map[0x0BC6] = 0x005F;
+ xkeysym_unicode_map[0x0BCA] = 0x2218;
+ xkeysym_unicode_map[0x0BCC] = 0x2395;
+ xkeysym_unicode_map[0x0BCE] = 0x22A4;
+ xkeysym_unicode_map[0x0BCF] = 0x25CB;
+ xkeysym_unicode_map[0x0BD3] = 0x2308;
+ xkeysym_unicode_map[0x0BD6] = 0x222A;
+ xkeysym_unicode_map[0x0BD8] = 0x2283;
+ xkeysym_unicode_map[0x0BDA] = 0x2282;
+ xkeysym_unicode_map[0x0BDC] = 0x22A2;
+ xkeysym_unicode_map[0x0BFC] = 0x22A3;
+ xkeysym_unicode_map[0x0CDF] = 0x2017;
+ xkeysym_unicode_map[0x0CE0] = 0x05D0;
+ xkeysym_unicode_map[0x0CE1] = 0x05D1;
+ xkeysym_unicode_map[0x0CE2] = 0x05D2;
+ xkeysym_unicode_map[0x0CE3] = 0x05D3;
+ xkeysym_unicode_map[0x0CE4] = 0x05D4;
+ xkeysym_unicode_map[0x0CE5] = 0x05D5;
+ xkeysym_unicode_map[0x0CE6] = 0x05D6;
+ xkeysym_unicode_map[0x0CE7] = 0x05D7;
+ xkeysym_unicode_map[0x0CE8] = 0x05D8;
+ xkeysym_unicode_map[0x0CE9] = 0x05D9;
+ xkeysym_unicode_map[0x0CEA] = 0x05DA;
+ xkeysym_unicode_map[0x0CEB] = 0x05DB;
+ xkeysym_unicode_map[0x0CEC] = 0x05DC;
+ xkeysym_unicode_map[0x0CED] = 0x05DD;
+ xkeysym_unicode_map[0x0CEE] = 0x05DE;
+ xkeysym_unicode_map[0x0CEF] = 0x05DF;
+ xkeysym_unicode_map[0x0CF0] = 0x05E0;
+ xkeysym_unicode_map[0x0CF1] = 0x05E1;
+ xkeysym_unicode_map[0x0CF2] = 0x05E2;
+ xkeysym_unicode_map[0x0CF3] = 0x05E3;
+ xkeysym_unicode_map[0x0CF4] = 0x05E4;
+ xkeysym_unicode_map[0x0CF5] = 0x05E5;
+ xkeysym_unicode_map[0x0CF6] = 0x05E6;
+ xkeysym_unicode_map[0x0CF7] = 0x05E7;
+ xkeysym_unicode_map[0x0CF8] = 0x05E8;
+ xkeysym_unicode_map[0x0CF9] = 0x05E9;
+ xkeysym_unicode_map[0x0CFA] = 0x05EA;
+ xkeysym_unicode_map[0x0DA1] = 0x0E01;
+ xkeysym_unicode_map[0x0DA2] = 0x0E02;
+ xkeysym_unicode_map[0x0DA3] = 0x0E03;
+ xkeysym_unicode_map[0x0DA4] = 0x0E04;
+ xkeysym_unicode_map[0x0DA5] = 0x0E05;
+ xkeysym_unicode_map[0x0DA6] = 0x0E06;
+ xkeysym_unicode_map[0x0DA7] = 0x0E07;
+ xkeysym_unicode_map[0x0DA8] = 0x0E08;
+ xkeysym_unicode_map[0x0DA9] = 0x0E09;
+ xkeysym_unicode_map[0x0DAA] = 0x0E0A;
+ xkeysym_unicode_map[0x0DAB] = 0x0E0B;
+ xkeysym_unicode_map[0x0DAC] = 0x0E0C;
+ xkeysym_unicode_map[0x0DAD] = 0x0E0D;
+ xkeysym_unicode_map[0x0DAE] = 0x0E0E;
+ xkeysym_unicode_map[0x0DAF] = 0x0E0F;
+ xkeysym_unicode_map[0x0DB0] = 0x0E10;
+ xkeysym_unicode_map[0x0DB1] = 0x0E11;
+ xkeysym_unicode_map[0x0DB2] = 0x0E12;
+ xkeysym_unicode_map[0x0DB3] = 0x0E13;
+ xkeysym_unicode_map[0x0DB4] = 0x0E14;
+ xkeysym_unicode_map[0x0DB5] = 0x0E15;
+ xkeysym_unicode_map[0x0DB6] = 0x0E16;
+ xkeysym_unicode_map[0x0DB7] = 0x0E17;
+ xkeysym_unicode_map[0x0DB8] = 0x0E18;
+ xkeysym_unicode_map[0x0DB9] = 0x0E19;
+ xkeysym_unicode_map[0x0DBA] = 0x0E1A;
+ xkeysym_unicode_map[0x0DBB] = 0x0E1B;
+ xkeysym_unicode_map[0x0DBC] = 0x0E1C;
+ xkeysym_unicode_map[0x0DBD] = 0x0E1D;
+ xkeysym_unicode_map[0x0DBE] = 0x0E1E;
+ xkeysym_unicode_map[0x0DBF] = 0x0E1F;
+ xkeysym_unicode_map[0x0DC0] = 0x0E20;
+ xkeysym_unicode_map[0x0DC1] = 0x0E21;
+ xkeysym_unicode_map[0x0DC2] = 0x0E22;
+ xkeysym_unicode_map[0x0DC3] = 0x0E23;
+ xkeysym_unicode_map[0x0DC4] = 0x0E24;
+ xkeysym_unicode_map[0x0DC5] = 0x0E25;
+ xkeysym_unicode_map[0x0DC6] = 0x0E26;
+ xkeysym_unicode_map[0x0DC7] = 0x0E27;
+ xkeysym_unicode_map[0x0DC8] = 0x0E28;
+ xkeysym_unicode_map[0x0DC9] = 0x0E29;
+ xkeysym_unicode_map[0x0DCA] = 0x0E2A;
+ xkeysym_unicode_map[0x0DCB] = 0x0E2B;
+ xkeysym_unicode_map[0x0DCC] = 0x0E2C;
+ xkeysym_unicode_map[0x0DCD] = 0x0E2D;
+ xkeysym_unicode_map[0x0DCE] = 0x0E2E;
+ xkeysym_unicode_map[0x0DCF] = 0x0E2F;
+ xkeysym_unicode_map[0x0DD0] = 0x0E30;
+ xkeysym_unicode_map[0x0DD1] = 0x0E31;
+ xkeysym_unicode_map[0x0DD2] = 0x0E32;
+ xkeysym_unicode_map[0x0DD3] = 0x0E33;
+ xkeysym_unicode_map[0x0DD4] = 0x0E34;
+ xkeysym_unicode_map[0x0DD5] = 0x0E35;
+ xkeysym_unicode_map[0x0DD6] = 0x0E36;
+ xkeysym_unicode_map[0x0DD7] = 0x0E37;
+ xkeysym_unicode_map[0x0DD8] = 0x0E38;
+ xkeysym_unicode_map[0x0DD9] = 0x0E39;
+ xkeysym_unicode_map[0x0DDA] = 0x0E3A;
+ xkeysym_unicode_map[0x0DDF] = 0x0E3F;
+ xkeysym_unicode_map[0x0DE0] = 0x0E40;
+ xkeysym_unicode_map[0x0DE1] = 0x0E41;
+ xkeysym_unicode_map[0x0DE2] = 0x0E42;
+ xkeysym_unicode_map[0x0DE3] = 0x0E43;
+ xkeysym_unicode_map[0x0DE4] = 0x0E44;
+ xkeysym_unicode_map[0x0DE5] = 0x0E45;
+ xkeysym_unicode_map[0x0DE6] = 0x0E46;
+ xkeysym_unicode_map[0x0DE7] = 0x0E47;
+ xkeysym_unicode_map[0x0DE8] = 0x0E48;
+ xkeysym_unicode_map[0x0DE9] = 0x0E49;
+ xkeysym_unicode_map[0x0DEA] = 0x0E4A;
+ xkeysym_unicode_map[0x0DEB] = 0x0E4B;
+ xkeysym_unicode_map[0x0DEC] = 0x0E4C;
+ xkeysym_unicode_map[0x0DED] = 0x0E4D;
+ xkeysym_unicode_map[0x0DF0] = 0x0E50;
+ xkeysym_unicode_map[0x0DF1] = 0x0E51;
+ xkeysym_unicode_map[0x0DF2] = 0x0E52;
+ xkeysym_unicode_map[0x0DF3] = 0x0E53;
+ xkeysym_unicode_map[0x0DF4] = 0x0E54;
+ xkeysym_unicode_map[0x0DF5] = 0x0E55;
+ xkeysym_unicode_map[0x0DF6] = 0x0E56;
+ xkeysym_unicode_map[0x0DF7] = 0x0E57;
+ xkeysym_unicode_map[0x0DF8] = 0x0E58;
+ xkeysym_unicode_map[0x0DF9] = 0x0E59;
+ xkeysym_unicode_map[0x0EA1] = 0x3131;
+ xkeysym_unicode_map[0x0EA2] = 0x3132;
+ xkeysym_unicode_map[0x0EA3] = 0x3133;
+ xkeysym_unicode_map[0x0EA4] = 0x3134;
+ xkeysym_unicode_map[0x0EA5] = 0x3135;
+ xkeysym_unicode_map[0x0EA6] = 0x3136;
+ xkeysym_unicode_map[0x0EA7] = 0x3137;
+ xkeysym_unicode_map[0x0EA8] = 0x3138;
+ xkeysym_unicode_map[0x0EA9] = 0x3139;
+ xkeysym_unicode_map[0x0EAA] = 0x313A;
+ xkeysym_unicode_map[0x0EAB] = 0x313B;
+ xkeysym_unicode_map[0x0EAC] = 0x313C;
+ xkeysym_unicode_map[0x0EAD] = 0x313D;
+ xkeysym_unicode_map[0x0EAE] = 0x313E;
+ xkeysym_unicode_map[0x0EAF] = 0x313F;
+ xkeysym_unicode_map[0x0EB0] = 0x3140;
+ xkeysym_unicode_map[0x0EB1] = 0x3141;
+ xkeysym_unicode_map[0x0EB2] = 0x3142;
+ xkeysym_unicode_map[0x0EB3] = 0x3143;
+ xkeysym_unicode_map[0x0EB4] = 0x3144;
+ xkeysym_unicode_map[0x0EB5] = 0x3145;
+ xkeysym_unicode_map[0x0EB6] = 0x3146;
+ xkeysym_unicode_map[0x0EB7] = 0x3147;
+ xkeysym_unicode_map[0x0EB8] = 0x3148;
+ xkeysym_unicode_map[0x0EB9] = 0x3149;
+ xkeysym_unicode_map[0x0EBA] = 0x314A;
+ xkeysym_unicode_map[0x0EBB] = 0x314B;
+ xkeysym_unicode_map[0x0EBC] = 0x314C;
+ xkeysym_unicode_map[0x0EBD] = 0x314D;
+ xkeysym_unicode_map[0x0EBE] = 0x314E;
+ xkeysym_unicode_map[0x0EBF] = 0x314F;
+ xkeysym_unicode_map[0x0EC0] = 0x3150;
+ xkeysym_unicode_map[0x0EC1] = 0x3151;
+ xkeysym_unicode_map[0x0EC2] = 0x3152;
+ xkeysym_unicode_map[0x0EC3] = 0x3153;
+ xkeysym_unicode_map[0x0EC4] = 0x3154;
+ xkeysym_unicode_map[0x0EC5] = 0x3155;
+ xkeysym_unicode_map[0x0EC6] = 0x3156;
+ xkeysym_unicode_map[0x0EC7] = 0x3157;
+ xkeysym_unicode_map[0x0EC8] = 0x3158;
+ xkeysym_unicode_map[0x0EC9] = 0x3159;
+ xkeysym_unicode_map[0x0ECA] = 0x315A;
+ xkeysym_unicode_map[0x0ECB] = 0x315B;
+ xkeysym_unicode_map[0x0ECC] = 0x315C;
+ xkeysym_unicode_map[0x0ECD] = 0x315D;
+ xkeysym_unicode_map[0x0ECE] = 0x315E;
+ xkeysym_unicode_map[0x0ECF] = 0x315F;
+ xkeysym_unicode_map[0x0ED0] = 0x3160;
+ xkeysym_unicode_map[0x0ED1] = 0x3161;
+ xkeysym_unicode_map[0x0ED2] = 0x3162;
+ xkeysym_unicode_map[0x0ED3] = 0x3163;
+ xkeysym_unicode_map[0x0ED4] = 0x11A8;
+ xkeysym_unicode_map[0x0ED5] = 0x11A9;
+ xkeysym_unicode_map[0x0ED6] = 0x11AA;
+ xkeysym_unicode_map[0x0ED7] = 0x11AB;
+ xkeysym_unicode_map[0x0ED8] = 0x11AC;
+ xkeysym_unicode_map[0x0ED9] = 0x11AD;
+ xkeysym_unicode_map[0x0EDA] = 0x11AE;
+ xkeysym_unicode_map[0x0EDB] = 0x11AF;
+ xkeysym_unicode_map[0x0EDC] = 0x11B0;
+ xkeysym_unicode_map[0x0EDD] = 0x11B1;
+ xkeysym_unicode_map[0x0EDE] = 0x11B2;
+ xkeysym_unicode_map[0x0EDF] = 0x11B3;
+ xkeysym_unicode_map[0x0EE0] = 0x11B4;
+ xkeysym_unicode_map[0x0EE1] = 0x11B5;
+ xkeysym_unicode_map[0x0EE2] = 0x11B6;
+ xkeysym_unicode_map[0x0EE3] = 0x11B7;
+ xkeysym_unicode_map[0x0EE4] = 0x11B8;
+ xkeysym_unicode_map[0x0EE5] = 0x11B9;
+ xkeysym_unicode_map[0x0EE6] = 0x11BA;
+ xkeysym_unicode_map[0x0EE7] = 0x11BB;
+ xkeysym_unicode_map[0x0EE8] = 0x11BC;
+ xkeysym_unicode_map[0x0EE9] = 0x11BD;
+ xkeysym_unicode_map[0x0EEA] = 0x11BE;
+ xkeysym_unicode_map[0x0EEB] = 0x11BF;
+ xkeysym_unicode_map[0x0EEC] = 0x11C0;
+ xkeysym_unicode_map[0x0EED] = 0x11C1;
+ xkeysym_unicode_map[0x0EEE] = 0x11C2;
+ xkeysym_unicode_map[0x0EEF] = 0x316D;
+ xkeysym_unicode_map[0x0EF0] = 0x3171;
+ xkeysym_unicode_map[0x0EF1] = 0x3178;
+ xkeysym_unicode_map[0x0EF2] = 0x317F;
+ xkeysym_unicode_map[0x0EF3] = 0x3181;
+ xkeysym_unicode_map[0x0EF4] = 0x3184;
+ xkeysym_unicode_map[0x0EF5] = 0x3186;
+ xkeysym_unicode_map[0x0EF6] = 0x318D;
+ xkeysym_unicode_map[0x0EF7] = 0x318E;
+ xkeysym_unicode_map[0x0EF8] = 0x11EB;
+ xkeysym_unicode_map[0x0EF9] = 0x11F0;
+ xkeysym_unicode_map[0x0EFA] = 0x11F9;
+ xkeysym_unicode_map[0x0EFF] = 0x20A9;
+ xkeysym_unicode_map[0x13A4] = 0x20AC;
+ xkeysym_unicode_map[0x13BC] = 0x0152;
+ xkeysym_unicode_map[0x13BD] = 0x0153;
+ xkeysym_unicode_map[0x13BE] = 0x0178;
+ xkeysym_unicode_map[0x20AC] = 0x20AC;
+}
+
+Key KeyMappingX11::get_keycode(KeySym p_keysym) {
+ if (p_keysym >= 0x20 && p_keysym < 0x7E) { // ASCII, maps 1-1
+ if (p_keysym > 0x60 && p_keysym < 0x7B) { // Lowercase ASCII.
+ return (Key)(p_keysym - 32);
+ } else {
+ return (Key)p_keysym;
+ }
+ }
+
+ const Key *key = xkeysym_map.getptr(p_keysym);
+ if (key) {
+ return *key;
+ }
+ return Key::NONE;
+}
+
+Key KeyMappingX11::get_scancode(unsigned int p_code) {
+ const Key *key = scancode_map.getptr(p_code);
+ if (key) {
+ return *key;
+ }
+
+ return Key::NONE;
+}
+
+unsigned int KeyMappingX11::get_xlibcode(Key p_keysym) {
+ const unsigned int *key = scancode_map_inv.getptr(p_keysym);
+ if (key) {
+ return *key;
+ }
+ return 0x00;
+}
+
+char32_t KeyMappingX11::get_unicode_from_keysym(KeySym p_keysym) {
+ // Latin-1
+ if (p_keysym >= 0x20 && p_keysym <= 0x7E) {
+ return p_keysym;
+ }
+ if (p_keysym >= 0xA0 && p_keysym <= 0xFF) {
+ return p_keysym;
+ }
+
+ // Keypad to Latin-1.
+ if (p_keysym >= 0xFFAA && p_keysym <= 0xFFB9) {
+ return p_keysym - 0xFF80;
+ }
+
+ // Unicode (may be present).
+ if ((p_keysym & 0xFF000000) == 0x01000000) {
+ return p_keysym & 0x00FFFFFF;
+ }
+
+ const char32_t *c = xkeysym_unicode_map.getptr(p_keysym);
+ if (c) {
+ return *c;
+ }
+ return 0;
+}
diff --git a/platform/linuxbsd/key_mapping_x11.h b/platform/linuxbsd/x11/key_mapping_x11.h
index b7b8a3b787..d4278a563c 100644
--- a/platform/linuxbsd/key_mapping_x11.h
+++ b/platform/linuxbsd/x11/key_mapping_x11.h
@@ -1,32 +1,32 @@
-/*************************************************************************/
-/* key_mapping_x11.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* key_mapping_x11.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef KEY_MAPPING_X11_H
#define KEY_MAPPING_X11_H
@@ -44,12 +44,12 @@ class KeyMappingX11 {
KeyMappingX11() {}
public:
+ static void initialize();
+
static Key get_keycode(KeySym p_keysym);
static unsigned int get_xlibcode(Key p_keysym);
static Key get_scancode(unsigned int p_code);
- static KeySym get_keysym(Key p_code);
- static unsigned int get_unicode_from_keysym(KeySym p_keysym);
- static KeySym get_keysym_from_unicode(unsigned int p_unicode);
+ static char32_t get_unicode_from_keysym(KeySym p_keysym);
};
#endif // KEY_MAPPING_X11_H
diff --git a/platform/linuxbsd/vulkan_context_x11.cpp b/platform/linuxbsd/x11/vulkan_context_x11.cpp
index b4f585726f..d240480f61 100644
--- a/platform/linuxbsd/vulkan_context_x11.cpp
+++ b/platform/linuxbsd/x11/vulkan_context_x11.cpp
@@ -1,32 +1,34 @@
-/*************************************************************************/
-/* vulkan_context_x11.cpp */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* vulkan_context_x11.cpp */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
+
+#ifdef VULKAN_ENABLED
#include "vulkan_context_x11.h"
@@ -59,3 +61,5 @@ VulkanContextX11::VulkanContextX11() {
VulkanContextX11::~VulkanContextX11() {
}
+
+#endif // VULKAN_ENABLED
diff --git a/platform/linuxbsd/vulkan_context_x11.h b/platform/linuxbsd/x11/vulkan_context_x11.h
index 0c4a6cd278..d093bca853 100644
--- a/platform/linuxbsd/vulkan_context_x11.h
+++ b/platform/linuxbsd/x11/vulkan_context_x11.h
@@ -1,36 +1,38 @@
-/*************************************************************************/
-/* vulkan_context_x11.h */
-/*************************************************************************/
-/* This file is part of: */
-/* GODOT ENGINE */
-/* https://godotengine.org */
-/*************************************************************************/
-/* Copyright (c) 2007-2022 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2022 Godot Engine contributors (cf. AUTHORS.md). */
-/* */
-/* Permission is hereby granted, free of charge, to any person obtaining */
-/* a copy of this software and associated documentation files (the */
-/* "Software"), to deal in the Software without restriction, including */
-/* without limitation the rights to use, copy, modify, merge, publish, */
-/* distribute, sublicense, and/or sell copies of the Software, and to */
-/* permit persons to whom the Software is furnished to do so, subject to */
-/* the following conditions: */
-/* */
-/* The above copyright notice and this permission notice shall be */
-/* included in all copies or substantial portions of the Software. */
-/* */
-/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
-/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
-/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/
-/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
-/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
-/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
-/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
-/*************************************************************************/
+/**************************************************************************/
+/* vulkan_context_x11.h */
+/**************************************************************************/
+/* This file is part of: */
+/* GODOT ENGINE */
+/* https://godotengine.org */
+/**************************************************************************/
+/* Copyright (c) 2014-present Godot Engine contributors (see AUTHORS.md). */
+/* Copyright (c) 2007-2014 Juan Linietsky, Ariel Manzur. */
+/* */
+/* Permission is hereby granted, free of charge, to any person obtaining */
+/* a copy of this software and associated documentation files (the */
+/* "Software"), to deal in the Software without restriction, including */
+/* without limitation the rights to use, copy, modify, merge, publish, */
+/* distribute, sublicense, and/or sell copies of the Software, and to */
+/* permit persons to whom the Software is furnished to do so, subject to */
+/* the following conditions: */
+/* */
+/* The above copyright notice and this permission notice shall be */
+/* included in all copies or substantial portions of the Software. */
+/* */
+/* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */
+/* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */
+/* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. */
+/* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */
+/* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */
+/* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */
+/* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */
+/**************************************************************************/
#ifndef VULKAN_CONTEXT_X11_H
#define VULKAN_CONTEXT_X11_H
+#ifdef VULKAN_ENABLED
+
#include "drivers/vulkan/vulkan_context.h"
#include <X11/Xlib.h>
@@ -44,4 +46,6 @@ public:
~VulkanContextX11();
};
+#endif // VULKAN_ENABLED
+
#endif // VULKAN_CONTEXT_X11_H