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

  • key - The key that is being held down and repeating, such as ARROW_DOWN or BACKSPACE.
  • physical_key - The position of the key being held down on the keyboard, such as W, whatever the active layout.

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_keyinstance-attribute​

physical_key: PhysicalKeyboardKey | int

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

A key that has no PhysicalKeyboardKey member is its USB HID usage code.