Mouse and Keyboard

  Edit on GitHub

LittleKt supports input for the mouse on desktop and browser and the keyboard.

Mouse

The mouse input supports reporting the location of the current pointer as 2D coordinates relative to the origin of the upper left corner of the screen.

Mouse input also allows to determine if the left, right, or middle mouse buttons were pressed. As well as handling scrolling.

Mouse inputs can be polled or processed via events.

Keyboard

LittleKt comes with its own key-code table (source) which handles handling all the different key-codes on each platform. Key-code presses and releases can be queried via polling as able to be processed via generated events.