KDE Plasma 5.8 LTS doesn't render transparency effects

Bug #1636252 reported by X-Legs
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Onboard
Fix Committed
Low
Unassigned

Bug Description

After Onboard loads, the sections that should be transparent are statically rendered instead. This was not an issue in previous versions of Plasma 5. This is for version 1.3.0-1. Screenshot attached.

Notice how the left sidebar of the Onboard Preferences dialog is also rendered behind the right side of the keyboard. Hiding and reshowing the keyboard resets the background, but the background does not redraw when I move the keyboard.

Related branches

Revision history for this message
X-Legs (xlegs231) wrote :
Revision history for this message
marmuta (marmuta) wrote :

What distribution is this?

There was a change in Onboard in version 1.2 that dropped gtk_window_set_opacity() calls and did set_app_paintable(True) instead. Since then all transparency was handled by cairo drawing.
https://bazaar.launchpad.net/~onboard/onboard/trunk/revision/2036

This could very well be a bug in Plasma or even Gtk, but I'm wondering what happens if you enable the old override_background_color() calls at
https://bazaar.launchpad.net/~onboard/onboard/trunk/view/2180/Onboard/KbdWindow.py#L205

Could you
sudo gedit /usr/lib/python3/dist-packages/Onboard/KbdWindow.py
and replace line 204
             if gtk_version < Version(3, 18): # Xenial doesn't need them
with
             if True: #gtk_version < Version(3, 18): # Xenial doesn't need them
?

Revision history for this message
X-Legs (xlegs231) wrote : Re: [Bug 1636252] Re: KDE Plasma 5.8 LTS doesn't render transparency effects

>
> sudo vim /usr/lib/python3.5/site-packages/Onboard/KbdWindow.py

I'm running Manjaro -- a rolling release distro based on Arch. Changing the
file had no effect. FYI, the version of Cairo installed is:

> cairo 1.14.6-2

python2-cairo 1.10.0-6

My GTK is v3.22.1+67+gffb1ac5-1.

Stefan Zecevic
The little commuter in the big red scooter

On Tue, Oct 25, 2016 at 3:10 AM, marmuta <email address hidden> wrote:

> What distribution is this?
>
> There was a change in Onboard in version 1.2 that dropped
> gtk_window_set_opacity() calls and did set_app_paintable(True) instead.
> Since then all transparency was handled by cairo drawing.
> https://bazaar.launchpad.net/~onboard/onboard/trunk/revision/2036
>
> This could very well be a bug in Plasma or even Gtk, but I'm wondering
> what happens if you enable the old override_background_color() calls at
> https://bazaar.launchpad.net/~onboard/onboard/trunk/view/
> 2180/Onboard/KbdWindow.py#L205
>
> Could you
> sudo gedit /usr/lib/python3/dist-packages/Onboard/KbdWindow.py
> and replace line 204
> if gtk_version < Version(3, 18): # Xenial doesn't need them
> with
> if True: #gtk_version < Version(3, 18): # Xenial doesn't
> need them
> ?
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1636252
>
> Title:
> KDE Plasma 5.8 LTS doesn't render transparency effects
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/onboard/+bug/1636252/+subscriptions
>

Revision history for this message
marmuta (marmuta) wrote :

How does the floating icon look? It has transparency enabled independently of the keyboard.
Check Preferences->General->Show floating icon, then hide the keyboard.

Revision history for this message
X-Legs (xlegs231) wrote :

The floating icon looks good. When I move it, the background behind it is redrawn as expected.

Revision history for this message
marmuta (marmuta) wrote :

Can confirm on Arch with plasma-desktop 5.8.3-1. The floating icon transparency is fine, but the background behind the keyboard doesn't seem to get updated. No problem with Ubuntu's 5.7.5. This might be a kwin issue, but I'm not fully sure.

Changed in onboard:
status: New → Confirmed
importance: Undecided → Low
Revision history for this message
marmuta (marmuta) wrote :

So this is not a Plasma issue. Same thing happens in gnome-shell. It's caused by the git version of Gtk3 that Arch uses, 3.22.2+4+gc54f348-1 in my case. The people at Plasma IRC kindly pointed me in the right direction.

I've tracked it down to KeyboardWidget.get_xid(). What I think happens is that a native X window is being created inside this call, but isn't initialized properly for transparency. I've attached (Python) sample code that triggers the problem, i.e. the green rectangle ought to be transparent but isn't.

Two preconditions: the top level window must set accept_focus=False, and at any point get_xid() must be called on the GtkDrawingArea child. We can't change the former in Onboard, however there is a workaround for the latter:

Set
Preferences->Keyboard->Advanced->Input event source
to Gtk.

I believe a real fix has to come from Gtk. I'm going to file an upstream bug report, though I fully expect it to be ignored, as usual.

Revision history for this message
marmuta (marmuta) wrote :
Revision history for this message
marmuta (marmuta) wrote :

This bug has arrived in Ubuntu 17.04 with default unity7/compiz and libgtk-3-0 3.22.4.

Revision history for this message
marmuta (marmuta) wrote :

Finally found a workaround. Upstream bug is still there in Gtk 3.22.7, but it shouldn't affect Onboard anymore.

Changed in onboard:
status: Confirmed → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.