onKeyDown property

(void Function(int?)?) onKeyDown
getter/setter pair

Called whenever a key is downed and the editor is in rich text view.

This function will return the keycode for the downed key as an argument.

Note: The keycode is broken on Android, you will only ever receive 229, 8 (backspace), or 13 (enter) as a keycode. 8 and 13 only seem to be returned when the editor is empty and those keys are downed.

Implementation

void Function(int?)? onKeyDown;