Skip to main content

KeyRepeatEvent

Event triggered when a key is held down and repeating.

This event fires continuously while the key remains pressed, depending on the system's key repeat rate.

Inherits: Event

Properties

Properties​

keyinstance-attribute​

key: KeyboardKey | str

The key that is being held down and repeating, such as ARROW_DOWN or BACKSPACE.

A key that has no KeyboardKey member is a plain string, such as "Ü".

physical_keyclass-attributeinstance-attribute​

physical_key: PhysicalKeyboardKey | int | None = None

The position of the key being held down on the keyboard, such as PhysicalKeyboardKey.W, whatever the active layout.

A key that has no PhysicalKeyboardKey member is its USB HID usage code. Older clients that omit the physical key leave this as None.