aboutsummaryrefslogtreecommitdiff
path: root/src/term/mod.rs
diff options
context:
space:
mode:
authorJoe Wilm <joe@jwilm.com>2017-02-06 13:28:33 -0800
committerJoe Wilm <jwilm@users.noreply.github.com>2017-02-11 14:18:05 -0800
commit2be3e8fc5b72698391423c5b10cf490211a8828a (patch)
tree886dcdd30293a2df243145caa40b3e5b118be98f /src/term/mod.rs
parent908ea5543a40b772d2336e2ce981aae61dc6b2d7 (diff)
downloadalacritty-2be3e8fc5b72698391423c5b10cf490211a8828a.tar.gz
alacritty-2be3e8fc5b72698391423c5b10cf490211a8828a.zip
Handle OSC for setting indexed color values
Resolves #26.
Diffstat (limited to 'src/term/mod.rs')
-rw-r--r--src/term/mod.rs10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/term/mod.rs b/src/term/mod.rs
index 3a86f887..a895d135 100644
--- a/src/term/mod.rs
+++ b/src/term/mod.rs
@@ -1335,6 +1335,16 @@ impl ansi::Handler for Term {
}
}
+ /// Set the indexed color value
+ ///
+ /// TODO needs access to `Config`, and `Config` should not overwrite values
+ /// when reloading
+ #[inline]
+ fn set_color(&mut self, index: usize, color: Rgb) {
+ trace!("set_color[{}] = {:?}", index, color);
+ self.colors[index] = color;
+ }
+
#[inline]
fn clear_screen(&mut self, mode: ansi::ClearMode) {
trace!("clear_screen: {:?}", mode);