keyboard topic
CategoryKeyboard
SDL keyboard management.
Please refer to the Best Keyboard Practices document for details on how best to accept keyboard input in various types of programs:
Functions
-
sdlClearComposition(
Pointer< keyboardSdlWindow> window) → bool - Dismiss the composition window/IME without disabling the subsystem.
-
sdlGetKeyboardFocus(
) → Pointer< keyboardSdlWindow> - Query the window which currently has keyboard focus.
-
sdlGetKeyboardNameForId(
int instanceId) → String? keyboard - Get the name of a keyboard.
-
sdlGetKeyboards(
Pointer< keyboardInt32> count) → Pointer<Uint32> - Get a list of currently connected keyboards.
-
sdlGetKeyboardState(
Pointer< keyboardInt32> numkeys) → Pointer<Uint8> - Get a snapshot of the current state of the keyboard.
-
sdlGetKeyFromName(
String? name) → int keyboard - Get a key code from a human-readable name.
-
sdlGetKeyFromScancode(
int scancode, int modstate, bool keyEvent) → int keyboard - Get the key code corresponding to the given scancode according to the current keyboard layout.
-
sdlGetKeyName(
int key) → String? keyboard - Get a human-readable name for a key.
-
sdlGetModState(
) → int keyboard - Get the current key modifier state for the keyboard.
-
sdlGetScancodeFromKey(
int key, Pointer< keyboardUint16> modstate) → int - Get the scancode corresponding to the given key code according to the current keyboard layout.
-
sdlGetScancodeFromName(
String? name) → int keyboard - Get a scancode from a human-readable name.
-
sdlGetScancodeName(
int scancode) → String? keyboard - Get a human-readable name for a scancode.
-
sdlGetTextInputArea(
Pointer< keyboardSdlWindow> window, Pointer<SdlRect> rect, Pointer<Int32> cursor) → bool - Get the area used to type Unicode text input.
-
sdlHasKeyboard(
) → bool keyboard - Return whether a keyboard is currently connected.
-
sdlHasScreenKeyboardSupport(
) → bool keyboard - Check whether the platform has screen keyboard support.
-
sdlResetKeyboard(
) → void keyboard - Clear the state of the keyboard.
-
sdlScreenKeyboardShown(
Pointer< keyboardSdlWindow> window) → bool - Check whether the screen keyboard is shown for given window.
-
sdlSetModState(
int modstate) → void keyboard - Set the current key modifier state for the keyboard.
-
sdlSetScancodeName(
int scancode, String? name) → bool keyboard - Set a human-readable name for a scancode.
-
sdlSetTextInputArea(
Pointer< keyboardSdlWindow> window, Pointer<SdlRect> rect, int cursor) → bool - Set the area used to type Unicode text input.
-
sdlStartTextInput(
Pointer< keyboardSdlWindow> window) → bool - Start accepting Unicode text input events in a window.
-
sdlStartTextInputWithProperties(
Pointer< keyboardSdlWindow> window, int props) → bool - Start accepting Unicode text input events in a window, with properties describing the input.
-
sdlStopTextInput(
Pointer< keyboardSdlWindow> window) → bool - Stop receiving any text input events in a window.
-
sdlTextInputActive(
Pointer< keyboardSdlWindow> window) → bool - Check whether or not Unicode text input events are enabled for a window.