aboutsummaryrefslogtreecommitdiff
path: root/src/window.rs
diff options
context:
space:
mode:
authorGabriel Martinez <reitaka@gmail.com>2017-08-20 09:55:45 -0700
committerJoe Wilm <jwilm@users.noreply.github.com>2017-08-20 09:55:45 -0700
commit5009566ea5c46a85fa243b18ce4b7fe8e0b89b62 (patch)
treecc14c0de9686a52f0732a4a7ec29b5c23ea86efb /src/window.rs
parent4e9b1c590e8b0990f5f43fa9d7c53a31a92840a8 (diff)
downloadalacritty-5009566ea5c46a85fa243b18ce4b7fe8e0b89b62.tar.gz
alacritty-5009566ea5c46a85fa243b18ce4b7fe8e0b89b62.zip
Add background_opacity option to set terminal transparency (#331)
The option is an Alpha struct that ensures that the contained float is between 0.0 and 1.0. Background colors are multiplied by the opacity to properly alpha blend them.
Diffstat (limited to 'src/window.rs')
-rw-r--r--src/window.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/window.rs b/src/window.rs
index 83274f83..d5d35b8e 100644
--- a/src/window.rs
+++ b/src/window.rs
@@ -186,7 +186,8 @@ impl Window {
Window::platform_window_init();
let window = WindowBuilder::new()
- .with_title(title);
+ .with_title(title)
+ .with_transparency(true);
let context = ContextBuilder::new()
.with_vsync(true);
let window = ::glutin::GlWindow::new(window, context, &event_loop)?;