SourceClass TextCursorState
from egui import TextCursorStateclass TextCursorState:The state of a text cursor selection.
Used for egui.TextEdit and egui.Label.
Methods§
Sourcedef char_range(self, /) -> CCursorRange |None§
The currently selected range of characters.
@staticmethod
def default() -> TextCursorState§
Sourcedef is_empty(self, /) -> bool§
Sourcedef pointer_interaction(self, /, ui: Ui, response: Response, cursor_at_pointer: CCursor, galley: Galley, is_being_dragged: bool) -> bool§
Handle clicking and/or dragging text.
Returns True if there was interaction.
Sourcedef range(self, /, galley: Galley) -> CCursorRange |None§
The currently selected range of characters, clamped within the character
range of the given Galley.
Sourcedef set_char_range(self, /, range: CCursorRange |None) -> None§
Sets the currently selected range of characters.