[][src]Function conrod_core::text::cursor::xys_per_line_from_text

pub fn xys_per_line_from_text<'a>(
    text: &'a str,
    line_infos: &'a [Info],
    font: &'a Font,
    font_size: FontSize,
    x_align: Justify,
    y_align: Align,
    line_spacing: Scalar,
    rect: Rect
) -> XysPerLineFromText<'a>

Notable traits for XysPerLineFromText<'a>

impl<'a> Iterator for XysPerLineFromText<'a> type Item = (Xs<'a, 'a>, Range);

Similarly to xys_per_line, this produces an iterator yielding every possible cursor position within each line of text yielded by the given iterator.

Rather than taking an iterator yielding lines and their positioning data, this method constructs its own iterator to do so internally, saving some boilerplate involved in common xys_per_line use cases.

Yields (xs, y_range), where y_range is the Range occupied by the line across the y axis and xs is every possible cursor position along the x axis.