Bug 348290

Summary: [ Eraser mode ] eraser icon highlight in toolbar send wrong feedback to user
Product: [Applications] krita Reporter: David REVOY <info>
Component: ToolsAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: griffinvalley, halla, kalia24, welcome
Priority: NOR    
Version: 2.9   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: [screenshot of the bug]

Description David REVOY 2015-05-27 07:01:15 UTC
Hi, 

In the top-toolbar, the eraser icon was updated in 2.9 with a background 'active' color when the eraser is in use. While painting, I often saw it highlighted for no-reason. It took me time to find how to reproduce this bug.

How to reproduce :
================
1. select a brush, and paint a stroke on canvas
2. turn eraser mode with the 'E' key on keyboard and erase a part of your stroke
3. directly change color in the "advanced color selector"
4. paint a stroke on the canvas

Result :
======
The eraser icon on the top-toolbar keep highlighted/active , even if the blending mode of the brush is a 'Normal' one.

Expected :
=========
The eraser icon highlighted/active to be in sync with the Blending mode list : highlight when it's 'Eraser' mode, turn the highlight off when it's another blending-mode.
Comment 1 Camille Bissuel 2015-06-23 12:48:15 UTC
I can't reproduce it strictly,  with several brushes, but the outline of the eraser button in the "painter's tool" button remain highlighted with the steps David describe, while the background go back to normal ...
Comment 2 kalia24 2015-11-25 11:08:58 UTC
Confirm on what Camille wrote - the outline remains highlighted for some reason, which is confusing.
Using Windows version.
Comment 3 Halla Rempt 2016-03-22 13:57:36 UTC
See: https://phabricator.kde.org/T1597
Comment 4 wolthera 2016-05-11 12:14:31 UTC
This is fixed in 3.0 :)
Comment 5 David REVOY 2017-01-24 08:14:52 UTC
Created attachment 103612 [details]
[screenshot of the bug]

Hi, I reopen this bug because a similar-but-not-yet the same bug is back on the eraser top toolbar icon (git~krita/3.1) :

### To reproduce:
- Select an eraser preset in the brush docker

### Result:
- The 'eraser icon' doesn't receive hightlight/selected status. However, the blending mode switch correctly to 'eraser' mode. 

( Note: screenshot in attachment. )
Comment 6 Halla Rempt 2017-01-24 10:11:24 UTC
Git commit f1968fd7f55cda3a08aa0488a3b72d186db565e8 by Boudewijn Rempt.
Committed on 24/01/2017 at 10:10.
Pushed by rempt into branch 'master'.

M  +6    -0    libs/ui/kis_paintop_box.cc

https://commits.kde.org/krita/f1968fd7f55cda3a08aa0488a3b72d186db565e8
Comment 7 Halla Rempt 2017-01-24 10:11:29 UTC
Git commit 59d9fb6de9d72f7cc72c0999b0c412f75f45a444 by Boudewijn Rempt.
Committed on 24/01/2017 at 10:11.
Pushed by rempt into branch 'krita/3.1'.

M  +6    -0    libs/ui/kis_paintop_box.cc

https://commits.kde.org/krita/59d9fb6de9d72f7cc72c0999b0c412f75f45a444
Comment 8 Halla Rempt 2017-03-13 10:02:23 UTC
Git commit 98a0c786310fdfcda488405a6ad098d6e8169120 by Boudewijn Rempt.
Committed on 13/03/2017 at 10:01.
Pushed by rempt into branch 'master'.

Revert "Make the erase mode button follow the blending mode combobox"

This broke flipping the stylus.
Related: bug 375878

This reverts commit f1968fd7f55cda3a08aa0488a3b72d186db565e8.

M  +0    -6    libs/ui/kis_paintop_box.cc

https://commits.kde.org/krita/98a0c786310fdfcda488405a6ad098d6e8169120
Comment 9 Halla Rempt 2017-03-13 10:53:35 UTC
Git commit ad22bab81c3379a467f0d5c8a6423a0165f2cf86 by Boudewijn Rempt.
Committed on 13/03/2017 at 10:34.
Pushed by rempt into branch 'krita/3.1'.

Revert "Make the erase mode button follow the blending mode combobox"

This broke flipping the stylus.
Related: bug 375878

This reverts commit f1968fd7f55cda3a08aa0488a3b72d186db565e8.

M  +0    -6    libs/ui/kis_paintop_box.cc

https://commits.kde.org/krita/ad22bab81c3379a467f0d5c8a6423a0165f2cf86