In This Article

IUIControl Interface

Represents base requirements for a custom user interface control.

public interface IUIControl : IUIElement, ILogicalTreeNode, IDpiAwareElement, IDisposable

Properties

Capture

Gets or sets a value indicating whether the control has captured the mouse.

bool Capture { get; set; }

Property Value

bool:

true if the control has captured the mouse; otherwise, false.

IsPaintValid

Gets whether the control has rendered itself and doesn't have any invalidated paint regions.

bool IsPaintValid { get; }

Property Value

bool:

true if the control has rendered itself and doesn't have any invalidated paint regions; otherwise, false.

MouseCaptureElement

Indicates the IUIElement for which mouse capture is being performed.

IUIElement MouseCaptureElement { get; set; }

Property Value

IUIElement:

The IUIElement for which mouse capture is being performed.

Methods

AddPendingGraphicsInversion(Rectangle)

Inverts the canvas using XOR at the end of the current or next drawing operation.

bool AddPendingGraphicsInversion(Rectangle bounds)
Parameter Type Description
bounds Rectangle

A Rectangle specifying the bounds to invert.

Returns

bool:

true if the inversion operation was added successfully; otherwise, false.

AddPendingScrollOperation(Rectangle, int, int)

Scrolls the canvas the specified amount at the beginning of the next drawing operation.

bool AddPendingScrollOperation(Rectangle bounds, int xAmount, int yAmount)
Parameter Type Description
bounds Rectangle

The bounds to scroll.

xAmount int

The amount to scroll horizontally.

yAmount int

The amount to scroll vertically.

Returns

bool:

true if the scroll operation was added successfully; otherwise, false.

AddPendingScrollOperation(Rectangle, Orientation, int)

Scrolls the canvas the specified amount at the beginning of the next drawing operation.

bool AddPendingScrollOperation(Rectangle bounds, Orientation orientation, int amount)
Parameter Type Description
bounds Rectangle

The bounds to scroll.

orientation Orientation

The direction to scroll.

amount int

The amount to scroll.

Returns

bool:

true if the scroll operation was added successfully; otherwise, false.

AddToInvalidatedRegion(Rectangle)

Adds a Rectangle to the invalidated region.

void AddToInvalidatedRegion(Rectangle rect)
Parameter Type Description
rect Rectangle

The Rectangle to add to the invalidated region.

ResetDoubleBufferCanvas(bool)

Resets the double-buffer canvas.

void ResetDoubleBufferCanvas(bool recurse)
Parameter Type Description
recurse bool

Whether to recurse down into the child control tree.

Inherited Members

Extension Methods