chjj / compton

A compositor for X11.
Other
2.24k stars 502 forks source link

Tooltips artifacts with GTK+ 2 programs #399

Open equeim opened 7 years ago

equeim commented 7 years ago

Looks like this:

Happens not always, but quite often. Maybe other toolkits are also affected, but most of programs that I regularly use are GTK+ 2. Radeon R9 280X, Mesa drivers, xf86-video-ati with TearFree enabled. This doesn't happen if I disable compton or use another compositor. compton.conf:

backend = "glx"
paint-on-overlay = true
unredir-if-possible = true
glx-no-stencil = true
kn00tcn commented 7 years ago

which swap method? which compton vsync type?

given quite the history with radeon bugs in opengl, there's a chance it's a driver bug that may or may not be worked around with some tweak

edit: which gtk theme?

SammysHP commented 7 years ago

Also with gtk3. Happens with tooltips, context menu, sometimes even whole clients/screen areas.

backend = "glx";
paint-on-overlay = true;
glx-no-stencil = true;
glx-no-rebind-pixmap = true;
glx-swap-method = 1;

Happens also without glx-no-rebind-pixmap or paint-on-overlay and other glx-swap-method. So basically this is enough:

backend = "glx";

Radeon R7 260X xf86-video-ati (with default config) Arch Linux No DE, just awesome wm + compton

Started some months ago (at least since 22nd November), but I don't know with which version of X/video-ati/kernel exactly. Probably xorg-server 1.19.0 and xf86-video-ati 7.8.0.

edit: Does not happen with xrender and xr_glx_hybrid backend, but the latter creates sometimes flickering and delayed rendering (sometimes just the background is rendered).

Some examples:

kn00tcn commented 7 years ago

if a driver update broke compton which hasnt changed code in over 2 years, then... not much can be done other than trial & error of alternate gl modes or other tweaks

Efenstor commented 7 years ago

I've been struggling with this problem too for some time. My final solution was to use the xrender backend, disable vsync in Compton but instead turn it on in xorg.conf (see the ArchWiki pages on video cards for details).

My compton.conf (optimized for use with MATE):

backend = "xrender";
vsync = "none";

shadow = true;
no-dock-shadow = true;
no-dnd-shadow = true;
detect-rounded-corners = true;
shadow-exclude = "bounding_shaped && !rounded_corners";
shadow-opacity = 0.4;
fade-in-step = 0.1;
fade-out-step = 0.1;

wintypes:
{
    tooltip =
    {
        shadow = false;
        opacity = 0.85;
        focus = true;
        fade = true;
    };
};