Bug 348234 - Selection modifier patch issues.
Summary: Selection modifier patch issues.
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Tools (show other bugs)
Version: git master (please specify the git hash!)
Platform: Other Linux
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
: 348243 348288 (view as bug list)
Depends on:
Blocks:
 
Reported: 2015-05-26 10:00 UTC by wolthera
Modified: 2015-06-25 16:26 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description wolthera 2015-05-26 10:00:45 UTC
General bugreport for selection modifier issues.

Personal things I noticed:
* Whatever you had set to pick foreground colour from merged image is now set to pick background color from merged image.
* Alternate invocation is broken and it's not helping this patch.
* Added to that, we can't seem to differentiate between click+shift is always treated as shift+click+shift, and click+ctrl is always treated as ctrl+click+ctrl.
* Sometimes, but not always, my marching ants don't reflect my global selection mask. Krita uses the global selection masks to do the selection and the marching ants are the ones that are wrong. Can't seem to reproduce it.

Reproducible: Always
Comment 1 wolthera 2015-05-26 10:02:40 UTC
That said, Alternative invocation was broken on previous Krita's as well.
The problem is that Krita's alternate invocation settings don't change the hotkeys in actuality.
Comment 2 animtim 2015-05-26 10:07:33 UTC
As Wolthera said, my issue is with clic+modifier.
-Doing modifier+click does change the selection mode. That is ok.
-Doing click+ any modifier does the action of the modifiers (proportional/scale from center/ translate), but also the resulting selection mode. This is really bad.
Comment 3 wolthera 2015-05-26 16:58:20 UTC
This also seems to have broken the clone tool somehow...
Comment 4 Halla Rempt 2015-05-26 17:08:36 UTC
*** Bug 348243 has been marked as a duplicate of this bug. ***
Comment 5 Halla Rempt 2015-05-27 07:12:50 UTC
*** Bug 348288 has been marked as a duplicate of this bug. ***
Comment 6 David REVOY 2015-05-29 09:55:18 UTC
An update :  I get the reset at each compile. This bug is now my top annoying one.  xD
Comment 7 Halla Rempt 2015-05-29 10:10:13 UTC
Hm... Not sure how that's possible: I already reverted the patch because I thought we were done -- it cannot have left any bugs behind!
Comment 8 Halla Rempt 2015-06-21 13:51:02 UTC
Git commit a7f5592308fa8e841f444106a15f37ffa66ae001 by Boudewijn Rempt.
Committed on 21/06/2015 at 13:50.
Pushed by rempt into branch 'calligra/2.9'.

Third time! The Selection modifiers patch!!!

This refactors polygonal, elliptical, and rectangular selection tools to
use a basic selection tool template which unifies previously duplicated
code. The template overrides the ability to execute alternate actions, but
none of those tools supported alternate actions previously and the ellipse
and rectangle were already overriding the modifier keys to begin with.

Shift: add to selection

Alt: subtract from selection

Shift+Alt: intersect current selection

Ctrl: replace selection

Certain key combinations allow users the ability to expose the modifier
keys to the base tool, i.e. to make proportional / translated / scaled
alterations using ctrl/alt/shift.

1) If the user clicks first and then presses modifier keys, those modifier
keys will only alter the selection method.

2) If the user presses modifier keys first and then clicks, the selection
method is locked in, and subsequent modifier keystrokes will change how
the selection is drawn.

3) If the underlying tool never takes modifier keys, modifier keys will
always alter the selection method.

Note: the bezier curve selection tool doesn't support the modifiers yet.

Patch by Michael Abrahams. Thanks!
CCMAIL: miabraha@gmail.com
CCMAIL: kimageshop@kde.org
CCMAIL: animtim@gmail.com, info@davidrevoy.com
REVIEW: 123833
Related: bug 315255

NOTE: Changing the secondary invocation action is still broken, but that's
not the fault of this patch, that's another bug!

M  +2    -1    krita/image/kis_selection.h
M  +14   -0    krita/plugins/tools/defaulttools/kis_tool_path.cc
M  +4    -1    krita/plugins/tools/defaulttools/kis_tool_path.h
M  +25   -10   krita/plugins/tools/selectiontools/kis_tool_select_contiguous.cc
M  +9    -4    krita/plugins/tools/selectiontools/kis_tool_select_contiguous.h
M  +30   -22   krita/plugins/tools/selectiontools/kis_tool_select_elliptical.cc
M  +29   -13   krita/plugins/tools/selectiontools/kis_tool_select_elliptical.h
M  +32   -4    krita/plugins/tools/selectiontools/kis_tool_select_outline.cc
M  +10   -5    krita/plugins/tools/selectiontools/kis_tool_select_outline.h
M  +30   -4    krita/plugins/tools/selectiontools/kis_tool_select_path.cc
M  +18   -12   krita/plugins/tools/selectiontools/kis_tool_select_path.h
M  +30   -41   krita/plugins/tools/selectiontools/kis_tool_select_polygonal.cc
M  +21   -16   krita/plugins/tools/selectiontools/kis_tool_select_polygonal.h
M  +29   -44   krita/plugins/tools/selectiontools/kis_tool_select_rectangular.cc
M  +20   -16   krita/plugins/tools/selectiontools/kis_tool_select_rectangular.h
M  +23   -8    krita/plugins/tools/selectiontools/kis_tool_select_similar.cc
M  +18   -10   krita/plugins/tools/selectiontools/kis_tool_select_similar.h
M  +0    -1    krita/ui/CMakeLists.txt
M  +8    -3    krita/ui/canvas/kis_tool_proxy.h
M  +1    -0    krita/ui/input/kis_alternate_invocation_action.cpp
M  +0    -1    krita/ui/input/kis_input_manager.cpp
M  +1    -1    krita/ui/tool/kis_delegated_tool.h
M  +8    -0    krita/ui/tool/kis_tool.cc
M  +11   -1    krita/ui/tool/kis_tool.h
M  +4    -4    krita/ui/tool/kis_tool_paint.h
M  +12   -0    krita/ui/tool/kis_tool_polyline_base.cpp
M  +3    -0    krita/ui/tool/kis_tool_polyline_base.h
M  +34   -24   krita/ui/tool/kis_tool_rectangle_base.cpp
M  +8    -5    krita/ui/tool/kis_tool_rectangle_base.h
D  +0    -79   krita/ui/tool/kis_tool_select_base.cpp
M  +185  -18   krita/ui/tool/kis_tool_select_base.h
M  +19   -7    libs/basicflakes/tools/KoCreatePathTool.cpp
M  +9    -2    libs/basicflakes/tools/KoCreatePathTool.h
M  +7    -5    libs/basicflakes/tools/KoCreatePathTool_p.h

http://commits.kde.org/calligra/a7f5592308fa8e841f444106a15f37ffa66ae001