* [PATCH installer] ui: gtk3: set up proper RGBA visual for main window
@ 2026-06-18 10:54 Christoph Heiss
2026-06-19 7:20 ` Maximiliano Sandoval
0 siblings, 1 reply; 2+ messages in thread
From: Christoph Heiss @ 2026-06-18 10:54 UTC (permalink / raw)
To: pve-devel
This properly fixes all instances of broken damage-tracking with dialogs
and other overlaying widgets on top of the WebKit2 view.
By using RGBA instead of a the default RGB visual, the GTK <-> X server
interaction for compositing widgets on top of each other seem to work
correctly.
This was previously worked around in one instance and thus also
effectively reverts commit
55c764163 ("gui: redraw window after closing disk setup dialog")
.. as it is now no longer needed.
Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
---
proxinstall | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/proxinstall b/proxinstall
index 49b1612..51ead26 100755
--- a/proxinstall
+++ b/proxinstall
@@ -236,6 +236,13 @@ sub create_main_window {
Proxmox::UI::init_gtk($gtk_state, $iso_env);
+ # make it play nice without a compositor, i.e. this enables proper damage
+ # tracking in GTK in combination with WebKit2
+ my $visual = $window->get_screen()->get_rgba_visual();
+ if ($visual) {
+ $window->set_visual($visual);
+ }
+
$window->show_all;
$window->present();
}
@@ -1651,7 +1658,6 @@ sub create_hdoption_view {
$dialog->show();
$dialog->run();
- $gtk_state->{window}->queue_draw();
my $get_float = sub {
my ($entry) = @_;
--
2.54.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH installer] ui: gtk3: set up proper RGBA visual for main window
2026-06-18 10:54 [PATCH installer] ui: gtk3: set up proper RGBA visual for main window Christoph Heiss
@ 2026-06-19 7:20 ` Maximiliano Sandoval
0 siblings, 0 replies; 2+ messages in thread
From: Maximiliano Sandoval @ 2026-06-19 7:20 UTC (permalink / raw)
To: Christoph Heiss; +Cc: pve-devel
Christoph Heiss <c.heiss@proxmox.com> writes:
> This properly fixes all instances of broken damage-tracking with dialogs
> and other overlaying widgets on top of the WebKit2 view.
>
> By using RGBA instead of a the default RGB visual, the GTK <-> X server
> interaction for compositing widgets on top of each other seem to work
> correctly.
>
> This was previously worked around in one instance and thus also
> effectively reverts commit
>
> 55c764163 ("gui: redraw window after closing disk setup dialog")
>
> .. as it is now no longer needed.
>
> Signed-off-by: Christoph Heiss <c.heiss@proxmox.com>
> ---
> proxinstall | 8 +++++++-
> 1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/proxinstall b/proxinstall
> index 49b1612..51ead26 100755
> --- a/proxinstall
> +++ b/proxinstall
> @@ -236,6 +236,13 @@ sub create_main_window {
>
> Proxmox::UI::init_gtk($gtk_state, $iso_env);
>
> + # make it play nice without a compositor, i.e. this enables proper damage
> + # tracking in GTK in combination with WebKit2
> + my $visual = $window->get_screen()->get_rgba_visual();
> + if ($visual) {
> + $window->set_visual($visual);
> + }
Very interesting find!
I booted a new VM using the latest iso where this issue was reproducible
and I can confirm that the patch works as expected. The patch fixes a
couple of edge cases (even on disk setup dialog) that were not fixed by
55c764163.
As a side note, while reviewing gtk source code, it seems that GtkWindow
will use RGBA visuals only if gtk_window_supports_client_shadow (which
on x11 boils down to whether the compositor supports the
_GTK_FRAME_EXTENTS hint) returns true.
Looks good to me.
Reviewed-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
Tested-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
--
Maximiliano
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-06-19 7:20 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-18 10:54 [PATCH installer] ui: gtk3: set up proper RGBA visual for main window Christoph Heiss
2026-06-19 7:20 ` Maximiliano Sandoval
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.