pub struct TextFragment { /* private fields */ }Implementations§
Source§impl TextFragment
impl TextFragment
pub const fn range(&self) -> TextRange
pub fn text(&self) -> &str
pub const fn rect(&self) -> TextRect
pub const fn baseline(&self) -> Pt
pub const fn direction(&self) -> TextDirection
pub const fn script(&self) -> Script
pub const fn font(&self) -> &FontDescriptor
pub const fn font_size(&self) -> Pt
pub fn decorations(&self) -> &[TextDecoration]
pub const fn inserted_hyphen(&self) -> bool
pub const fn is_whitespace(&self) -> bool
Trait Implementations§
Source§impl Clone for TextFragment
impl Clone for TextFragment
Source§fn clone(&self) -> TextFragment
fn clone(&self) -> TextFragment
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for TextFragment
impl Debug for TextFragment
Source§impl PartialEq for TextFragment
impl PartialEq for TextFragment
Source§fn eq(&self, other: &TextFragment) -> bool
fn eq(&self, other: &TextFragment) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for TextFragment
Auto Trait Implementations§
impl Freeze for TextFragment
impl RefUnwindSafe for TextFragment
impl Send for TextFragment
impl Sync for TextFragment
impl Unpin for TextFragment
impl UnsafeUnpin for TextFragment
impl UnwindSafe for TextFragment
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more