mirror of
https://github.com/pimalaya/himalaya.git
synced 2026-06-17 05:07:55 +08:00
table: reset color after cell (#372)
Co-authored-by: Clément DOUIN <soywod@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
b7157573f2
commit
4d91a5d74e
+8
-1
@@ -134,7 +134,14 @@ impl Print for Cell {
|
||||
.context(format!(r#"cannot apply colors to cell "{}""#, self.value))?;
|
||||
|
||||
// Writes the colorized cell to stdout
|
||||
write!(writer, "{}", self.value).context(format!(r#"cannot print cell "{}""#, self.value))
|
||||
write!(writer, "{}", self.value)
|
||||
.context(format!(r#"cannot print cell "{}""#, self.value))?;
|
||||
|
||||
// Resets color after cell
|
||||
writer
|
||||
.reset()
|
||||
.context(format!(r#"cannot reset color in cell "{}""#, self.value))?;
|
||||
write!(writer, "").context(format!(r#"cannot print cell "{}""#, self.value))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user