net.kernelpanicsoft.archie.gui.modifiers.input¶
Types¶
BasicPointerEvent¶
class BasicPointerEvent(
type: PointerEventType,
mouseX: Double,
mouseY: Double
) : PointerEvent
A basic pointer event carrying position and type information.
CharEvent¶
data class CharEvent(val codePoint: Char, val modifiers: Int) : InputEvent
An event generated when a printable character is typed.
DragEvent¶
class DragEvent(
type: PointerEventType = PointerEventType.DRAG,
mouseX: Double,
mouseY: Double,
val button: Int,
val dragX: Double,
val dragY: Double
) : PointerEvent
A pointer event generated by click-dragging the mouse.
InputEvent¶
sealed class InputEvent
Base class for all events dispatched through the composable input system.
KeyEvent¶
data class KeyEvent(
val keyCode: Int,
val scanCode: Int,
val modifiers: Int
) : InputEvent
An event generated by a keyboard key press.
OnCharTypedModifier¶
data class OnCharTypedModifier(val onEvent: (AUINode, CharEvent) -> Unit) : Modifier.Element<OnCharTypedModifier>
A Modifier.Element that registers a character-typed handler on a composable node.
OnKeyEventModifier¶
data class OnKeyEventModifier(val onEvent: (AUINode, KeyEvent) -> Unit) : Modifier.Element<OnKeyEventModifier>
A Modifier.Element that registers a keyboard key-press handler on a composable node.
OnPointerEventModifier¶
data class OnPointerEventModifier<T : AUINode>(val eventType: PointerEventType, val onEvent: (T, PointerEvent) -> Unit) : Modifier.Element<OnPointerEventModifier<*>>
A Modifier.Element that registers a callback for a specific PointerEventType.
PointerEvent¶
sealed class PointerEvent : InputEvent
Base class for all pointer (mouse) events.
PointerEventType¶
enum PointerEventType : Enum<PointerEventType>
Identifies the type of pointer (mouse) interaction that triggers an event handler.
ScrollEvent¶
class ScrollEvent(
type: PointerEventType = PointerEventType.SCROLL,
mouseX: Double,
mouseY: Double,
val scrollX: Double,
val scrollY: Double
) : PointerEvent
A pointer event generated by mouse wheel movement.
Properties¶
DOUBLE_CLICK_THRESHOLD¶
const val DOUBLE_CLICK_THRESHOLD: Int = 300
Milliseconds within which two successive presses qualify as a double-click.
LONG_CLICK_THRESHOLD¶
const val LONG_CLICK_THRESHOLD: Int = 500
Milliseconds a press must be held to qualify as a long-click.