Struct view::LineSegment
source · [−]pub struct LineSegment { /* private fields */ }
Expand description
Represents a segment in a larger line.
Implementations
sourceimpl LineSegment
impl LineSegment
sourcepub fn new_with_color(text: &str, color: DisplayColor) -> Self
pub fn new_with_color(text: &str, color: DisplayColor) -> Self
Create a new instance with added color.
sourcepub fn new_with_color_and_style(
text: &str,
color: DisplayColor,
dim: bool,
underline: bool,
reverse: bool
) -> Self
pub fn new_with_color_and_style(
text: &str,
color: DisplayColor,
dim: bool,
underline: bool,
reverse: bool
) -> Self
Create a new instance with added color and style.
Trait Implementations
sourceimpl Clone for LineSegment
impl Clone for LineSegment
sourcefn clone(&self) -> LineSegment
fn clone(&self) -> LineSegment
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for LineSegment
impl Debug for LineSegment
sourceimpl From<LineSegment> for ViewLine
impl From<LineSegment> for ViewLine
sourcefn from(line_segment: LineSegment) -> Self
fn from(line_segment: LineSegment) -> Self
Converts to this type from the input type.
Auto Trait Implementations
impl RefUnwindSafe for LineSegment
impl Send for LineSegment
impl Sync for LineSegment
impl Unpin for LineSegment
impl UnwindSafe for LineSegment
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more