Bug 352641 - scrollbar mini-map not working anymore
Summary: scrollbar mini-map not working anymore
Status: RESOLVED FIXED
Alias: None
Product: frameworks-ktexteditor
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: Other Linux
: HI normal
Target Milestone: ---
Assignee: Kåre Särs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-13 07:02 UTC by Markus Trippelsdorf
Modified: 2015-09-15 19:19 UTC (History)
2 users (show)

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


Attachments
bad screenshot (624.46 KB, image/png)
2015-09-13 07:03 UTC, Markus Trippelsdorf
Details
good screenshot (670.76 KB, image/png)
2015-09-13 07:04 UTC, Markus Trippelsdorf
Details
This is how it looks for me (101.56 KB, image/png)
2015-09-15 05:47 UTC, Kåre Särs
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Markus Trippelsdorf 2015-09-13 07:02:54 UTC
Since the update to Frameworks 5.14.0 the scrollbar mini-map is unusable,
because it not possible to tell anymore which part of the document is currently displayed.
See attached screenshots.

Reproducible: Always
Comment 1 Markus Trippelsdorf 2015-09-13 07:03:45 UTC
Created attachment 94527 [details]
bad screenshot
Comment 2 Markus Trippelsdorf 2015-09-13 07:04:07 UTC
Created attachment 94528 [details]
good screenshot
Comment 3 Kevin Funk 2015-09-14 16:58:50 UTC
Looks like a bug in ktexteditor -- moved the issue.

@KTE people, can you make sense out of this?
Comment 4 Kåre Särs 2015-09-14 21:14:29 UTC
Hmm..

Marcus: It looks like the pallet that you are using has the same or almost the same color for text background and highlight... Can You confirm this? or is there something else?

We may have to think about using another palette color for the scrollbar handle...
Comment 5 Markus Trippelsdorf 2015-09-15 03:23:34 UTC
(In reply to Kåre Särs from comment #4)
> Hmm..
> 
> Marcus: It looks like the pallet that you are using has the same or almost
> the same color for text background and highlight... Can You confirm this? or
> is there something else?

It happens with every colorscheme. And, as I wrote, it worked fine before with Frameworks 5.13.0.
So something must have changed with 5.14.0. that introduced the bug.
Comment 6 Kåre Särs 2015-09-15 05:47:00 UTC
Created attachment 94572 [details]
This is how it looks for me

Are you using distro packages or self compiled? If distro what distro?

As you can see from my screenshot it works OK here... Kubuntu 15.04 with self compiled master of Ktexteditor and Kate

Are you able to help by compiling and debugging the issue?
Comment 7 Markus Trippelsdorf 2015-09-15 06:38:14 UTC
(In reply to Kåre Särs from comment #6)
> Created attachment 94572 [details]
> This is how it looks for me
> 
> Are you using distro packages or self compiled? If distro what distro?
> 
> As you can see from my screenshot it works OK here... Kubuntu 15.04 with
> self compiled master of Ktexteditor and Kate
> 
> Are you able to help by compiling and debugging the issue?

Yes. I'm running Gentoo, so everything is self compiled...
Comment 8 Markus Trippelsdorf 2015-09-15 06:52:07 UTC
Just to confirm. Bug happens when I compile and use ktexteditor-5.14.0.
With ktexteditor-5.13.0 everything is fine again. 
Configuration is identical in both cases.
Comment 9 Markus Trippelsdorf 2015-09-15 07:04:01 UTC
Started with:
commit 9c0df13721838c2e395f94c413529d170ef96163
Author: Emmanuel Lepage Vallee <elv1313@gmail.com>
Date:   Wed Aug 19 10:26:34 2015 +0300

    minimap: Attempt to improve the look and feel
    
    This patch attempt to make the minimap look better.
    
    * The design has been reviewed during Akademy
    * It now feel "native" in the canvas for both Breeze and Fusion
      styles. Oxygen has some hardcoded extra borders, this is a
      known limitation of this patch.
    * Improve support for darker themes. The previous implementation
      failed to properly display the visible area
    * Partially degrade the visible section view when the handle is
      at its minimum height. This could be improved later on.
    
    BUG: 309553

Reverting the commit above fixes the issue.
Comment 10 Kåre Särs 2015-09-15 07:51:11 UTC
Can you in stead of reverting the commit change src/view/kateviewhelpers.cpp: line 513 from:

    const QColor highlightColor  = palette().highlight().color();
to
    const QColor highlightColor  = QColor("black");
or
    const QColor highlightColor  = palette().link().color();

Then you should get a scrollbar handle ;)
Comment 11 Markus Trippelsdorf 2015-09-15 08:02:42 UTC
(In reply to Kåre Särs from comment #10)
> Can you in stead of reverting the commit change
> src/view/kateviewhelpers.cpp: line 513 from:
> 
>     const QColor highlightColor  = palette().highlight().color();
> to
>     const QColor highlightColor  = QColor("black");
> or
>     const QColor highlightColor  = palette().link().color();
> 
> Then you should get a scrollbar handle ;)

Nope. Unfortunately it doesn't change anything at all.
Comment 12 Markus Trippelsdorf 2015-09-15 08:12:26 UTC
Forgot to mention that I don't use the compositor.
Comment 13 Kåre Särs 2015-09-15 08:54:43 UTC
Found the issue... Enable scrollbar marks and it should work.
Comment 14 Kåre Särs 2015-09-15 19:19:11 UTC
Git commit ab177b97e57f8eaae10e27c5bbb00cfa8b30c6d4 by Kåre Särs.
Committed on 15/09/2015 at 19:12.
Pushed by sars into branch 'master'.

minimap: Fix scrollbar handle not being drawn with scrollmarks off.

Also draw scrollmarks on top of the shading to make them more visible

M  +26   -28   src/view/kateviewhelpers.cpp

http://commits.kde.org/ktexteditor/ab177b97e57f8eaae10e27c5bbb00cfa8b30c6d4