Skip to main content

Module multi_click

Module multi_click 

Source
Expand description

Shared multi-click (single / double / triple) detection for the text editors.

TextField, TextArea and RichTextEdit all want the same “click again quickly to select more” behaviour: a first press positions the caret, a second selects the word, a third selects the line/paragraph/block. Rather than each widget re-deriving the timing gate, they share this tracker so the window and travel tolerance match each other — and match the Scene’s double-click reset (scene::DBL_CLICK_MS / MAX_CLICK_DIST).

Structs§

MultiClickTracker
Tracks consecutive mouse presses to distinguish single, double and triple clicks. One lives per text-editor widget instance.

Enums§

SelectGranularity
Granularity of an in-progress selection drag, decided by the click that began it. A double-click starts a Word drag (extends by whole words), a triple-click a Line drag; an ordinary press stays Char.