Enum conrod::text::line::Break [] [src]

pub enum Break {
    Wrap {
        byte: usize,
        char: usize,
        len_bytes: usize,
    },
    Newline {
        byte: usize,
        char: usize,
        len_bytes: usize,
    },
    End {
        byte: usize,
        char: usize,
    },
}

The two types of Break indices returned by the WrapIndicesBy iterators.

Variants

A break caused by the text exceeding some maximum width.

Fields of Wrap

The byte index at which the break occurs.

The char index at which the string should wrap due to exceeding a maximum width.

The byte length which should be skipped in order to reach the first non-whitespace character to use as the beginning of the next line.

A break caused by a newline character.

Fields of Newline

The byte index at which the string should wrap due to exceeding a maximum width.

The char index at which the string should wrap due to exceeding a maximum width.

The width of the "newline" token in bytes.

The end of the string has been reached, with the given length.

Fields of End

The ending byte index.

The ending char index.

Methods

impl Break
[src]

[src]

Return the index at which the break occurs.

[src]

Return the index of the char at which the break occurs.

To clarify, this index is to be used in relation to the Chars iterator.

Trait Implementations

impl Copy for Break
[src]

impl Clone for Break
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for Break
[src]

[src]

Formats the value using the given formatter.

impl PartialEq for Break
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.