[−][src]Struct termimad::MadSkin
A skin defining how a parsed mardkown appears on the terminal (fg and bg colors, bold, italic, underline, etc.)
Fields
paragraph: LineStyle
bold: CompoundStyle
italic: CompoundStyle
code: LineStyle
headers: [LineStyle; 8]
scrollbar: ScrollBarStyle
table_border: CompoundStyle
Methods
impl MadSkin
[src]
pub fn set_headers_fg(&mut self, c: Color)
[src]
pub fn set_headers_bg(&mut self, c: Color)
[src]
pub fn visible_composite_length(&self, composite: &Composite) -> usize
[src]
pub fn visible_line_length(&self, line: &Line) -> usize
[src]
pub fn inline<'k, 's>(&'k self, src: &'s str) -> FmtInline<'k, 's>
[src]
pub fn text<'k, 's>(
&'k self,
src: &'s str,
width: Option<usize>
) -> FmtText<'k, 's>
[src]
&'k self,
src: &'s str,
width: Option<usize>
) -> FmtText<'k, 's>
return a formatted text. Code blocs will be right justified
pub fn term_text<'k, 's>(&'k self, src: &'s str) -> FmtText<'k, 's>
[src]
return a formatted text, with lines wrapped or justified for the current terminal width. Code blocs will be right justified
pub fn area_text<'k, 's>(&'k self, src: &'s str, area: &Area) -> FmtText<'k, 's>
[src]
return a formatted text, with lines wrapped or justified for the passed area width (with space for a scrollbar). Code blocs will be right justified
pub fn print_inline(&self, src: &str)
[src]
pub fn print_text(&self, src: &str)
[src]
pub fn write_fmt_composite(
&self,
f: &mut Formatter,
fc: &FmtComposite,
outer_width: Option<usize>
) -> Result
[src]
&self,
f: &mut Formatter,
fc: &FmtComposite,
outer_width: Option<usize>
) -> Result
pub fn write_fmt_line(
&self,
f: &mut Formatter,
line: &FmtLine,
width: Option<usize>
) -> Result
[src]
&self,
f: &mut Formatter,
line: &FmtLine,
width: Option<usize>
) -> Result
Trait Implementations
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,