Table of Contents

Struct DragInfo

Namespace
Icy.Input.Gestures
Assembly
IcyUI.dll

Describes one step of a drag.

public readonly record struct DragInfo : IEquatable<DragInfo>
Implements
Inherited Members
Extension Methods

Constructors

DragInfo(PointerKind, Point, Point, Vector2, Vector2, bool)

Describes one step of a drag.

public DragInfo(PointerKind Kind, Point Start, Point Position, Vector2 Delta, Vector2 Velocity, bool StartedFromHold = false)

Parameters

Kind PointerKind

The pointer that drags.

Start Point

The position where the pointer was pressed, in physical pixels.

Position Point

The current pointer position, in physical pixels.

Delta Vector2

The movement since the previous drag event, in physical pixels.

Velocity Vector2

The release velocity in physical pixels per second - set on DragCompleted only, otherwise Zero.

StartedFromHold bool

true when the drag grew out of a press that had already raised Held (press-and-hold, then move) - the touch gesture that picks up drag-and-drop sources.

Properties

Delta

The movement since the previous drag event, in physical pixels.

public Vector2 Delta { get; init; }

Property Value

Vector2

Kind

The pointer that drags.

public PointerKind Kind { get; init; }

Property Value

PointerKind

Position

The current pointer position, in physical pixels.

public Point Position { get; init; }

Property Value

Point

Start

The position where the pointer was pressed, in physical pixels.

public Point Start { get; init; }

Property Value

Point

StartedFromHold

true when the drag grew out of a press that had already raised Held (press-and-hold, then move) - the touch gesture that picks up drag-and-drop sources.

public bool StartedFromHold { get; init; }

Property Value

bool

Velocity

The release velocity in physical pixels per second - set on DragCompleted only, otherwise Zero.

public Vector2 Velocity { get; init; }

Property Value

Vector2