MCPcopy Create free account
hub / github.com/TheRedDeveloper/ply-engine / selection_anchor_raw

Method selection_anchor_raw

src/text_input.rs:1136–1138  ·  view source on GitHub ↗

Convert the visual selection_anchor to a raw position for rendering.

(&self)

Source from the content-addressed store, hash-verified

1134
1135 /// Convert the visual selection_anchor to a raw position for rendering.
1136 pub fn selection_anchor_raw(&self) -> Option<usize> {
1137 self.selection_anchor.map(|a| styling::cursor_to_raw(&self.text, a))
1138 }
1139
1140 /// Get the selection range in raw positions for rendering.
1141 pub fn selection_range_raw(&self) -> Option<(usize, usize)> {

Callers

nothing calls this directly

Calls 1

cursor_to_rawFunction · 0.85

Tested by

no test coverage detected