From 1ce23c079ec5d78f6b98e5a8e5aa5b115c4fc18f Mon Sep 17 00:00:00 2001 From: eifr Date: Wed, 5 Feb 2025 23:35:12 +0200 Subject: [PATCH] expand comment + rename --- src/apprt/gtk/App.zig | 4 +++- src/config/Config.zig | 15 ++++++++++++--- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/src/apprt/gtk/App.zig b/src/apprt/gtk/App.zig index c9096ee01..4781b0ac3 100644 --- a/src/apprt/gtk/App.zig +++ b/src/apprt/gtk/App.zig @@ -146,13 +146,15 @@ pub fn init(core_app: *CoreApp, opts: Options) !App { var gdk_disable: struct { @"gles-api": bool = false, + /// current gtk implementation for color management is not good enough. + /// see: https://bugs.kde.org/show_bug.cgi?id=495647 @"color-mgmt": bool, /// Disabling Vulkan can improve startup times by hundreds of /// milliseconds on some systems. We don't use Vulkan so we can just /// disable it. vulkan: bool = false, } = .{ - .@"color-mgmt" = config.@"disable-gtk-color-mgmt", + .@"color-mgmt" = config.@"gtk-gdk-disable-color-mgmt", }; environment: { diff --git a/src/config/Config.zig b/src/config/Config.zig index 52a1f2885..6d09fc9ce 100644 --- a/src/config/Config.zig +++ b/src/config/Config.zig @@ -1350,9 +1350,18 @@ keybind: Keybinds = .{}, /// Specified as either hex (`#RRGGBB` or `RRGGBB`) or a named X11 color. @"window-titlebar-foreground": ?Color = null, -/// current gtk implementation for color management is not good enough. -/// see: https://bugs.kde.org/show_bug.cgi?id=495647 -@"disable-gtk-color-mgmt": bool = false, +/// Controls whether to disable GDK color management in GTK applications. +/// +/// By default this is set to `false`, meaning color management is enabled. +/// You may want to enable this setting (set to `true`) if you experience: +/// - Incorrect or washed out colors in your terminal +/// - Color inconsistencies between GTK applications +/// - Performance issues related to color management +/// +/// This is a workaround for known issues with GTK's color management implementation, +/// particularly affecting applications running under Wayland. +/// See: https://bugs.kde.org/show_bug.cgi?id=495647 +@"gtk-gdk-disable-color-mgmt": bool = false, /// This controls when resize overlays are shown. Resize overlays are a /// transient popup that shows the size of the terminal while the surfaces are