Struct epaint::Galley [−][src]
A collection of text locked into place.
Fields
text: String
The full text, including any an all \n
.
rows: Vec<Row>
Rows of text, from top to bottom.
The number of chars in all rows sum up to text.chars().count().
Note that each paragraph (pieces of text separated with \n
)
can be split up into multiple rows.
size: Vec2
Implementations
impl Galley
[src]
pub fn sanity_check(&self)
[src]
impl Galley
[src]
pub fn pos_from_pcursor(&self, pcursor: PCursor) -> Rect
[src]
Returns a 0-width Rect.
pub fn pos_from_cursor(&self, cursor: &Cursor) -> Rect
[src]
Returns a 0-width Rect.
pub fn cursor_from_pos(&self, pos: Vec2) -> Cursor
[src]
Cursor at the given position within the galley
impl Galley
[src]
pub fn end(&self) -> Cursor
[src]
Cursor to one-past last character.
pub fn end_rcursor(&self) -> RCursor
[src]
impl Galley
[src]
pub fn from_ccursor(&self, ccursor: CCursor) -> Cursor
[src]
pub fn from_rcursor(&self, rcursor: RCursor) -> Cursor
[src]
pub fn from_pcursor(&self, pcursor: PCursor) -> Cursor
[src]
impl Galley
[src]
pub fn cursor_left_one_character(&self, cursor: &Cursor) -> Cursor
[src]
pub fn cursor_right_one_character(&self, cursor: &Cursor) -> Cursor
[src]
pub fn cursor_up_one_row(&self, cursor: &Cursor) -> Cursor
[src]
pub fn cursor_down_one_row(&self, cursor: &Cursor) -> Cursor
[src]
pub fn cursor_begin_of_row(&self, cursor: &Cursor) -> Cursor
[src]
pub fn cursor_end_of_row(&self, cursor: &Cursor) -> Cursor
[src]
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Galley
impl Send for Galley
impl Sync for Galley
impl Unpin for Galley
impl UnwindSafe for Galley
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,