klyn.gui.events.KeyEvent.KeyEvent
constructor

    public KeyEvent(source as Object, key as String, keyCode as Int, alt as Boolean = false, control as Boolean = false, shift as Boolean = false):

Description

Creates a keyboard event payload.

Parameters

Parameter | Description
--- | ---
`source` | Widget that received the keyboard event.
`key` | Textual key name when available.
`keyCode` | Native key code or keysym.
`alt` | Whether Alt was held.
`control` | Whether Control was held.
`shift` | Whether Shift was held.

Example

    event = KeyEvent(field, "Enter", 13)