pub struct DiffStyles;
Expand description
Style presets for diff rendering
Implementations§
Source§impl DiffStyles
impl DiffStyles
Sourcepub fn file_header() -> Style
pub fn file_header() -> Style
File header style (bold blue)
Sourcepub fn stats_header() -> Style
pub fn stats_header() -> Style
Stats header style (bold magenta)
Sourcepub fn additions_count() -> Style
pub fn additions_count() -> Style
Additions count style (bold green)
Sourcepub fn deletions_count() -> Style
pub fn deletions_count() -> Style
Deletions count style (bold red)
Sourcepub fn changes_count() -> Style
pub fn changes_count() -> Style
Changes count style (bold yellow)
Sourcepub fn summary_header() -> Style
pub fn summary_header() -> Style
Summary header style (bold cyan)
Sourcepub fn added_line() -> Style
pub fn added_line() -> Style
Added line style (green)
Sourcepub fn removed_line() -> Style
pub fn removed_line() -> Style
Removed line style (red)
Sourcepub fn context_line() -> Style
pub fn context_line() -> Style
Context line style (dim white)
Sourcepub fn header_line() -> Style
pub fn header_line() -> Style
Header line style (bold blue)
Sourcepub fn apply_style(style: &Style, text: &str) -> String
pub fn apply_style(style: &Style, text: &str) -> String
Apply style to text
Auto Trait Implementations§
impl Freeze for DiffStyles
impl RefUnwindSafe for DiffStyles
impl Send for DiffStyles
impl Sync for DiffStyles
impl Unpin for DiffStyles
impl UnwindSafe for DiffStyles
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