diff options
author | pierresy <pierre-henri.symoneaux@alcatel-lucent.com> | 2015-11-08 11:46:58 +0100 |
---|---|---|
committer | pierresy <pierre-henri.symoneaux@alcatel-lucent.com> | 2015-11-08 11:46:58 +0100 |
commit | 95d6db992e2816da0bd8173aacbde600e279d78d (patch) | |
tree | 8171f4c561a1b0d1f36709d44624d329522bc2ea /src/cell.rs | |
parent | 8d56043062880ca1b70e2d600deb6cbda393a3c2 (diff) |
#2 : Added a method to reset style on cells
Diffstat (limited to 'src/cell.rs')
-rw-r--r-- | src/cell.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/cell.rs b/src/cell.rs index c41e800..bfe78c5 100644 --- a/src/cell.rs +++ b/src/cell.rs @@ -60,6 +60,12 @@ impl Cell { return self;
}
+ /// Remove all style attributes and reset alignment to default (LEFT)
+ pub fn reset_style(&mut self) {
+ self.style.clear();
+ self.align(Align::LEFT);
+ }
+
pub fn style_spec(mut self, spec: &str) -> Cell {
let mut foreground = false;
let mut background = false;
|