Class Cursor
- Namespace
- Gdk
- Assembly
- Gdk-4.0.dll
public class Cursor : Object, IDisposable, NativeObject, GTypeProvider, InstanceFactory
- Inheritance
-
Cursor
- Implements
- Inherited Members
Constructors
Cursor(params ConstructArgument[])
[Obsolete("Regular C# constructors on native classes will be removed in a future version. Please see the linked documentation for more details. It contains scenarios and possible solutions to prepare for the upcoming changes.", DiagnosticId = "GirCore1007", UrlFormat = "https://gircore.github.io/docs/integration/diagnostic/1007.html")]
public Cursor(params ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]
Cursor(CreationData)
[Obsolete("This constructor is a workaround to keep legacy APIs alive. Do not use it.")]
protected Cursor(CreationData data)
Parameters
dataCreationData
Cursor(CursorHandle)
protected Cursor(CursorHandle handle)
Parameters
handleCursorHandle
Fields
FallbackPropertyDefinition
public static readonly Property<Cursor?, Cursor> FallbackPropertyDefinition
Field Value
HotspotXPropertyDefinition
public static readonly Property<int, Cursor> HotspotXPropertyDefinition
Field Value
HotspotYPropertyDefinition
public static readonly Property<int, Cursor> HotspotYPropertyDefinition
Field Value
NamePropertyDefinition
public static readonly Property<string?, Cursor> NamePropertyDefinition
Field Value
TexturePropertyDefinition
public static readonly Property<Texture?, Cursor> TexturePropertyDefinition
Field Value
Properties
Fallback
public Cursor? Fallback { get; }
Property Value
HotspotX
public int HotspotX { get; }
Property Value
HotspotY
public int HotspotY { get; }
Property Value
Name
public string? Name { get; }
Property Value
Texture
public Texture? Texture { get; }
Property Value
Methods
GetFallback()
public Cursor? GetFallback()
Returns
GetGType()
public static Type GetGType()
Returns
GetHotspotX()
public int GetHotspotX()
Returns
GetHotspotY()
public int GetHotspotY()
Returns
GetName()
public string? GetName()
Returns
GetTexture()
public Texture? GetTexture()
Returns
NewFromCallback(CursorGetTextureCallback, Cursor?)
[Version("4.16")]
public static Cursor? NewFromCallback(CursorGetTextureCallback callback, Cursor? fallback)
Parameters
callbackCursorGetTextureCallbackfallbackCursor
Returns
NewFromName(string, Cursor?)
public static Cursor? NewFromName(string name, Cursor? fallback)
Parameters
Returns
NewFromPointer(nint, bool)
Creates a new managed Cursor instance for a given pointer.
public static Cursor NewFromPointer(nint ptr, bool ownsHandle)
Parameters
Returns
NewFromTexture(Texture, int, int, Cursor?)
public static Cursor NewFromTexture(Texture texture, int hotspotX, int hotspotY, Cursor? fallback)
Parameters
Returns
NewWithProperties(ConstructArgument[])
Creates a new Cursor and sets the properties specified by the construct arguments.
public static Cursor NewWithProperties(ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]The properties to set.