Struct iced_graphics::text::editor::Editor
source · pub struct Editor(/* private fields */);
Expand description
A multi-line text editor.
Implementations§
Trait Implementations§
source§impl Editor for Editor
impl Editor for Editor
source§fn line(&self, index: usize) -> Option<&str>
fn line(&self, index: usize) -> Option<&str>
Returns the text of the given line in the
Editor
, if it exists.source§fn line_count(&self) -> usize
fn line_count(&self) -> usize
Returns the amount of lines in the
Editor
.source§fn cursor_position(&self) -> (usize, usize)
fn cursor_position(&self) -> (usize, usize)
source§fn min_bounds(&self) -> Size
fn min_bounds(&self) -> Size
Returns the minimum boundaries to fit the current contents of
the
Editor
.source§fn update(
&mut self,
new_bounds: Size,
new_font: Font,
new_size: Pixels,
new_line_height: LineHeight,
new_highlighter: &mut impl Highlighter
)
fn update( &mut self, new_bounds: Size, new_font: Font, new_size: Pixels, new_line_height: LineHeight, new_highlighter: &mut impl Highlighter )
Updates the
Editor
with some new attributes.source§impl PartialEq for Editor
impl PartialEq for Editor
impl StructuralPartialEq for Editor
Auto Trait Implementations§
impl RefUnwindSafe for Editor
impl Send for Editor
impl Sync for Editor
impl Unpin for Editor
impl UnwindSafe for Editor
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
§impl<T> Pointable for T
impl<T> Pointable for T
source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian()
.