Bug 317066 - systray leaves garbage on the panel when resizing
Summary: systray leaves garbage on the panel when resizing
Status: RESOLVED FIXED
Alias: None
Product: plasma4
Classification: Plasma
Component: containment-panel (show other bugs)
Version: 4.10.1
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-03-20 07:48 UTC by Antonio Rojas
Modified: 2014-07-29 21:03 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
screenshot (12.93 KB, image/png)
2013-03-20 07:48 UTC, Antonio Rojas
Details
Panel configuration (8.39 KB, text/plain)
2013-04-15 20:52 UTC, Antonio Rojas
Details
Patch forcing qml to repaint the system tray applet on each resize event (645 bytes, patch)
2014-01-07 12:28 UTC, Dmitry Ivanov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Antonio Rojas 2013-03-20 07:48:17 UTC
When an icon is aded to the systray, part of it is drawn over the plasmoid immediately to its right. See attached screenshot: the systray arrow is drawn on top of the weather plasmoid

Reproducible: Always
Comment 1 Antonio Rojas 2013-03-20 07:48:50 UTC
Created attachment 78233 [details]
screenshot
Comment 2 Chao Feng 2013-04-14 13:59:23 UTC
I can not reproduce, could you give detailed steps.
Comment 3 Antonio Rojas 2013-04-15 20:52:19 UTC
Created attachment 78942 [details]
Panel configuration

No steps in particular, just add a panel with the attached configuration and wait for an icon to appear in the systray
Comment 4 Kai Uwe Broulik 2013-06-03 21:40:59 UTC
Confirmed. The new icon is added right of the plasmoid, overdrawing whatever there is, and then the entire plasmoid shifts to the left to make room for the new icon.
I guess that's probably because the item is added to the GridView and painted and then the plasmoid width is adjusted.
Comment 5 Michael D 2013-11-05 11:11:11 UTC
I have this issue all the time. I guess it's the result of tray icons (e.g. Kmail) that are set to auto visibility and appear/hide when needed. Clicking on the clock removes the tray arrow incorrectly painted on it.
Comment 6 Dmitry Ivanov 2014-01-07 12:28:47 UTC
Created attachment 84496 [details]
Patch forcing qml to repaint the system tray applet on each resize event

I seem to have found a fix for this bug, I verified it working well on both my laptop and PC. As Kai Uwe Broulik wrote, the plasmoid is not repainted as its width is adjusted after adding the new icon. I simply set viewport update mode to FullViewportUpdate to force repaint of things once anything gets dirty. 

I'm aware FullViewportUpdate implies worse performance, however, it leaves graphical glitches out and seems to work fast enough for me. I also tried BoundingRectViewportUpdate mode but it didn't help. I'm not sure this patch is suitable as "official" fix but I figured it won't be bad to just share it. 

This patch is for KDE/4.11 branch of kde-workspace repo.
Comment 7 Den 2014-02-11 14:57:00 UTC
*** This bug has been confirmed by popular vote. ***
Comment 8 Nikola Schnelle 2014-02-16 11:26:09 UTC
The easiest way to reproduce the bug is to open any video file with vlc player. Vlc icon pops up in system tray and than system tray leaves "garbage" arrow.
Comment 9 Marco Martin 2014-07-29 21:03:08 UTC
Git commit 3cdf85b5147382bf768d5b624ebf52a08748825b by Marco Martin.
Committed on 29/07/2014 at 21:01.
Pushed by mart into branch 'KDE/4.11'.

fix graphical glitch of xembed entries

Patch by Dmitry Ivanov
The fix is a very simple one-liner setting FullViewportUpdate mode for FdoGraphicsWidget. I'm aware FullViewportUpdate has negative performance impact but I also know it efficiently leaves out any graphical glitches happening due to no repaint of widget when necessary (which is what the bug is about).
REVIEW:114910

M  +13   -0    plasma/generic/applets/systemtray/protocols/fdo/fdographicswidget.cpp

http://commits.kde.org/kde-workspace/3cdf85b5147382bf768d5b624ebf52a08748825b