Class MouseEvent
- Namespace
- MiniTui
- Assembly
- MiniTui.dll
A mouse report, delivered while WithMouse(bool) is on (1.x spec §4). X and
Y are 0-based cells, like Buffer coordinates.
public sealed record MouseEvent : Event, IEquatable<Event>, IEquatable<MouseEvent>
- Inheritance
-
MouseEvent
- Implements
- Inherited Members
Constructors
MouseEvent(MouseAction, MouseButton, int, int, ConsoleModifiers)
A mouse report, delivered while WithMouse(bool) is on (1.x spec §4). X and
Y are 0-based cells, like Buffer coordinates.
public MouseEvent(MouseAction Action, MouseButton Button, int X, int Y, ConsoleModifiers Modifiers = ConsoleModifiers.None)
Parameters
ActionMouseActionButtonMouseButtonXintYintModifiersConsoleModifiers
Properties
Action
public MouseAction Action { get; init; }
Property Value
Button
public MouseButton Button { get; init; }
Property Value
ClickCount
For a press: 1, or 2 and 3 for the second and third press of a double- or triple-click, counted by the app (1.x spec §17.3). 0 for other actions, and for presses the app hasn't counted.
public int ClickCount { get; init; }
Property Value
IsClick
True for a left-button press, the event clicks act on.
public bool IsClick { get; }
Property Value
Modifiers
public ConsoleModifiers Modifiers { get; init; }
Property Value
Position
The cell, as a Vec2.
public Vec2 Position { get; }
Property Value
X
public int X { get; init; }
Property Value
Y
public int Y { get; init; }