Class DrawContext
- Namespace
- Gdk
- Assembly
- Gdk-4.0.dll
public class DrawContext : Object, IDisposable, NativeObject, GTypeProvider, InstanceFactory
- Inheritance
-
DrawContext
- Implements
- Derived
- Inherited Members
Constructors
DrawContext(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 DrawContext(params ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]
DrawContext(CreationData)
[Obsolete("This constructor is a workaround to keep legacy APIs alive. Do not use it.")]
protected DrawContext(CreationData data)
Parameters
dataCreationData
DrawContext(DrawContextHandle)
protected DrawContext(DrawContextHandle handle)
Parameters
handleDrawContextHandle
Fields
DisplayPropertyDefinition
public static readonly Property<Display?, DrawContext> DisplayPropertyDefinition
Field Value
SurfacePropertyDefinition
public static readonly Property<Surface?, DrawContext> SurfacePropertyDefinition
Field Value
Properties
Display
public Display? Display { get; }
Property Value
Surface
public Surface? Surface { get; }
Property Value
Methods
BeginFrame(Region)
public void BeginFrame(Region region)
Parameters
regionRegion
EndFrame()
public void EndFrame()
GetDisplay()
public Display? GetDisplay()
Returns
GetFrameRegion()
public Region? GetFrameRegion()
Returns
GetGType()
public static Type GetGType()
Returns
GetSurface()
public Surface? GetSurface()
Returns
IsInFrame()
public bool IsInFrame()
Returns
NewFromPointer(nint, bool)
Creates a new managed DrawContext instance for a given pointer.
public static DrawContext NewFromPointer(nint ptr, bool ownsHandle)
Parameters
Returns
NewWithProperties(ConstructArgument[])
Creates a new DrawContext and sets the properties specified by the construct arguments.
public static DrawContext NewWithProperties(ConstructArgument[] constructArguments)
Parameters
constructArgumentsConstructArgument[]The properties to set.