KeyPress(Interactive, Key, Int32, Nullable) Method

Definition

Assembly HeadlessTestingFramework.dll

Simulates a complete key press (down and up).

public void KeyPress(Interactive target, Key key, int holdTime = 50, KeyModifiers? modifiers = default(KeyModifiers? ))

Parameters

target
Avalonia.Interactivity.Interactive

The target control to receive the event.

key
Avalonia.Input.Key

The key to press.

holdTime
Int32

Time in milliseconds to hold the key.

modifiers
Nullable<KeyModifiers>

Optional key modifiers.