Wise&mystical  1.0
Project about Europe
Loading...
Searching...
No Matches
x11_platform.h
Go to the documentation of this file.
1//========================================================================
2// GLFW 3.4 X11 - www.glfw.org
3//------------------------------------------------------------------------
4// Copyright (c) 2002-2006 Marcus Geelnard
5// Copyright (c) 2006-2019 Camilla Löwy <elmindreda@glfw.org>
6//
7// This software is provided 'as-is', without any express or implied
8// warranty. In no event will the authors be held liable for any damages
9// arising from the use of this software.
10//
11// Permission is granted to anyone to use this software for any purpose,
12// including commercial applications, and to alter it and redistribute it
13// freely, subject to the following restrictions:
14//
15// 1. The origin of this software must not be misrepresented; you must not
16// claim that you wrote the original software. If you use this software
17// in a product, an acknowledgment in the product documentation would
18// be appreciated but is not required.
19//
20// 2. Altered source versions must be plainly marked as such, and must not
21// be misrepresented as being the original software.
22//
23// 3. This notice may not be removed or altered from any source
24// distribution.
25//
26//========================================================================
27
28#include <unistd.h>
29#include <signal.h>
30#include <stdint.h>
31#include <dlfcn.h>
32
33#include <X11/Xlib.h>
34#include <X11/keysym.h>
35#include <X11/Xatom.h>
36#include <X11/Xresource.h>
37#include <X11/Xcursor/Xcursor.h>
38
39// The XRandR extension provides mode setting and gamma control
40#include <X11/extensions/Xrandr.h>
41
42// The Xkb extension provides improved keyboard support
43#include <X11/XKBlib.h>
44
45// The Xinerama extension provides legacy monitor indices
46#include <X11/extensions/Xinerama.h>
47
48// The XInput extension provides raw mouse motion input
49#include <X11/extensions/XInput2.h>
50
51// The Shape extension provides custom window shapes
52#include <X11/extensions/shape.h>
53
54typedef XClassHint* (* PFN_XAllocClassHint)(void);
55typedef XSizeHints* (* PFN_XAllocSizeHints)(void);
56typedef XWMHints* (* PFN_XAllocWMHints)(void);
57typedef int (* PFN_XChangeProperty)(Display*,Window,Atom,Atom,int,int,const unsigned char*,int);
58typedef int (* PFN_XChangeWindowAttributes)(Display*,Window,unsigned long,XSetWindowAttributes*);
59typedef Bool (* PFN_XCheckIfEvent)(Display*,XEvent*,Bool(*)(Display*,XEvent*,XPointer),XPointer);
60typedef Bool (* PFN_XCheckTypedWindowEvent)(Display*,Window,int,XEvent*);
61typedef int (* PFN_XCloseDisplay)(Display*);
62typedef Status (* PFN_XCloseIM)(XIM);
63typedef int (* PFN_XConvertSelection)(Display*,Atom,Atom,Atom,Window,Time);
64typedef Colormap (* PFN_XCreateColormap)(Display*,Window,Visual*,int);
65typedef Cursor (* PFN_XCreateFontCursor)(Display*,unsigned int);
66typedef XIC (* PFN_XCreateIC)(XIM,...);
67typedef Region (* PFN_XCreateRegion)(void);
68typedef Window (* PFN_XCreateWindow)(Display*,Window,int,int,unsigned int,unsigned int,unsigned int,int,unsigned int,Visual*,unsigned long,XSetWindowAttributes*);
69typedef int (* PFN_XDefineCursor)(Display*,Window,Cursor);
70typedef int (* PFN_XDeleteContext)(Display*,XID,XContext);
71typedef int (* PFN_XDeleteProperty)(Display*,Window,Atom);
72typedef void (* PFN_XDestroyIC)(XIC);
73typedef int (* PFN_XDestroyRegion)(Region);
74typedef int (* PFN_XDestroyWindow)(Display*,Window);
75typedef int (* PFN_XDisplayKeycodes)(Display*,int*,int*);
76typedef int (* PFN_XEventsQueued)(Display*,int);
77typedef Bool (* PFN_XFilterEvent)(XEvent*,Window);
78typedef int (* PFN_XFindContext)(Display*,XID,XContext,XPointer*);
79typedef int (* PFN_XFlush)(Display*);
80typedef int (* PFN_XFree)(void*);
81typedef int (* PFN_XFreeColormap)(Display*,Colormap);
82typedef int (* PFN_XFreeCursor)(Display*,Cursor);
83typedef void (* PFN_XFreeEventData)(Display*,XGenericEventCookie*);
84typedef int (* PFN_XGetErrorText)(Display*,int,char*,int);
85typedef Bool (* PFN_XGetEventData)(Display*,XGenericEventCookie*);
86typedef char* (* PFN_XGetICValues)(XIC,...);
87typedef char* (* PFN_XGetIMValues)(XIM,...);
88typedef int (* PFN_XGetInputFocus)(Display*,Window*,int*);
89typedef KeySym* (* PFN_XGetKeyboardMapping)(Display*,KeyCode,int,int*);
90typedef int (* PFN_XGetScreenSaver)(Display*,int*,int*,int*,int*);
91typedef Window (* PFN_XGetSelectionOwner)(Display*,Atom);
92typedef XVisualInfo* (* PFN_XGetVisualInfo)(Display*,long,XVisualInfo*,int*);
93typedef Status (* PFN_XGetWMNormalHints)(Display*,Window,XSizeHints*,long*);
94typedef Status (* PFN_XGetWindowAttributes)(Display*,Window,XWindowAttributes*);
95typedef int (* PFN_XGetWindowProperty)(Display*,Window,Atom,long,long,Bool,Atom,Atom*,int*,unsigned long*,unsigned long*,unsigned char**);
96typedef int (* PFN_XGrabPointer)(Display*,Window,Bool,unsigned int,int,int,Window,Cursor,Time);
97typedef Status (* PFN_XIconifyWindow)(Display*,Window,int);
98typedef Status (* PFN_XInitThreads)(void);
99typedef Atom (* PFN_XInternAtom)(Display*,const char*,Bool);
100typedef int (* PFN_XLookupString)(XKeyEvent*,char*,int,KeySym*,XComposeStatus*);
101typedef int (* PFN_XMapRaised)(Display*,Window);
102typedef int (* PFN_XMapWindow)(Display*,Window);
103typedef int (* PFN_XMoveResizeWindow)(Display*,Window,int,int,unsigned int,unsigned int);
104typedef int (* PFN_XMoveWindow)(Display*,Window,int,int);
105typedef int (* PFN_XNextEvent)(Display*,XEvent*);
106typedef Display* (* PFN_XOpenDisplay)(const char*);
107typedef XIM (* PFN_XOpenIM)(Display*,XrmDatabase*,char*,char*);
108typedef int (* PFN_XPeekEvent)(Display*,XEvent*);
109typedef int (* PFN_XPending)(Display*);
110typedef Bool (* PFN_XQueryExtension)(Display*,const char*,int*,int*,int*);
111typedef Bool (* PFN_XQueryPointer)(Display*,Window,Window*,Window*,int*,int*,int*,int*,unsigned int*);
112typedef int (* PFN_XRaiseWindow)(Display*,Window);
113typedef Bool (* PFN_XRegisterIMInstantiateCallback)(Display*,void*,char*,char*,XIDProc,XPointer);
114typedef int (* PFN_XResizeWindow)(Display*,Window,unsigned int,unsigned int);
115typedef char* (* PFN_XResourceManagerString)(Display*);
116typedef int (* PFN_XSaveContext)(Display*,XID,XContext,const char*);
117typedef int (* PFN_XSelectInput)(Display*,Window,long);
118typedef Status (* PFN_XSendEvent)(Display*,Window,Bool,long,XEvent*);
119typedef int (* PFN_XSetClassHint)(Display*,Window,XClassHint*);
120typedef XErrorHandler (* PFN_XSetErrorHandler)(XErrorHandler);
121typedef void (* PFN_XSetICFocus)(XIC);
122typedef char* (* PFN_XSetIMValues)(XIM,...);
123typedef int (* PFN_XSetInputFocus)(Display*,Window,int,Time);
124typedef char* (* PFN_XSetLocaleModifiers)(const char*);
125typedef int (* PFN_XSetScreenSaver)(Display*,int,int,int,int);
126typedef int (* PFN_XSetSelectionOwner)(Display*,Atom,Window,Time);
127typedef int (* PFN_XSetWMHints)(Display*,Window,XWMHints*);
128typedef void (* PFN_XSetWMNormalHints)(Display*,Window,XSizeHints*);
129typedef Status (* PFN_XSetWMProtocols)(Display*,Window,Atom*,int);
130typedef Bool (* PFN_XSupportsLocale)(void);
131typedef int (* PFN_XSync)(Display*,Bool);
132typedef Bool (* PFN_XTranslateCoordinates)(Display*,Window,Window,int,int,int*,int*,Window*);
133typedef int (* PFN_XUndefineCursor)(Display*,Window);
134typedef int (* PFN_XUngrabPointer)(Display*,Time);
135typedef int (* PFN_XUnmapWindow)(Display*,Window);
136typedef void (* PFN_XUnsetICFocus)(XIC);
137typedef VisualID (* PFN_XVisualIDFromVisual)(Visual*);
138typedef int (* PFN_XWarpPointer)(Display*,Window,Window,int,int,unsigned int,unsigned int,int,int);
139typedef void (* PFN_XkbFreeKeyboard)(XkbDescPtr,unsigned int,Bool);
140typedef void (* PFN_XkbFreeNames)(XkbDescPtr,unsigned int,Bool);
141typedef XkbDescPtr (* PFN_XkbGetMap)(Display*,unsigned int,unsigned int);
142typedef Status (* PFN_XkbGetNames)(Display*,unsigned int,XkbDescPtr);
143typedef Status (* PFN_XkbGetState)(Display*,unsigned int,XkbStatePtr);
144typedef KeySym (* PFN_XkbKeycodeToKeysym)(Display*,KeyCode,int,int);
145typedef Bool (* PFN_XkbQueryExtension)(Display*,int*,int*,int*,int*,int*);
146typedef Bool (* PFN_XkbSelectEventDetails)(Display*,unsigned int,unsigned int,unsigned long,unsigned long);
147typedef Bool (* PFN_XkbSetDetectableAutoRepeat)(Display*,Bool,Bool*);
148typedef void (* PFN_XrmDestroyDatabase)(XrmDatabase);
149typedef Bool (* PFN_XrmGetResource)(XrmDatabase,const char*,const char*,char**,XrmValue*);
150typedef XrmDatabase (* PFN_XrmGetStringDatabase)(const char*);
151typedef void (* PFN_XrmInitialize)(void);
152typedef XrmQuark (* PFN_XrmUniqueQuark)(void);
153typedef Bool (* PFN_XUnregisterIMInstantiateCallback)(Display*,void*,char*,char*,XIDProc,XPointer);
154typedef int (* PFN_Xutf8LookupString)(XIC,XKeyPressedEvent*,char*,int,KeySym*,Status*);
155typedef void (* PFN_Xutf8SetWMProperties)(Display*,Window,const char*,const char*,char**,int,XSizeHints*,XWMHints*,XClassHint*);
156#define XAllocClassHint _glfw.x11.xlib.AllocClassHint
157#define XAllocSizeHints _glfw.x11.xlib.AllocSizeHints
158#define XAllocWMHints _glfw.x11.xlib.AllocWMHints
159#define XChangeProperty _glfw.x11.xlib.ChangeProperty
160#define XChangeWindowAttributes _glfw.x11.xlib.ChangeWindowAttributes
161#define XCheckIfEvent _glfw.x11.xlib.CheckIfEvent
162#define XCheckTypedWindowEvent _glfw.x11.xlib.CheckTypedWindowEvent
163#define XCloseDisplay _glfw.x11.xlib.CloseDisplay
164#define XCloseIM _glfw.x11.xlib.CloseIM
165#define XConvertSelection _glfw.x11.xlib.ConvertSelection
166#define XCreateColormap _glfw.x11.xlib.CreateColormap
167#define XCreateFontCursor _glfw.x11.xlib.CreateFontCursor
168#define XCreateIC _glfw.x11.xlib.CreateIC
169#define XCreateRegion _glfw.x11.xlib.CreateRegion
170#define XCreateWindow _glfw.x11.xlib.CreateWindow
171#define XDefineCursor _glfw.x11.xlib.DefineCursor
172#define XDeleteContext _glfw.x11.xlib.DeleteContext
173#define XDeleteProperty _glfw.x11.xlib.DeleteProperty
174#define XDestroyIC _glfw.x11.xlib.DestroyIC
175#define XDestroyRegion _glfw.x11.xlib.DestroyRegion
176#define XDestroyWindow _glfw.x11.xlib.DestroyWindow
177#define XDisplayKeycodes _glfw.x11.xlib.DisplayKeycodes
178#define XEventsQueued _glfw.x11.xlib.EventsQueued
179#define XFilterEvent _glfw.x11.xlib.FilterEvent
180#define XFindContext _glfw.x11.xlib.FindContext
181#define XFlush _glfw.x11.xlib.Flush
182#define XFree _glfw.x11.xlib.Free
183#define XFreeColormap _glfw.x11.xlib.FreeColormap
184#define XFreeCursor _glfw.x11.xlib.FreeCursor
185#define XFreeEventData _glfw.x11.xlib.FreeEventData
186#define XGetErrorText _glfw.x11.xlib.GetErrorText
187#define XGetEventData _glfw.x11.xlib.GetEventData
188#define XGetICValues _glfw.x11.xlib.GetICValues
189#define XGetIMValues _glfw.x11.xlib.GetIMValues
190#define XGetInputFocus _glfw.x11.xlib.GetInputFocus
191#define XGetKeyboardMapping _glfw.x11.xlib.GetKeyboardMapping
192#define XGetScreenSaver _glfw.x11.xlib.GetScreenSaver
193#define XGetSelectionOwner _glfw.x11.xlib.GetSelectionOwner
194#define XGetVisualInfo _glfw.x11.xlib.GetVisualInfo
195#define XGetWMNormalHints _glfw.x11.xlib.GetWMNormalHints
196#define XGetWindowAttributes _glfw.x11.xlib.GetWindowAttributes
197#define XGetWindowProperty _glfw.x11.xlib.GetWindowProperty
198#define XGrabPointer _glfw.x11.xlib.GrabPointer
199#define XIconifyWindow _glfw.x11.xlib.IconifyWindow
200#define XInitThreads _glfw.x11.xlib.InitThreads
201#define XInternAtom _glfw.x11.xlib.InternAtom
202#define XLookupString _glfw.x11.xlib.LookupString
203#define XMapRaised _glfw.x11.xlib.MapRaised
204#define XMapWindow _glfw.x11.xlib.MapWindow
205#define XMoveResizeWindow _glfw.x11.xlib.MoveResizeWindow
206#define XMoveWindow _glfw.x11.xlib.MoveWindow
207#define XNextEvent _glfw.x11.xlib.NextEvent
208#define XOpenDisplay _glfw.x11.xlib.OpenDisplay
209#define XOpenIM _glfw.x11.xlib.OpenIM
210#define XPeekEvent _glfw.x11.xlib.PeekEvent
211#define XPending _glfw.x11.xlib.Pending
212#define XQueryExtension _glfw.x11.xlib.QueryExtension
213#define XQueryPointer _glfw.x11.xlib.QueryPointer
214#define XRaiseWindow _glfw.x11.xlib.RaiseWindow
215#define XRegisterIMInstantiateCallback _glfw.x11.xlib.RegisterIMInstantiateCallback
216#define XResizeWindow _glfw.x11.xlib.ResizeWindow
217#define XResourceManagerString _glfw.x11.xlib.ResourceManagerString
218#define XSaveContext _glfw.x11.xlib.SaveContext
219#define XSelectInput _glfw.x11.xlib.SelectInput
220#define XSendEvent _glfw.x11.xlib.SendEvent
221#define XSetClassHint _glfw.x11.xlib.SetClassHint
222#define XSetErrorHandler _glfw.x11.xlib.SetErrorHandler
223#define XSetICFocus _glfw.x11.xlib.SetICFocus
224#define XSetIMValues _glfw.x11.xlib.SetIMValues
225#define XSetInputFocus _glfw.x11.xlib.SetInputFocus
226#define XSetLocaleModifiers _glfw.x11.xlib.SetLocaleModifiers
227#define XSetScreenSaver _glfw.x11.xlib.SetScreenSaver
228#define XSetSelectionOwner _glfw.x11.xlib.SetSelectionOwner
229#define XSetWMHints _glfw.x11.xlib.SetWMHints
230#define XSetWMNormalHints _glfw.x11.xlib.SetWMNormalHints
231#define XSetWMProtocols _glfw.x11.xlib.SetWMProtocols
232#define XSupportsLocale _glfw.x11.xlib.SupportsLocale
233#define XSync _glfw.x11.xlib.Sync
234#define XTranslateCoordinates _glfw.x11.xlib.TranslateCoordinates
235#define XUndefineCursor _glfw.x11.xlib.UndefineCursor
236#define XUngrabPointer _glfw.x11.xlib.UngrabPointer
237#define XUnmapWindow _glfw.x11.xlib.UnmapWindow
238#define XUnsetICFocus _glfw.x11.xlib.UnsetICFocus
239#define XVisualIDFromVisual _glfw.x11.xlib.VisualIDFromVisual
240#define XWarpPointer _glfw.x11.xlib.WarpPointer
241#define XkbFreeKeyboard _glfw.x11.xkb.FreeKeyboard
242#define XkbFreeNames _glfw.x11.xkb.FreeNames
243#define XkbGetMap _glfw.x11.xkb.GetMap
244#define XkbGetNames _glfw.x11.xkb.GetNames
245#define XkbGetState _glfw.x11.xkb.GetState
246#define XkbKeycodeToKeysym _glfw.x11.xkb.KeycodeToKeysym
247#define XkbQueryExtension _glfw.x11.xkb.QueryExtension
248#define XkbSelectEventDetails _glfw.x11.xkb.SelectEventDetails
249#define XkbSetDetectableAutoRepeat _glfw.x11.xkb.SetDetectableAutoRepeat
250#define XrmDestroyDatabase _glfw.x11.xrm.DestroyDatabase
251#define XrmGetResource _glfw.x11.xrm.GetResource
252#define XrmGetStringDatabase _glfw.x11.xrm.GetStringDatabase
253#define XrmInitialize _glfw.x11.xrm.Initialize
254#define XrmUniqueQuark _glfw.x11.xrm.UniqueQuark
255#define XUnregisterIMInstantiateCallback _glfw.x11.xlib.UnregisterIMInstantiateCallback
256#define Xutf8LookupString _glfw.x11.xlib.utf8LookupString
257#define Xutf8SetWMProperties _glfw.x11.xlib.utf8SetWMProperties
258
259typedef XRRCrtcGamma* (* PFN_XRRAllocGamma)(int);
260typedef void (* PFN_XRRFreeCrtcInfo)(XRRCrtcInfo*);
261typedef void (* PFN_XRRFreeGamma)(XRRCrtcGamma*);
262typedef void (* PFN_XRRFreeOutputInfo)(XRROutputInfo*);
263typedef void (* PFN_XRRFreeScreenResources)(XRRScreenResources*);
264typedef XRRCrtcGamma* (* PFN_XRRGetCrtcGamma)(Display*,RRCrtc);
265typedef int (* PFN_XRRGetCrtcGammaSize)(Display*,RRCrtc);
266typedef XRRCrtcInfo* (* PFN_XRRGetCrtcInfo) (Display*,XRRScreenResources*,RRCrtc);
267typedef XRROutputInfo* (* PFN_XRRGetOutputInfo)(Display*,XRRScreenResources*,RROutput);
268typedef RROutput (* PFN_XRRGetOutputPrimary)(Display*,Window);
269typedef XRRScreenResources* (* PFN_XRRGetScreenResourcesCurrent)(Display*,Window);
270typedef Bool (* PFN_XRRQueryExtension)(Display*,int*,int*);
271typedef Status (* PFN_XRRQueryVersion)(Display*,int*,int*);
272typedef void (* PFN_XRRSelectInput)(Display*,Window,int);
273typedef Status (* PFN_XRRSetCrtcConfig)(Display*,XRRScreenResources*,RRCrtc,Time,int,int,RRMode,Rotation,RROutput*,int);
274typedef void (* PFN_XRRSetCrtcGamma)(Display*,RRCrtc,XRRCrtcGamma*);
275typedef int (* PFN_XRRUpdateConfiguration)(XEvent*);
276#define XRRAllocGamma _glfw.x11.randr.AllocGamma
277#define XRRFreeCrtcInfo _glfw.x11.randr.FreeCrtcInfo
278#define XRRFreeGamma _glfw.x11.randr.FreeGamma
279#define XRRFreeOutputInfo _glfw.x11.randr.FreeOutputInfo
280#define XRRFreeScreenResources _glfw.x11.randr.FreeScreenResources
281#define XRRGetCrtcGamma _glfw.x11.randr.GetCrtcGamma
282#define XRRGetCrtcGammaSize _glfw.x11.randr.GetCrtcGammaSize
283#define XRRGetCrtcInfo _glfw.x11.randr.GetCrtcInfo
284#define XRRGetOutputInfo _glfw.x11.randr.GetOutputInfo
285#define XRRGetOutputPrimary _glfw.x11.randr.GetOutputPrimary
286#define XRRGetScreenResourcesCurrent _glfw.x11.randr.GetScreenResourcesCurrent
287#define XRRQueryExtension _glfw.x11.randr.QueryExtension
288#define XRRQueryVersion _glfw.x11.randr.QueryVersion
289#define XRRSelectInput _glfw.x11.randr.SelectInput
290#define XRRSetCrtcConfig _glfw.x11.randr.SetCrtcConfig
291#define XRRSetCrtcGamma _glfw.x11.randr.SetCrtcGamma
292#define XRRUpdateConfiguration _glfw.x11.randr.UpdateConfiguration
293
294typedef XcursorImage* (* PFN_XcursorImageCreate)(int,int);
295typedef void (* PFN_XcursorImageDestroy)(XcursorImage*);
296typedef Cursor (* PFN_XcursorImageLoadCursor)(Display*,const XcursorImage*);
297typedef char* (* PFN_XcursorGetTheme)(Display*);
298typedef int (* PFN_XcursorGetDefaultSize)(Display*);
299typedef XcursorImage* (* PFN_XcursorLibraryLoadImage)(const char*,const char*,int);
300#define XcursorImageCreate _glfw.x11.xcursor.ImageCreate
301#define XcursorImageDestroy _glfw.x11.xcursor.ImageDestroy
302#define XcursorImageLoadCursor _glfw.x11.xcursor.ImageLoadCursor
303#define XcursorGetTheme _glfw.x11.xcursor.GetTheme
304#define XcursorGetDefaultSize _glfw.x11.xcursor.GetDefaultSize
305#define XcursorLibraryLoadImage _glfw.x11.xcursor.LibraryLoadImage
306
307typedef Bool (* PFN_XineramaIsActive)(Display*);
308typedef Bool (* PFN_XineramaQueryExtension)(Display*,int*,int*);
309typedef XineramaScreenInfo* (* PFN_XineramaQueryScreens)(Display*,int*);
310#define XineramaIsActive _glfw.x11.xinerama.IsActive
311#define XineramaQueryExtension _glfw.x11.xinerama.QueryExtension
312#define XineramaQueryScreens _glfw.x11.xinerama.QueryScreens
313
314typedef XID xcb_window_t;
315typedef XID xcb_visualid_t;
317typedef xcb_connection_t* (* PFN_XGetXCBConnection)(Display*);
318#define XGetXCBConnection _glfw.x11.x11xcb.GetXCBConnection
319
320typedef Bool (* PFN_XF86VidModeQueryExtension)(Display*,int*,int*);
321typedef Bool (* PFN_XF86VidModeGetGammaRamp)(Display*,int,int,unsigned short*,unsigned short*,unsigned short*);
322typedef Bool (* PFN_XF86VidModeSetGammaRamp)(Display*,int,int,unsigned short*,unsigned short*,unsigned short*);
323typedef Bool (* PFN_XF86VidModeGetGammaRampSize)(Display*,int,int*);
324#define XF86VidModeQueryExtension _glfw.x11.vidmode.QueryExtension
325#define XF86VidModeGetGammaRamp _glfw.x11.vidmode.GetGammaRamp
326#define XF86VidModeSetGammaRamp _glfw.x11.vidmode.SetGammaRamp
327#define XF86VidModeGetGammaRampSize _glfw.x11.vidmode.GetGammaRampSize
328
329typedef Status (* PFN_XIQueryVersion)(Display*,int*,int*);
330typedef int (* PFN_XISelectEvents)(Display*,Window,XIEventMask*,int);
331#define XIQueryVersion _glfw.x11.xi.QueryVersion
332#define XISelectEvents _glfw.x11.xi.SelectEvents
333
334typedef Bool (* PFN_XRenderQueryExtension)(Display*,int*,int*);
335typedef Status (* PFN_XRenderQueryVersion)(Display*dpy,int*,int*);
336typedef XRenderPictFormat* (* PFN_XRenderFindVisualFormat)(Display*,Visual const*);
337#define XRenderQueryExtension _glfw.x11.xrender.QueryExtension
338#define XRenderQueryVersion _glfw.x11.xrender.QueryVersion
339#define XRenderFindVisualFormat _glfw.x11.xrender.FindVisualFormat
340
341typedef Bool (* PFN_XShapeQueryExtension)(Display*,int*,int*);
342typedef Status (* PFN_XShapeQueryVersion)(Display*dpy,int*,int*);
343typedef void (* PFN_XShapeCombineRegion)(Display*,Window,int,int,int,Region,int);
344typedef void (* PFN_XShapeCombineMask)(Display*,Window,int,int,int,Pixmap,int);
345
346#define XShapeQueryExtension _glfw.x11.xshape.QueryExtension
347#define XShapeQueryVersion _glfw.x11.xshape.QueryVersion
348#define XShapeCombineRegion _glfw.x11.xshape.ShapeCombineRegion
349#define XShapeCombineMask _glfw.x11.xshape.ShapeCombineMask
350
353
355{
357 const void* pNext;
359 Display* dpy;
360 Window window;
362
364{
366 const void* pNext;
371
376
377#include "posix_thread.h"
378#include "posix_time.h"
379#include "xkb_unicode.h"
380#include "glx_context.h"
381#if defined(__linux__)
382#include "linux_joystick.h"
383#else
384#include "null_joystick.h"
385#endif
386
387#define _glfw_dlopen(name) dlopen(name, RTLD_LAZY | RTLD_LOCAL)
388#define _glfw_dlclose(handle) dlclose(handle)
389#define _glfw_dlsym(handle, name) dlsym(handle, name)
390
391#define _GLFW_PLATFORM_WINDOW_STATE _GLFWwindowX11 x11
392#define _GLFW_PLATFORM_LIBRARY_WINDOW_STATE _GLFWlibraryX11 x11
393#define _GLFW_PLATFORM_MONITOR_STATE _GLFWmonitorX11 x11
394#define _GLFW_PLATFORM_CURSOR_STATE _GLFWcursorX11 x11
395
396
397// X11-specific per-window data
398//
399typedef struct _GLFWwindowX11
400{
401 Colormap colormap;
402 Window handle;
403 Window parent;
404 XIC ic;
405
409
410 // Whether the visual supports framebuffer transparency
412
413 // Cached position and size used to filter out duplicate events
415 int xpos, ypos;
416
417 // The last received cursor position, regardless of source
419 // The last position the cursor was warped to by GLFW
421
422 // The time of the last KeyPress event per keycode, for discarding
423 // duplicate key events generated for some keys by ibus
424 Time keyPressTimes[256];
425
427
428// X11-specific global data
429//
430typedef struct _GLFWlibraryX11
431{
432 Display* display;
434 Window root;
435
436 // System content scale
438 // Helper window for IPC
440 // Invisible cursor for hidden cursor mode
442 // Context for mapping window XIDs to _GLFWwindow pointers
443 XContext context;
444 // XIM input method
445 XIM im;
446 // Most recent error code received by X error handler
448 // Primary selection string (while the primary selection is owned)
450 // Clipboard string (while the selection is owned)
452 // Key name string
454 // X11 keycode to GLFW key LUT
455 short int keycodes[256];
456 // GLFW key to X11 keycode LUT
457 short int scancodes[GLFW_KEY_LAST + 1];
458 // Where to place the cursor when re-enabled
460 // The window whose disabled cursor mode is active
462
463 // Window manager atoms
492
493 // Xdnd (drag and drop) atoms
504
505 // Selection (clipboard) atoms
508 Atom INCR;
513 Atom NULL_;
518
519 struct {
520 void* handle;
611
612 struct {
619
620 struct {
622 void* handle;
625 int major;
626 int minor;
647
648 struct {
652 int eventBase;
653 int errorBase;
654 int major;
655 int minor;
656 unsigned int group;
667
668 struct {
669 int count;
675
676 struct {
678 Window source;
679 Atom format;
681
682 struct {
683 void* handle;
691
692 struct {
694 void* handle;
695 int major;
696 int minor;
701
702 struct {
703 void* handle;
706
707 struct {
709 void* handle;
710 int eventBase;
711 int errorBase;
717
718 struct {
720 void* handle;
721 int majorOpcode;
722 int eventBase;
723 int errorBase;
724 int major;
725 int minor;
728 } xi;
729
730 struct {
732 void* handle;
733 int major;
734 int minor;
735 int eventBase;
736 int errorBase;
741
742 struct {
744 void* handle;
745 int major;
746 int minor;
747 int eventBase;
748 int errorBase;
754
756
757// X11-specific per-monitor data
758//
759typedef struct _GLFWmonitorX11
760{
761 RROutput output;
762 RRCrtc crtc;
763 RRMode oldMode;
764
765 // Index of corresponding Xinerama screen,
766 // for EWMH full screen window placement
767 int index;
768
770
771// X11-specific per-cursor data
772//
773typedef struct _GLFWcursorX11
774{
775 Cursor handle;
776
778
779
780void _glfwPollMonitorsX11(void);
781void _glfwSetVideoModeX11(_GLFWmonitor* monitor, const GLFWvidmode* desired);
783
784Cursor _glfwCreateCursorX11(const GLFWimage* image, int xhot, int yhot);
785
786unsigned long _glfwGetWindowPropertyX11(Window window,
787 Atom property,
788 Atom type,
789 unsigned char** value);
791
792void _glfwGrabErrorHandlerX11(void);
794void _glfwInputErrorX11(int error, const char* message);
795
798
#define APIENTRY
Compiler- and platform-specific preprocessor work.
Definition: glfw3.h:125
#define GLFW_KEY_LAST
Definition: glfw3.h:515
uint64_t VkSurfaceKHR
Definition: internal.h:120
void * VkInstance
Definition: internal.h:118
void * VkPhysicalDevice
Definition: internal.h:119
int GLFWbool
Definition: internal.h:61
unsigned int uint32_t
Definition: stdint.h:80
char keynames[GLFW_KEY_LAST+1][5]
Definition: x11_platform.h:453
PFN_XDefineCursor DefineCursor
Definition: x11_platform.h:537
Atom NET_SUPPORTING_WM_CHECK
Definition: x11_platform.h:465
Atom NET_WM_BYPASS_COMPOSITOR
Definition: x11_platform.h:482
PFN_XCreateRegion CreateRegion
Definition: x11_platform.h:535
PFN_XShapeQueryVersion QueryVersion
Definition: x11_platform.h:751
PFN_XRRGetCrtcGamma GetCrtcGamma
Definition: x11_platform.h:634
PFN_XQueryPointer QueryPointer
Definition: x11_platform.h:579
PFN_XRRQueryVersion QueryVersion
Definition: x11_platform.h:641
PFN_Xutf8SetWMProperties utf8SetWMProperties
Definition: x11_platform.h:609
PFN_XSetLocaleModifiers SetLocaleModifiers
Definition: x11_platform.h:592
PFN_XrmGetStringDatabase GetStringDatabase
Definition: x11_platform.h:615
PFN_XineramaIsActive IsActive
Definition: x11_platform.h:697
PFN_XineramaQueryExtension QueryExtension
Definition: x11_platform.h:698
PFN_XMapWindow MapWindow
Definition: x11_platform.h:570
PFN_XSetScreenSaver SetScreenSaver
Definition: x11_platform.h:593
PFN_XCreateFontCursor CreateFontCursor
Definition: x11_platform.h:533
PFN_XCreateColormap CreateColormap
Definition: x11_platform.h:532
PFN_XGetWMNormalHints GetWMNormalHints
Definition: x11_platform.h:561
PFN_XFlush Flush
Definition: x11_platform.h:547
PFN_XcursorLibraryLoadImage LibraryLoadImage
Definition: x11_platform.h:689
GLFWbool available
Definition: x11_platform.h:621
PFN_XCreateIC CreateIC
Definition: x11_platform.h:534
PFN_XRRSelectInput SelectInput
Definition: x11_platform.h:642
struct _GLFWlibraryX11::@42 randr
PFN_XOpenDisplay OpenDisplay
Definition: x11_platform.h:574
short int scancodes[GLFW_KEY_LAST+1]
Definition: x11_platform.h:457
PFN_XFreeColormap FreeColormap
Definition: x11_platform.h:549
struct _GLFWlibraryX11::@41 xrm
PFN_XcursorGetDefaultSize GetDefaultSize
Definition: x11_platform.h:688
struct _GLFWlibraryX11::@49 vidmode
PFN_XSaveContext SaveContext
Definition: x11_platform.h:584
PFN_XkbSelectEventDetails SelectEventDetails
Definition: x11_platform.h:664
PFN_XQueryExtension QueryExtension
Definition: x11_platform.h:578
PFN_XRRUpdateConfiguration UpdateConfiguration
Definition: x11_platform.h:645
PFN_XGetWindowAttributes GetWindowAttributes
Definition: x11_platform.h:562
PFN_XGetScreenSaver GetScreenSaver
Definition: x11_platform.h:558
PFN_XF86VidModeQueryExtension QueryExtension
Definition: x11_platform.h:712
_GLFWwindow * disabledCursorWindow
Definition: x11_platform.h:461
PFN_XSetInputFocus SetInputFocus
Definition: x11_platform.h:591
PFN_XIQueryVersion QueryVersion
Definition: x11_platform.h:726
PFN_XGetWindowProperty GetWindowProperty
Definition: x11_platform.h:563
PFN_XRenderQueryVersion QueryVersion
Definition: x11_platform.h:738
PFN_XCheckIfEvent CheckIfEvent
Definition: x11_platform.h:527
PFN_XInternAtom InternAtom
Definition: x11_platform.h:567
PFN_XNextEvent NextEvent
Definition: x11_platform.h:573
PFN_XRRGetOutputInfo GetOutputInfo
Definition: x11_platform.h:637
PFN_XDeleteContext DeleteContext
Definition: x11_platform.h:538
PFN_XSetWMNormalHints SetWMNormalHints
Definition: x11_platform.h:596
PFN_XPending Pending
Definition: x11_platform.h:577
PFN_XGetInputFocus GetInputFocus
Definition: x11_platform.h:556
struct _GLFWlibraryX11::@48 x11xcb
short int keycodes[256]
Definition: x11_platform.h:455
PFN_XCloseDisplay CloseDisplay
Definition: x11_platform.h:529
PFN_XVisualIDFromVisual VisualIDFromVisual
Definition: x11_platform.h:605
PFN_XMapRaised MapRaised
Definition: x11_platform.h:569
PFN_XDestroyRegion DestroyRegion
Definition: x11_platform.h:541
PFN_XcursorImageLoadCursor ImageLoadCursor
Definition: x11_platform.h:686
PFN_XGrabPointer GrabPointer
Definition: x11_platform.h:564
PFN_XRRGetCrtcInfo GetCrtcInfo
Definition: x11_platform.h:636
PFN_XCloseIM CloseIM
Definition: x11_platform.h:530
Atom NET_CURRENT_DESKTOP
Definition: x11_platform.h:487
Window helperWindowHandle
Definition: x11_platform.h:439
PFN_XGetEventData GetEventData
Definition: x11_platform.h:553
PFN_XSetWMProtocols SetWMProtocols
Definition: x11_platform.h:597
PFN_XRenderFindVisualFormat FindVisualFormat
Definition: x11_platform.h:739
PFN_XSetSelectionOwner SetSelectionOwner
Definition: x11_platform.h:594
PFN_XkbQueryExtension QueryExtension
Definition: x11_platform.h:663
PFN_XRRSetCrtcConfig SetCrtcConfig
Definition: x11_platform.h:643
PFN_XkbGetNames GetNames
Definition: x11_platform.h:660
PFN_XrmInitialize Initialize
Definition: x11_platform.h:616
PFN_XResizeWindow ResizeWindow
Definition: x11_platform.h:582
PFN_XFilterEvent FilterEvent
Definition: x11_platform.h:545
PFN_XRegisterIMInstantiateCallback RegisterIMInstantiateCallback
Definition: x11_platform.h:581
char * primarySelectionString
Definition: x11_platform.h:449
PFN_XLookupString LookupString
Definition: x11_platform.h:568
PFN_XineramaQueryScreens QueryScreens
Definition: x11_platform.h:699
PFN_XResourceManagerString ResourceManagerString
Definition: x11_platform.h:583
PFN_XkbKeycodeToKeysym KeycodeToKeysym
Definition: x11_platform.h:662
PFN_XRRSetCrtcGamma SetCrtcGamma
Definition: x11_platform.h:644
PFN_XChangeProperty ChangeProperty
Definition: x11_platform.h:525
PFN_XcursorGetTheme GetTheme
Definition: x11_platform.h:687
GLFWbool detectable
Definition: x11_platform.h:650
PFN_XPeekEvent PeekEvent
Definition: x11_platform.h:576
PFN_XInitThreads InitThreads
Definition: x11_platform.h:566
PFN_XCheckTypedWindowEvent CheckTypedWindowEvent
Definition: x11_platform.h:528
PFN_XIconifyWindow IconifyWindow
Definition: x11_platform.h:565
PFN_XGetKeyboardMapping GetKeyboardMapping
Definition: x11_platform.h:557
struct _GLFWlibraryX11::@51 xrender
PFN_XRRGetOutputPrimary GetOutputPrimary
Definition: x11_platform.h:638
double restoreCursorPosX
Definition: x11_platform.h:459
PFN_XMoveResizeWindow MoveResizeWindow
Definition: x11_platform.h:571
struct _GLFWlibraryX11::@43 xkb
PFN_XkbFreeKeyboard FreeKeyboard
Definition: x11_platform.h:657
PFN_XSync Sync
Definition: x11_platform.h:599
PFN_XrmDestroyDatabase DestroyDatabase
Definition: x11_platform.h:613
PFN_XFindContext FindContext
Definition: x11_platform.h:546
PFN_XcursorImageCreate ImageCreate
Definition: x11_platform.h:684
PFN_XF86VidModeGetGammaRampSize GetGammaRampSize
Definition: x11_platform.h:715
struct _GLFWlibraryX11::@50 xi
struct _GLFWlibraryX11::@45 xdnd
PFN_XShapeCombineMask ShapeCombineMask
Definition: x11_platform.h:752
PFN_XkbSetDetectableAutoRepeat SetDetectableAutoRepeat
Definition: x11_platform.h:665
PFN_XSupportsLocale SupportsLocale
Definition: x11_platform.h:598
PFN_XFreeCursor FreeCursor
Definition: x11_platform.h:550
PFN_XUnregisterIMInstantiateCallback UnregisterIMInstantiateCallback
Definition: x11_platform.h:607
PFN_XGetSelectionOwner GetSelectionOwner
Definition: x11_platform.h:559
PFN_XGetErrorText GetErrorText
Definition: x11_platform.h:552
PFN_XCreateWindow CreateWindow
Definition: x11_platform.h:536
PFN_XrmUniqueQuark UniqueQuark
Definition: x11_platform.h:617
PFN_XkbFreeNames FreeNames
Definition: x11_platform.h:658
PFN_XChangeWindowAttributes ChangeWindowAttributes
Definition: x11_platform.h:526
PFN_XkbGetMap GetMap
Definition: x11_platform.h:659
PFN_XTranslateCoordinates TranslateCoordinates
Definition: x11_platform.h:600
PFN_XSetIMValues SetIMValues
Definition: x11_platform.h:590
PFN_XGetXCBConnection GetXCBConnection
Definition: x11_platform.h:704
PFN_XSelectInput SelectInput
Definition: x11_platform.h:585
PFN_XSetClassHint SetClassHint
Definition: x11_platform.h:587
PFN_XDisplayKeycodes DisplayKeycodes
Definition: x11_platform.h:543
Atom NET_WM_STATE_MAXIMIZED_HORZ
Definition: x11_platform.h:480
PFN_XFreeEventData FreeEventData
Definition: x11_platform.h:551
PFN_XUndefineCursor UndefineCursor
Definition: x11_platform.h:601
PFN_XSetErrorHandler SetErrorHandler
Definition: x11_platform.h:588
PFN_XDestroyIC DestroyIC
Definition: x11_platform.h:540
GLFWbool monitorBroken
Definition: x11_platform.h:628
Atom NET_WM_WINDOW_OPACITY
Definition: x11_platform.h:484
PFN_XUngrabPointer UngrabPointer
Definition: x11_platform.h:602
PFN_XRRFreeScreenResources FreeScreenResources
Definition: x11_platform.h:633
struct _GLFWlibraryX11::@40 xlib
unsigned int group
Definition: x11_platform.h:656
Atom NET_REQUEST_FRAME_EXTENTS
Definition: x11_platform.h:490
PFN_XOpenIM OpenIM
Definition: x11_platform.h:575
PFN_XAllocSizeHints AllocSizeHints
Definition: x11_platform.h:523
PFN_XRRGetCrtcGammaSize GetCrtcGammaSize
Definition: x11_platform.h:635
Atom NET_WM_FULLSCREEN_MONITORS
Definition: x11_platform.h:483
PFN_XUnmapWindow UnmapWindow
Definition: x11_platform.h:603
PFN_XSetWMHints SetWMHints
Definition: x11_platform.h:595
PFN_XAllocClassHint AllocClassHint
Definition: x11_platform.h:522
XContext context
Definition: x11_platform.h:443
PFN_XUnsetICFocus UnsetICFocus
Definition: x11_platform.h:604
struct _GLFWlibraryX11::@47 xinerama
PFN_XRRFreeCrtcInfo FreeCrtcInfo
Definition: x11_platform.h:630
char * clipboardString
Definition: x11_platform.h:451
PFN_XShapeQueryExtension QueryExtension
Definition: x11_platform.h:749
double restoreCursorPosY
Definition: x11_platform.h:459
PFN_XcursorImageDestroy ImageDestroy
Definition: x11_platform.h:685
PFN_XWarpPointer WarpPointer
Definition: x11_platform.h:606
PFN_XConvertSelection ConvertSelection
Definition: x11_platform.h:531
PFN_XDestroyWindow DestroyWindow
Definition: x11_platform.h:542
PFN_XFree Free
Definition: x11_platform.h:548
struct _GLFWlibraryX11::@46 xcursor
Atom NET_WM_STATE_FULLSCREEN
Definition: x11_platform.h:478
struct _GLFWlibraryX11::@52 xshape
PFN_XF86VidModeSetGammaRamp SetGammaRamp
Definition: x11_platform.h:714
PFN_XRRAllocGamma AllocGamma
Definition: x11_platform.h:629
PFN_XGetICValues GetICValues
Definition: x11_platform.h:554
PFN_XAllocWMHints AllocWMHints
Definition: x11_platform.h:524
PFN_XRaiseWindow RaiseWindow
Definition: x11_platform.h:580
PFN_XGetVisualInfo GetVisualInfo
Definition: x11_platform.h:560
PFN_Xutf8LookupString utf8LookupString
Definition: x11_platform.h:608
PFN_XISelectEvents SelectEvents
Definition: x11_platform.h:727
Atom NET_WM_WINDOW_TYPE_NORMAL
Definition: x11_platform.h:475
struct _GLFWlibraryX11::@44 saver
Atom NET_WM_STATE_DEMANDS_ATTENTION
Definition: x11_platform.h:481
PFN_XSetICFocus SetICFocus
Definition: x11_platform.h:589
PFN_XMoveWindow MoveWindow
Definition: x11_platform.h:572
PFN_XEventsQueued EventsQueued
Definition: x11_platform.h:544
PFN_XkbGetState GetState
Definition: x11_platform.h:661
Display * display
Definition: x11_platform.h:432
PFN_XRRFreeOutputInfo FreeOutputInfo
Definition: x11_platform.h:632
PFN_XDeleteProperty DeleteProperty
Definition: x11_platform.h:539
Atom NET_WM_STATE_MAXIMIZED_VERT
Definition: x11_platform.h:479
PFN_XShapeCombineRegion ShapeCombineRegion
Definition: x11_platform.h:750
Cursor hiddenCursorHandle
Definition: x11_platform.h:441
PFN_XRRFreeGamma FreeGamma
Definition: x11_platform.h:631
PFN_XGetIMValues GetIMValues
Definition: x11_platform.h:555
PFN_XF86VidModeGetGammaRamp GetGammaRamp
Definition: x11_platform.h:713
PFN_XrmGetResource GetResource
Definition: x11_platform.h:614
PFN_XRRQueryExtension QueryExtension
Definition: x11_platform.h:640
PFN_XRRGetScreenResourcesCurrent GetScreenResourcesCurrent
Definition: x11_platform.h:639
GLFWbool gammaBroken
Definition: x11_platform.h:627
PFN_XRenderQueryExtension QueryExtension
Definition: x11_platform.h:737
PFN_XSendEvent SendEvent
Definition: x11_platform.h:586
GLFWbool transparent
Definition: x11_platform.h:411
GLFWbool iconified
Definition: x11_platform.h:407
Time keyPressTimes[256]
Definition: x11_platform.h:424
Colormap colormap
Definition: x11_platform.h:401
GLFWbool maximized
Definition: x11_platform.h:408
GLFWbool overrideRedirect
Definition: x11_platform.h:406
Image data.
Definition: glfw3.h:1855
Video mode type.
Definition: glfw3.h:1792
VkXcbSurfaceCreateFlagsKHR flags
Definition: x11_platform.h:367
xcb_connection_t * connection
Definition: x11_platform.h:368
VkXlibSurfaceCreateFlagsKHR flags
Definition: x11_platform.h:358
uint32_t VkFlags
Definition: vulkan.h:1688
VkResult
Definition: vulkan.h:842
uint32_t VkBool32
Definition: vulkan.h:1687
VkStructureType
Definition: vulkan.h:897
XSizeHints *(* PFN_XAllocSizeHints)(void)
Definition: x11_platform.h:55
XClassHint *(* PFN_XAllocClassHint)(void)
Definition: x11_platform.h:54
int(* PFN_Xutf8LookupString)(XIC, XKeyPressedEvent *, char *, int, KeySym *, Status *)
Definition: x11_platform.h:154
int(* PFN_XMoveWindow)(Display *, Window, int, int)
Definition: x11_platform.h:104
int(* PFN_XCloseDisplay)(Display *)
Definition: x11_platform.h:61
int(* PFN_XNextEvent)(Display *, XEvent *)
Definition: x11_platform.h:105
VkResult(APIENTRY * PFN_vkCreateXcbSurfaceKHR)(VkInstance, const VkXcbSurfaceCreateInfoKHR *, const VkAllocationCallbacks *, VkSurfaceKHR *)
Definition: x11_platform.h:374
XkbDescPtr(* PFN_XkbGetMap)(Display *, unsigned int, unsigned int)
Definition: x11_platform.h:141
int(* PFN_XUndefineCursor)(Display *, Window)
Definition: x11_platform.h:133
Status(* PFN_XkbGetNames)(Display *, unsigned int, XkbDescPtr)
Definition: x11_platform.h:142
int(* PFN_XRRUpdateConfiguration)(XEvent *)
Definition: x11_platform.h:275
int(* PFN_XSetSelectionOwner)(Display *, Atom, Window, Time)
Definition: x11_platform.h:126
int(* PFN_XGetErrorText)(Display *, int, char *, int)
Definition: x11_platform.h:84
int(* PFN_XFreeCursor)(Display *, Cursor)
Definition: x11_platform.h:82
Status(* PFN_XIQueryVersion)(Display *, int *, int *)
Definition: x11_platform.h:329
int(* PFN_XDefineCursor)(Display *, Window, Cursor)
Definition: x11_platform.h:69
int(* PFN_XResizeWindow)(Display *, Window, unsigned int, unsigned int)
Definition: x11_platform.h:114
int(* PFN_XSync)(Display *, Bool)
Definition: x11_platform.h:131
int(* PFN_XGetScreenSaver)(Display *, int *, int *, int *, int *)
Definition: x11_platform.h:90
XRRCrtcGamma *(* PFN_XRRAllocGamma)(int)
Definition: x11_platform.h:259
Region(* PFN_XCreateRegion)(void)
Definition: x11_platform.h:67
void _glfwInputErrorX11(int error, const char *message)
Definition: x11_init.c:1062
int(* PFN_XGetInputFocus)(Display *, Window *, int *)
Definition: x11_platform.h:88
Cursor(* PFN_XcursorImageLoadCursor)(Display *, const XcursorImage *)
Definition: x11_platform.h:296
char *(* PFN_XSetLocaleModifiers)(const char *)
Definition: x11_platform.h:124
int(* PFN_XcursorGetDefaultSize)(Display *)
Definition: x11_platform.h:298
void(* PFN_XRRFreeCrtcInfo)(XRRCrtcInfo *)
Definition: x11_platform.h:260
int(* PFN_XRaiseWindow)(Display *, Window)
Definition: x11_platform.h:112
void _glfwReleaseErrorHandlerX11(void)
Definition: x11_init.c:1053
Bool(* PFN_XGetEventData)(Display *, XGenericEventCookie *)
Definition: x11_platform.h:85
XcursorImage *(* PFN_XcursorLibraryLoadImage)(const char *, const char *, int)
Definition: x11_platform.h:299
Bool(* PFN_XRRQueryExtension)(Display *, int *, int *)
Definition: x11_platform.h:270
char *(* PFN_XResourceManagerString)(Display *)
Definition: x11_platform.h:115
void(* PFN_XShapeCombineRegion)(Display *, Window, int, int, int, Region, int)
Definition: x11_platform.h:343
int(* PFN_XRRGetCrtcGammaSize)(Display *, RRCrtc)
Definition: x11_platform.h:265
Status(* PFN_XSetWMProtocols)(Display *, Window, Atom *, int)
Definition: x11_platform.h:129
void(* PFN_XRRFreeOutputInfo)(XRROutputInfo *)
Definition: x11_platform.h:262
Status(* PFN_XGetWMNormalHints)(Display *, Window, XSizeHints *, long *)
Definition: x11_platform.h:93
int(* PFN_XDisplayKeycodes)(Display *, int *, int *)
Definition: x11_platform.h:75
XRRCrtcInfo *(* PFN_XRRGetCrtcInfo)(Display *, XRRScreenResources *, RRCrtc)
Definition: x11_platform.h:266
int(* PFN_XConvertSelection)(Display *, Atom, Atom, Atom, Window, Time)
Definition: x11_platform.h:63
Window(* PFN_XCreateWindow)(Display *, Window, int, int, unsigned int, unsigned int, unsigned int, int, unsigned int, Visual *, unsigned long, XSetWindowAttributes *)
Definition: x11_platform.h:68
Bool(* PFN_XRegisterIMInstantiateCallback)(Display *, void *, char *, char *, XIDProc, XPointer)
Definition: x11_platform.h:113
int(* PFN_XFree)(void *)
Definition: x11_platform.h:80
int(* PFN_XWarpPointer)(Display *, Window, Window, int, int, unsigned int, unsigned int, int, int)
Definition: x11_platform.h:138
void(* PFN_XRRSetCrtcGamma)(Display *, RRCrtc, XRRCrtcGamma *)
Definition: x11_platform.h:274
Bool(* PFN_XQueryExtension)(Display *, const char *, int *, int *, int *)
Definition: x11_platform.h:110
Bool(* PFN_XUnregisterIMInstantiateCallback)(Display *, void *, char *, char *, XIDProc, XPointer)
Definition: x11_platform.h:153
Bool(* PFN_XRenderQueryExtension)(Display *, int *, int *)
Definition: x11_platform.h:334
void(* PFN_XSetICFocus)(XIC)
Definition: x11_platform.h:121
XRenderPictFormat *(* PFN_XRenderFindVisualFormat)(Display *, Visual const *)
Definition: x11_platform.h:336
void(* PFN_XUnsetICFocus)(XIC)
Definition: x11_platform.h:136
Bool(* PFN_XF86VidModeSetGammaRamp)(Display *, int, int, unsigned short *, unsigned short *, unsigned short *)
Definition: x11_platform.h:322
void _glfwRestoreVideoModeX11(_GLFWmonitor *monitor)
Definition: x11_monitor.c:281
int(* PFN_XUnmapWindow)(Display *, Window)
Definition: x11_platform.h:135
Bool(* PFN_XFilterEvent)(XEvent *, Window)
Definition: x11_platform.h:77
void(* PFN_XRRFreeGamma)(XRRCrtcGamma *)
Definition: x11_platform.h:261
void(* PFN_XSetWMNormalHints)(Display *, Window, XSizeHints *)
Definition: x11_platform.h:128
int(* PFN_XUngrabPointer)(Display *, Time)
Definition: x11_platform.h:134
Window(* PFN_XGetSelectionOwner)(Display *, Atom)
Definition: x11_platform.h:91
Bool(* PFN_XrmGetResource)(XrmDatabase, const char *, const char *, char **, XrmValue *)
Definition: x11_platform.h:149
void(* PFN_XkbFreeNames)(XkbDescPtr, unsigned int, Bool)
Definition: x11_platform.h:140
RROutput(* PFN_XRRGetOutputPrimary)(Display *, Window)
Definition: x11_platform.h:268
xcb_connection_t *(* PFN_XGetXCBConnection)(Display *)
Definition: x11_platform.h:317
int(* PFN_XFindContext)(Display *, XID, XContext, XPointer *)
Definition: x11_platform.h:78
XRRScreenResources *(* PFN_XRRGetScreenResourcesCurrent)(Display *, Window)
Definition: x11_platform.h:269
XID xcb_window_t
Definition: x11_platform.h:314
int(* PFN_XFreeColormap)(Display *, Colormap)
Definition: x11_platform.h:81
int(* PFN_XSetWMHints)(Display *, Window, XWMHints *)
Definition: x11_platform.h:127
Bool(* PFN_XCheckTypedWindowEvent)(Display *, Window, int, XEvent *)
Definition: x11_platform.h:60
int(* PFN_XDestroyWindow)(Display *, Window)
Definition: x11_platform.h:74
int(* PFN_XDeleteContext)(Display *, XID, XContext)
Definition: x11_platform.h:70
int(* PFN_XGrabPointer)(Display *, Window, Bool, unsigned int, int, int, Window, Cursor, Time)
Definition: x11_platform.h:96
unsigned long _glfwGetWindowPropertyX11(Window window, Atom property, Atom type, unsigned char **value)
Definition: x11_window.c:1854
int(* PFN_XChangeWindowAttributes)(Display *, Window, unsigned long, XSetWindowAttributes *)
Definition: x11_platform.h:58
void(* PFN_XRRFreeScreenResources)(XRRScreenResources *)
Definition: x11_platform.h:263
int(* PFN_XMoveResizeWindow)(Display *, Window, int, int, unsigned int, unsigned int)
Definition: x11_platform.h:103
struct xcb_connection_t xcb_connection_t
Definition: x11_platform.h:316
Bool(* PFN_XSupportsLocale)(void)
Definition: x11_platform.h:130
XrmDatabase(* PFN_XrmGetStringDatabase)(const char *)
Definition: x11_platform.h:150
Status(* PFN_XRRSetCrtcConfig)(Display *, XRRScreenResources *, RRCrtc, Time, int, int, RRMode, Rotation, RROutput *, int)
Definition: x11_platform.h:273
XWMHints *(* PFN_XAllocWMHints)(void)
Definition: x11_platform.h:56
int(* PFN_XGetWindowProperty)(Display *, Window, Atom, long, long, Bool, Atom, Atom *, int *, unsigned long *, unsigned long *, unsigned char **)
Definition: x11_platform.h:95
Cursor(* PFN_XCreateFontCursor)(Display *, unsigned int)
Definition: x11_platform.h:65
int(* PFN_XDeleteProperty)(Display *, Window, Atom)
Definition: x11_platform.h:71
Bool(* PFN_XQueryPointer)(Display *, Window, Window *, Window *, int *, int *, int *, int *, unsigned int *)
Definition: x11_platform.h:111
void(* PFN_XDestroyIC)(XIC)
Definition: x11_platform.h:72
Status(* PFN_XShapeQueryVersion)(Display *dpy, int *, int *)
Definition: x11_platform.h:342
int(* PFN_XChangeProperty)(Display *, Window, Atom, Atom, int, int, const unsigned char *, int)
Definition: x11_platform.h:57
VkBool32(APIENTRY * PFN_vkGetPhysicalDeviceXlibPresentationSupportKHR)(VkPhysicalDevice, uint32_t, Display *, VisualID)
Definition: x11_platform.h:373
char *(* PFN_XSetIMValues)(XIM,...)
Definition: x11_platform.h:122
int(* PFN_XFlush)(Display *)
Definition: x11_platform.h:79
void(* PFN_XShapeCombineMask)(Display *, Window, int, int, int, Pixmap, int)
Definition: x11_platform.h:344
Bool(* PFN_XF86VidModeGetGammaRampSize)(Display *, int, int *)
Definition: x11_platform.h:323
VkBool32(APIENTRY * PFN_vkGetPhysicalDeviceXcbPresentationSupportKHR)(VkPhysicalDevice, uint32_t, xcb_connection_t *, xcb_visualid_t)
Definition: x11_platform.h:375
Status(* PFN_XCloseIM)(XIM)
Definition: x11_platform.h:62
XVisualInfo *(* PFN_XGetVisualInfo)(Display *, long, XVisualInfo *, int *)
Definition: x11_platform.h:92
int(* PFN_XLookupString)(XKeyEvent *, char *, int, KeySym *, XComposeStatus *)
Definition: x11_platform.h:100
void(* PFN_XrmInitialize)(void)
Definition: x11_platform.h:151
Bool(* PFN_XineramaIsActive)(Display *)
Definition: x11_platform.h:307
XrmQuark(* PFN_XrmUniqueQuark)(void)
Definition: x11_platform.h:152
VkFlags VkXcbSurfaceCreateFlagsKHR
Definition: x11_platform.h:352
VisualID(* PFN_XVisualIDFromVisual)(Visual *)
Definition: x11_platform.h:137
GLFWbool _glfwIsVisualTransparentX11(Visual *visual)
Definition: x11_window.c:1879
XRRCrtcGamma *(* PFN_XRRGetCrtcGamma)(Display *, RRCrtc)
Definition: x11_platform.h:264
Bool(* PFN_XkbSelectEventDetails)(Display *, unsigned int, unsigned int, unsigned long, unsigned long)
Definition: x11_platform.h:146
Status(* PFN_XInitThreads)(void)
Definition: x11_platform.h:98
void(* PFN_XRRSelectInput)(Display *, Window, int)
Definition: x11_platform.h:272
int(* PFN_XDestroyRegion)(Region)
Definition: x11_platform.h:73
void _glfwSetVideoModeX11(_GLFWmonitor *monitor, const GLFWvidmode *desired)
Definition: x11_monitor.c:227
int(* PFN_XSetInputFocus)(Display *, Window, int, Time)
Definition: x11_platform.h:123
Bool(* PFN_XTranslateCoordinates)(Display *, Window, Window, int, int, int *, int *, Window *)
Definition: x11_platform.h:132
XcursorImage *(* PFN_XcursorImageCreate)(int, int)
Definition: x11_platform.h:294
Bool(* PFN_XF86VidModeGetGammaRamp)(Display *, int, int, unsigned short *, unsigned short *, unsigned short *)
Definition: x11_platform.h:321
Status(* PFN_XkbGetState)(Display *, unsigned int, XkbStatePtr)
Definition: x11_platform.h:143
Bool(* PFN_XineramaQueryExtension)(Display *, int *, int *)
Definition: x11_platform.h:308
KeySym *(* PFN_XGetKeyboardMapping)(Display *, KeyCode, int, int *)
Definition: x11_platform.h:89
VkResult(APIENTRY * PFN_vkCreateXlibSurfaceKHR)(VkInstance, const VkXlibSurfaceCreateInfoKHR *, const VkAllocationCallbacks *, VkSurfaceKHR *)
Definition: x11_platform.h:372
int(* PFN_XMapWindow)(Display *, Window)
Definition: x11_platform.h:102
Bool(* PFN_XShapeQueryExtension)(Display *, int *, int *)
Definition: x11_platform.h:341
Bool(* PFN_XkbQueryExtension)(Display *, int *, int *, int *, int *, int *)
Definition: x11_platform.h:145
void _glfwGrabErrorHandlerX11(void)
Definition: x11_init.c:1045
int(* PFN_XPending)(Display *)
Definition: x11_platform.h:109
int(* PFN_XSetClassHint)(Display *, Window, XClassHint *)
Definition: x11_platform.h:119
XIC(* PFN_XCreateIC)(XIM,...)
Definition: x11_platform.h:66
VkFlags VkXlibSurfaceCreateFlagsKHR
Definition: x11_platform.h:351
char *(* PFN_XGetIMValues)(XIM,...)
Definition: x11_platform.h:87
Status(* PFN_XRRQueryVersion)(Display *, int *, int *)
Definition: x11_platform.h:271
KeySym(* PFN_XkbKeycodeToKeysym)(Display *, KeyCode, int, int)
Definition: x11_platform.h:144
char *(* PFN_XGetICValues)(XIC,...)
Definition: x11_platform.h:86
void _glfwCreateInputContextX11(_GLFWwindow *window)
Definition: x11_window.c:1936
void(* PFN_XFreeEventData)(Display *, XGenericEventCookie *)
Definition: x11_platform.h:83
Display *(* PFN_XOpenDisplay)(const char *)
Definition: x11_platform.h:106
void(* PFN_XrmDestroyDatabase)(XrmDatabase)
Definition: x11_platform.h:148
Bool(* PFN_XCheckIfEvent)(Display *, XEvent *, Bool(*)(Display *, XEvent *, XPointer), XPointer)
Definition: x11_platform.h:59
void(* PFN_Xutf8SetWMProperties)(Display *, Window, const char *, const char *, char **, int, XSizeHints *, XWMHints *, XClassHint *)
Definition: x11_platform.h:155
Cursor _glfwCreateCursorX11(const GLFWimage *image, int xhot, int yhot)
Definition: x11_init.c:1073
void _glfwPollMonitorsX11(void)
Definition: x11_monitor.c:101
Colormap(* PFN_XCreateColormap)(Display *, Window, Visual *, int)
Definition: x11_platform.h:64
XIM(* PFN_XOpenIM)(Display *, XrmDatabase *, char *, char *)
Definition: x11_platform.h:107
Status(* PFN_XSendEvent)(Display *, Window, Bool, long, XEvent *)
Definition: x11_platform.h:118
int(* PFN_XEventsQueued)(Display *, int)
Definition: x11_platform.h:76
int(* PFN_XPeekEvent)(Display *, XEvent *)
Definition: x11_platform.h:108
Status(* PFN_XIconifyWindow)(Display *, Window, int)
Definition: x11_platform.h:97
int(* PFN_XISelectEvents)(Display *, Window, XIEventMask *, int)
Definition: x11_platform.h:330
Bool(* PFN_XkbSetDetectableAutoRepeat)(Display *, Bool, Bool *)
Definition: x11_platform.h:147
XineramaScreenInfo *(* PFN_XineramaQueryScreens)(Display *, int *)
Definition: x11_platform.h:309
void _glfwPushSelectionToManagerX11(void)
Definition: x11_window.c:1890
XRROutputInfo *(* PFN_XRRGetOutputInfo)(Display *, XRRScreenResources *, RROutput)
Definition: x11_platform.h:267
int(* PFN_XSaveContext)(Display *, XID, XContext, const char *)
Definition: x11_platform.h:116
XErrorHandler(* PFN_XSetErrorHandler)(XErrorHandler)
Definition: x11_platform.h:120
void(* PFN_XkbFreeKeyboard)(XkbDescPtr, unsigned int, Bool)
Definition: x11_platform.h:139
char *(* PFN_XcursorGetTheme)(Display *)
Definition: x11_platform.h:297
Bool(* PFN_XF86VidModeQueryExtension)(Display *, int *, int *)
Definition: x11_platform.h:320
int(* PFN_XMapRaised)(Display *, Window)
Definition: x11_platform.h:101
int(* PFN_XSetScreenSaver)(Display *, int, int, int, int)
Definition: x11_platform.h:125
Status(* PFN_XGetWindowAttributes)(Display *, Window, XWindowAttributes *)
Definition: x11_platform.h:94
XID xcb_visualid_t
Definition: x11_platform.h:315
Atom(* PFN_XInternAtom)(Display *, const char *, Bool)
Definition: x11_platform.h:99
Status(* PFN_XRenderQueryVersion)(Display *dpy, int *, int *)
Definition: x11_platform.h:335
int(* PFN_XSelectInput)(Display *, Window, long)
Definition: x11_platform.h:117
void(* PFN_XcursorImageDestroy)(XcursorImage *)
Definition: x11_platform.h:295