Skip to content

Commit 4c113cc

Browse files
committed
fix!: Rename Renderer::line_no to Renderer::line_num
Fixes #175
1 parent 1d802c3 commit 4c113cc

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

src/renderer/mod.rs

+4-4
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ impl Renderer {
101101
info: BRIGHT_BLUE.effects(Effects::BOLD),
102102
note: AnsiColor::BrightGreen.on_default().effects(Effects::BOLD),
103103
help: AnsiColor::BrightCyan.on_default().effects(Effects::BOLD),
104-
line_no: BRIGHT_BLUE.effects(Effects::BOLD),
104+
line_num: BRIGHT_BLUE.effects(Effects::BOLD),
105105
emphasis: if USE_WINDOWS_COLORS {
106106
AnsiColor::BrightWhite.on_default()
107107
} else {
@@ -178,8 +178,8 @@ impl Renderer {
178178
}
179179

180180
/// Set the output style for line numbers
181-
pub const fn line_no(mut self, style: Style) -> Self {
182-
self.stylesheet.line_no = style;
181+
pub const fn line_num(mut self, style: Style) -> Self {
182+
self.stylesheet.line_num = style;
183183
self
184184
}
185185

@@ -2665,7 +2665,7 @@ impl ElementStyle {
26652665
ElementStyle::Addition => stylesheet.addition,
26662666
ElementStyle::Removal => stylesheet.removal,
26672667
ElementStyle::LineAndColumn => stylesheet.none,
2668-
ElementStyle::LineNumber => stylesheet.line_no,
2668+
ElementStyle::LineNumber => stylesheet.line_num,
26692669
ElementStyle::Quotation => stylesheet.none,
26702670
ElementStyle::MainHeaderMsg => stylesheet.emphasis,
26712671
ElementStyle::UnderlinePrimary | ElementStyle::LabelPrimary => level.style(stylesheet),

src/renderer/stylesheet.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ pub(crate) struct Stylesheet {
77
pub(crate) info: Style,
88
pub(crate) note: Style,
99
pub(crate) help: Style,
10-
pub(crate) line_no: Style,
10+
pub(crate) line_num: Style,
1111
pub(crate) emphasis: Style,
1212
pub(crate) none: Style,
1313
pub(crate) context: Style,
@@ -29,7 +29,7 @@ impl Stylesheet {
2929
info: Style::new(),
3030
note: Style::new(),
3131
help: Style::new(),
32-
line_no: Style::new(),
32+
line_num: Style::new(),
3333
emphasis: Style::new(),
3434
none: Style::new(),
3535
context: Style::new(),

0 commit comments

Comments
 (0)