Function nannou::text::cursor::closest_cursor_index_and_xy
source · pub fn closest_cursor_index_and_xy<'a, I>(
xy: Point,
xys_per_line: I
) -> Option<(Index, Point)>
Expand description
Find the closest cursor index to the given xy
position, and the center Point
of that
cursor.
Returns None
if the given text
is empty.