Bug 420531 - Copy & Pasting Vector Shape from one layer to another doesn't preserve node type.
Summary: Copy & Pasting Vector Shape from one layer to another doesn't preserve node t...
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Tools/Vector (show other bugs)
Version: 4.2.9
Platform: Other Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: sh_zam
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-04-24 22:47 UTC by Samwise Galenorn
Modified: 2021-04-02 08:38 UTC (History)
3 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 Samwise Galenorn 2020-04-24 22:47:05 UTC
SUMMARY:
Moving a vector from one Vector Layer to another using Select Shapes Tool doesn't preserve node type information.

STEPS TO REPRODUCE:
1. In Krita document, add two Vector Layers, select a vector layer.
2. Using any vector tool, create a vector.
3. Using Edit Shapes Tool, select the new vector.
4. Using Tool Options, change nodes to Smooth or Symmetric Points.
5. Using Select Shapes Tool, select the vector.
6. Cut or Copy then Paste the vector to another layer.

OBSERVED RESULT:
Nodes of the vector in the second layer are all Corner Points.

EXPECTED RESULT:
Node types should be preserved to new layer.

SOFTWARE/OS VERSIONS:
Windows 10 x64, Linux Mint x64 19.3 Tricia

ADDITIONAL INFORMATION:
Node types of the original vector are all preserved if Copy command is used.
Comment 1 Rebecca Breu 2020-04-25 11:17:40 UTC
I can confirm this on the 4.2.9 appimage. You don't even have to paste it do a different layer--pasting to the same layer has the same effect. Pasting to Inkscape too.
Comment 2 vanyossi 2020-04-26 04:52:31 UTC
This bug is probably a duplicate of bug 418008
Comment 3 Bug Janitor Service 2021-03-29 10:13:51 UTC
A possibly relevant merge request was started @ https://invent.kde.org/graphics/krita/-/merge_requests/773
Comment 4 Dmitry Kazakov 2021-03-29 11:23:16 UTC
Git commit e87cb6899993fdfc65aa5371e752ba17b6b34538 by Dmitry Kazakov, on behalf of Sharaf Zaman.
Committed on 29/03/2021 at 11:22.
Pushed by dkazakov into branch 'master'.

Bugfix: Vector layer doesn't preserve nodetypes info

We had a mechanism to load nodetypes info but we didn't use it.
Related: bug 418008

M  +22   -28   libs/flake/KoPathShape.cpp
M  +28   -0    libs/flake/KoPathShape.h
M  +0    -30   libs/flake/KoPathShape_p.h
M  +3    -0    libs/flake/svg/SvgParser.cpp
M  +1    -0    libs/flake/svg/SvgWriter.cpp

https://invent.kde.org/graphics/krita/commit/e87cb6899993fdfc65aa5371e752ba17b6b34538
Comment 5 Samwise Galenorn 2021-04-01 22:46:35 UTC
I've downloaded the Krita Nightly Windows build:
krita-nightly-x64-5.0.0-prealpha-1b3b1973c0-setup.exe
and confirmed the fix. Now, cutting/copying a vector from one Vector Layer to another works fine with Node information being preserved. Thank you.
On a side note, when selecting the vector using the Select Shape Tool, the vector shape will fill with a color. I have to click Undo Last Action to get rid of the fill color. Do I file that as a bug on an Alpha build?
Comment 6 sh_zam 2021-04-02 08:38:55 UTC
(In reply to Samwise Galenorn from comment #5)
> I've downloaded the Krita Nightly Windows build:
> krita-nightly-x64-5.0.0-prealpha-1b3b1973c0-setup.exe
> and confirmed the fix. Now, cutting/copying a vector from one Vector Layer
> to another works fine with Node information being preserved. Thank you.
> On a side note, when selecting the vector using the Select Shape Tool, the
> vector shape will fill with a color. I have to click Undo Last Action to get
> rid of the fill color. Do I file that as a bug on an Alpha build?

well, I thinking filling a bug will unnecessary since we fixed that bug yesterday: https://invent.kde.org/graphics/krita/-/merge_requests/784 :)