1
1
mirror of https://github.com/wez/wezterm.git synced 2024-12-23 13:21:38 +03:00

rename focus_change_repaint_delay -> x11_focus_change_repaint_delay_ms

and add changelog!

refs: #2111
This commit is contained in:
Wez Furlong 2022-06-15 20:46:54 -07:00
parent 4f015e66bc
commit 297377ae9a
5 changed files with 16 additions and 10 deletions

View File

@ -651,7 +651,7 @@ pub struct Config {
pub quote_dropped_files: DroppedFileQuoting,
#[dynamic(default = "default_focus_change_repaint_delay")]
pub focus_change_repaint_delay: u64,
pub x11_focus_change_repaint_delay_ms: u64,
}
impl_lua_conversion_dynamic!(Config);

View File

@ -84,6 +84,7 @@ As features stabilize some brief notes about them will accumulate here.
* Added [freetype_pcf_long_family_names](config/lua/config/freetype_pcf_long_family_names.md) option to workaround PCF font naming issues on certain Linux distributions. [#2100](https://github.com/wez/wezterm/issues/2100)
* X11/Wayland: wezterm.desktop now specifies `StartupWMClass`. Thanks to [@uncomfyhalomacro](https://github.com/uncomfyhalomacro)! [#2052](https://github.com/wez/wezterm/issues/2052) [#2125](https://github.com/wez/wezterm/pull/2125)
* `sudo -i` in a pane would cause subsequent pane/tab creation to fail until the cwd was changed to an accessible directory [#2120](https://github.com/wez/wezterm/issues/2120)
* X11: Add [x11_focus_change_repaint_delay_ms](config/lua/config/x11_focus_change_repaint_delay_ms.md) option to workaround NVIDIA specific window resize quirks. Thanks to [@pjones123](https://github.com/pjones123)! [#2111](https://github.com/wez/wezterm/pull/2111)
### 20220408-101518-b908e2dd

View File

@ -1,8 +0,0 @@
## `focus_change_repaint_delay = 100`
*Since: nightly builds only*
When not set to `0`, WezTerm will wait the specified delay (in milliseconds) before invalidating the geometry and repainting the window after losing or gaining focus.
Using the proprietry NVIDIA drivers and EGL rendering on X11, the `CONFIGURE_NOTIFY` event is sometimes missed. This workaround ensures that the window correctly resizes in these cases.

View File

@ -0,0 +1,13 @@
## `x11_focus_change_repaint_delay_ms = 100`
*Since: nightly builds only*
When set to a non-zero value, WezTerm will wait the specified delay (in
milliseconds) after losing or gaining focus. It will then invalidate the
geometry and focus state and repaint the window.
The purpose of this option is to workaround a quirk when using proprietry
NVIDIA drivers together with EGL under X11: the quirk causes `CONFIGURE_NOTIFY`
to sometimes be suppressed, and `FOCUS_IN` and `FOCUS_OUT` events to sometimes
contain erroneous focus state.

View File

@ -557,7 +557,7 @@ impl XWindowInner {
// the window a short time after the focus event is processed in the
// hope that it can observe the changed window properties and update
// without the human needing to interact with the window.
let delay = self.config.focus_change_repaint_delay;
let delay = self.config.x11_focus_change_repaint_delay_ms;
if delay != 0 {
let window_id = self.window_id;
promise::spawn::spawn(async move {