From 52043d5f744b4544cceae98203138b7c2098c6cf Mon Sep 17 00:00:00 2001 From: Fraser Waters Date: Sat, 22 Feb 2014 12:54:11 +0000 Subject: [PATCH] Xcursor types. --- Source/OpenTK/Platform/X11/API.cs | 46 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/Source/OpenTK/Platform/X11/API.cs b/Source/OpenTK/Platform/X11/API.cs index dd7a5d2..2d488ab 100644 --- a/Source/OpenTK/Platform/X11/API.cs +++ b/Source/OpenTK/Platform/X11/API.cs @@ -38,6 +38,11 @@ namespace OpenTK.Platform.X11 using Display = System.IntPtr; using XPointer = System.IntPtr; + using XcursorBool = System.Int32; + using XcursorUInt = System.UInt32; + using XcursorDim = System.UInt32; + using XcursorPixel = System.UInt32; + // Randr and Xrandr using Bool = System.Boolean; using XRRScreenConfiguration = System.IntPtr; // opaque datatype @@ -579,6 +584,47 @@ XF86VidModeGetGammaRampSize( #region X11 Structures + #region Xcursor + + [StructLayout(LayoutKind.Sequential)] + unsafe struct XcursorImage + { + XcursorUInt version; + XcursorDim size; + XcursorDim width; + XcursorDim height; + XcursorDim xhot; + XcursorDim yhot; + XcursorUInt delay; + XcursorPixel* pixels; + } + + [StructLayout(LayoutKind.Sequential)] + unsafe struct XcursorImages + { + int nimage; + XcursorImage **images; + char *name; + } + + [StructLayout(LayoutKind.Sequential)] + unsafe struct XcursorCursors + { + Display *dpy; + int refcount; + int ncursor; + Cursor *cursors; + } + + [StructLayout(LayoutKind.Sequential)] + unsafe struct XcursorAnimate + { + XcursorCursors *cursors; + int sequence; + } + + #endregion + #region internal class XVisualInfo [StructLayout(LayoutKind.Sequential)] -- 2.7.4