mirror of
https://github.com/wez/wezterm.git
synced 2024-11-27 12:23:46 +03:00
f2cbc182cd
I thought it would be cute to add an option to add a background image to the window. While playing around with the parameters, I accidentally implemented window transparency on X11/Wayland, provided that you have a compositing window manager. I don't know of the transparency also works on macOS or Windows as of yet; will try that out once I push this commit. This commit introduces three new configuration options explained below. In the future I'd like to allow specifying equivalent settings in a color scheme, and then that would allow setting per-pane background images. ```lua return { --[[ Specifies the path to a background image attachment file. The file can be any image format that the rust `image` crate is able to identify and load. A window background image is rendered into the background of the window before any other content. The image will be scaled to fit the window. If the path is not absolute, then it will taken as being relative to the directory containing wezterm.lua. ]] window_background_image = "/some/file", --[[ Specifies the alpha value to use when rendering the background of the window. The background is taken either from the window_background_image, or if there is none, the background color of the cell in the current position. The default is 1.0 which is 100% opaque. Setting it to a number between 0.0 and 1.0 will allow for the screen behind the window to "shine through" to varying degrees. This only works on systems with a compositing window manager. Setting opacity to a value other than 1.0 can impact render performance. ]] window_background_opacity = 1.0, --[[ Specifies the alpha value to use when applying the default background color in a cell. This is useful to apply a kind of "tint" to the background image if either window_background_image or window_background_opacity are in used. It can be a number between 0.0 and 1.0. The default is 0.0 Larger numbers increase the amount of the color scheme's background color that is applied over the background image. This can be useful to increase effective contrast for text that is rendered over the top. ]] window_background_tint = 0.0, } ``` refs: https://github.com/wez/wezterm/issues/141 |
||
---|---|---|
.. | ||
src | ||
build.rs | ||
Cargo.toml |