pub struct RcTextBuffer { /* private fields */ }
Implementations§
Source§impl RcTextBuffer
impl RcTextBuffer
pub fn new(text: &str, props: TextProperties, bounds_size: Size) -> Self
pub fn bounds_size(&self) -> Size
pub fn props<'a>(&'a self) -> Ref<'a, TextProperties>
Sourcepub fn measure(&self) -> Size
pub fn measure(&self) -> Size
The minimum size (in logical points) needed to fit the text contents.
pub fn set_text_and_props(&mut self, text: &str, props: TextProperties)
pub fn set_text(&mut self, text: &str)
Sourcepub fn set_bounds(&mut self, bounds_size: Size)
pub fn set_bounds(&mut self, bounds_size: Size)
Set the bounds of the text in logical points.
Trait Implementations§
Source§impl Clone for RcTextBuffer
impl Clone for RcTextBuffer
Source§impl Debug for RcTextBuffer
impl Debug for RcTextBuffer
Source§impl PartialEq for RcTextBuffer
impl PartialEq for RcTextBuffer
Auto Trait Implementations§
impl Freeze for RcTextBuffer
impl !RefUnwindSafe for RcTextBuffer
impl !Send for RcTextBuffer
impl !Sync for RcTextBuffer
impl Unpin for RcTextBuffer
impl !UnwindSafe for RcTextBuffer
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