Bug 305782

Summary: Scale a layer in X axis, then Undo causes a layer has jump left or right
Product: [Applications] krita Reporter: ALeXeY <alexeyn3d>
Component: Tools/TransformAssignee: Dmitry Kazakov <dimula73>
Status: RESOLVED FIXED    
Severity: normal CC: halla
Priority: NOR    
Version: git master (please specify the git hash!)   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: .kra file
Enter horizontal scale
Apply transform
Undo transform

Description ALeXeY 2012-08-25 20:35:40 UTC
Snapshots and .kra file will be attached

Reproducible: Always

Steps to Reproduce:
1. Scale a layer horizontally
2. Undo, notice that the layer has shifted from it's previous position
Comment 1 ALeXeY 2012-08-25 20:36:53 UTC
Created attachment 73469 [details]
.kra file
Comment 2 ALeXeY 2012-08-25 20:39:02 UTC
Created attachment 73470 [details]
Enter horizontal scale
Comment 3 ALeXeY 2012-08-25 20:40:25 UTC
Created attachment 73471 [details]
Apply transform
Comment 4 ALeXeY 2012-08-25 20:41:47 UTC
Created attachment 73472 [details]
Undo transform
Comment 5 ALeXeY 2012-08-25 20:47:47 UTC
PS: I don't remember in which commit it appeared first time. But I think, it's old enough...
Comment 6 Halla Rempt 2012-09-27 14:05:34 UTC
Hi Alexey,

Thanks for your report. I can confirm the issue.
Comment 7 Dmitry Kazakov 2012-10-09 16:40:08 UTC
Git commit 026391ab2343d4860421e851285fa23795027e89 by Dmitry Kazakov.
Committed on 09/10/2012 at 18:33.
Pushed by dkazakov into branch 'master'.

Made KisTransaction to save the device offset.

Now be careful with using KisNodeMoveCammand2 together with KisTransaction,
because both of them track the device's offset. Atm, there are no
collisions possible.

M  +0    -1    krita/image/CMakeLists.txt
M  +0    -1    krita/image/commands/kis_node_commands.h
D  +0    -71   krita/image/commands/kis_node_move_command.cpp
D  +0    -56   krita/image/commands/kis_node_move_command.h
M  +30   -10   krita/image/kis_transaction_data.cpp
M  +3    -0    krita/image/kis_transaction_data.h
M  +45   -0    krita/image/tests/kis_transaction_test.cpp
M  +1    -0    krita/image/tests/kis_transaction_test.h

http://commits.kde.org/calligra/026391ab2343d4860421e851285fa23795027e89
Comment 8 Jarosław Staniek 2012-10-31 11:29:41 UTC
Git commit 8e5b063adc8ac2d28ec80d3c33ce8dcabdd46633 by Jaroslaw Staniek, on behalf of Dmitry Kazakov.
Committed on 09/10/2012 at 18:33.
Pushed by staniek into branch 'kexi-altertable-staniek'.

Made KisTransaction to save the device offset.

Now be careful with using KisNodeMoveCammand2 together with KisTransaction,
because both of them track the device's offset. Atm, there are no
collisions possible.

M  +0    -1    krita/image/CMakeLists.txt
M  +0    -1    krita/image/commands/kis_node_commands.h
D  +0    -71   krita/image/commands/kis_node_move_command.cpp
D  +0    -56   krita/image/commands/kis_node_move_command.h
M  +30   -10   krita/image/kis_transaction_data.cpp
M  +3    -0    krita/image/kis_transaction_data.h
M  +45   -0    krita/image/tests/kis_transaction_test.cpp
M  +1    -0    krita/image/tests/kis_transaction_test.h

http://commits.kde.org/calligra/8e5b063adc8ac2d28ec80d3c33ce8dcabdd46633