Bug 334696 - File/directory icons/names move to the right when opening/refreshing contents of Dolphin
Summary: File/directory icons/names move to the right when opening/refreshing contents...
Status: RESOLVED FIXED
Alias: None
Product: dolphin
Classification: Applications
Component: view-engine: icons mode (show other bugs)
Version: 4.13.0
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Dolphin Bug Assignee
URL: http://www.youtube.com/watch?v=BcVNRD...
Keywords:
Depends on:
Blocks:
 
Reported: 2014-05-13 10:56 UTC by temporary987
Modified: 2014-05-30 09:11 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 4.13.2
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description temporary987 2014-05-13 10:56:40 UTC
When I open dolphin or refresh it's contents, sometimes this content moves to the right, which can be seen.
When it happens:
ONLY!!! if there is not enough space to display contents (a scrollbar appears)
ONLY!!! when this scrollbar is on the top
ONLY!!! when Oxygen is used as a KDE-style
ONLY!!! in "Icons" view mode
With antialising enabled/disabled, effects enabled/disabled, Oxygen animations enabled/disabled
On two different computers with different displays and both with Nouveau or Nvidia graphics driver 

Reproducible: Always

Steps to Reproduce:
1. Set Oxygen as a KDE style
2. Set "Icons" as a view mode in Dolphin
3. Open a directory with large amount of files (scrollbar must appear)
4. Refresh contents of this directory (F5, for example)
Actual Results:  
Content of the directory appears, and in a second it is all moved to the right by a couple of pixels.

Expected Results:  
Content of the directory appears and stays on its place.

I could see this bug in Kubuntu 14.04 amd64 livedvd, Ubuntu 14.04 with KDE built from mini.iso and in Gentoo.
Comment 1 Emmanuel Pescosta 2014-05-13 11:48:58 UTC
Thanks for the bug report, I can reproduce it.

Dolphin does the layouting twice (first without scrollbar then with scrollbar). I'll try to fix it when I have enough time. Maybe Frank has already a great idea how to solve it the right way (as usual). ;)
Comment 2 temporary987 2014-05-13 11:58:03 UTC
Thank you very much, I'm looking forward to the bugfix.
;)
Comment 3 Frank Reininghaus 2014-05-13 15:17:16 UTC
(In reply to comment #1)
> Maybe Frank has already a great idea how to solve it the right way (as usual). ;)

Unfortunately not :-(

My first idea would be to set a breakpoint in KItemListViewLayouter::doLayout to see where it's called from for the two different layouts, and/or add some debug output to find out more about the problem.
Comment 4 Thomas Lübking 2014-05-14 22:30:50 UTC
It also happens wit bespin & virtuality, but not plastique or skulpture

-> I bet everyones right arm that it's related to SH_ScrollView_FrameOnlyAroundContents returning false for those styles.
Comment 5 temporary987 2014-05-17 16:08:19 UTC
So Is it bug in Dolphin or in KDE Styles?
Comment 6 Emmanuel Pescosta 2014-05-19 10:33:18 UTC
(In reply to comment #5)
> So Is it bug in Dolphin or in KDE Styles?

No, the problem is in Dolphins layout handling.
Comment 7 Emmanuel Pescosta 2014-05-29 13:38:31 UTC
Git commit 098294f49ef61b2f93874f6d9dd3e43b7d6e2410 by Emmanuel Pescosta.
Committed on 25/05/2014 at 16:30.
Pushed by emmanuelp into branch 'KDE/4.13'.

Fix Bug 334696 - File/directory icons/names move to the right when opening/refreshing contents of Dolphin

Take the scrollbar spacing into account.
REVIEW: 118319
FIXED-IN: 4.13.2

M  +8    -2    dolphin/src/kitemviews/kitemlistview.cpp

http://commits.kde.org/kde-baseapps/098294f49ef61b2f93874f6d9dd3e43b7d6e2410
Comment 8 temporary987 2014-05-30 04:35:41 UTC
Thank you for fixing this bug! I have downloaded .diff, patched the sources and built a package. Now dolphin works fine!
Comment 9 Emmanuel Pescosta 2014-05-30 09:11:35 UTC
(In reply to comment #8)
> Thank you for fixing this bug! I have downloaded .diff, patched the sources
> and built a package. Now dolphin works fine!

You are welcome!
Thanks for testing the patch, always appreciated! :)