Struct html2text::render::text_renderer::BorderHoriz
source · pub struct BorderHoriz<T> {
pub segments: Vec<BorderSegHoriz>,
pub tag: T,
}
Expand description
A dividing line between table rows which tracks intersections with vertical lines.
Fields§
§segments: Vec<BorderSegHoriz>
The segments for the line.
tag: T
The tag associated with the lines
Implementations§
source§impl<T: Clone> BorderHoriz<T>
impl<T: Clone> BorderHoriz<T>
sourcepub fn new_type(width: usize, linetype: BorderSegHoriz, tag: T) -> Self
pub fn new_type(width: usize, linetype: BorderSegHoriz, tag: T) -> Self
Create a new blank border line.
sourcepub fn stretch_to(&mut self, width: usize)
pub fn stretch_to(&mut self, width: usize)
Stretch the line to at least the specified width
sourcepub fn join_above(&mut self, x: usize)
pub fn join_above(&mut self, x: usize)
Make a join to a line above at the xth cell
sourcepub fn join_below(&mut self, x: usize)
pub fn join_below(&mut self, x: usize)
Make a join to a line below at the xth cell
sourcepub fn merge_from_below(&mut self, other: &BorderHoriz<T>, pos: usize)
pub fn merge_from_below(&mut self, other: &BorderHoriz<T>, pos: usize)
Merge a (possibly partial) border line below into this one.
sourcepub fn merge_from_above(&mut self, other: &BorderHoriz<T>, pos: usize)
pub fn merge_from_above(&mut self, other: &BorderHoriz<T>, pos: usize)
Merge a (possibly partial) border line above into this one.
sourcepub fn to_vertical_lines_above(&self) -> String
pub fn to_vertical_lines_above(&self) -> String
Return a string of spaces and vertical lines which would match just above this line.
sourcepub fn into_string(self) -> String
pub fn into_string(self) -> String
Turn into a string with drawing characters
Trait Implementations§
source§impl<T: Clone> Clone for BorderHoriz<T>
impl<T: Clone> Clone for BorderHoriz<T>
source§fn clone(&self) -> BorderHoriz<T>
fn clone(&self) -> BorderHoriz<T>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl<T> Freeze for BorderHoriz<T>where
T: Freeze,
impl<T> RefUnwindSafe for BorderHoriz<T>where
T: RefUnwindSafe,
impl<T> Send for BorderHoriz<T>where
T: Send,
impl<T> Sync for BorderHoriz<T>where
T: Sync,
impl<T> Unpin for BorderHoriz<T>where
T: Unpin,
impl<T> UnwindSafe for BorderHoriz<T>where
T: UnwindSafe,
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