Bug 458760

Summary: Layer styled vector handling in large size canvases is prone to progress popup stutters
Product: [Applications] krita Reporter: stephen <tgdev001>
Component: Layers/VectorAssignee: Krita Bugs <krita-bugs-null>
Status: CONFIRMED ---    
Severity: normal CC: tomtomtomreportingin
Priority: NOR Keywords: regression
Version First Reported In: git master (please specify the git hash!)   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description stephen 2022-09-05 19:07:45 UTC
SUMMARY
Krita version is 5.1.0 nightly (git 43f0ae3)

The vector handles behave in a weird manner as soon as you release mouse or pen click(noticeable with stroke rendering on(they stay glued to the mouse movement after you release your click, and stick for about 1-3 seconds.

STEPS TO REPRODUCE
1. create a new vector layer
2. insert a vector rectangle with white background fill
3. on the vector layer, activate the following layer style options(like json, but not really json) : 
{ "stroke" : {
		"Structure" : {
			"size" : 12,
			"size_unit" : "px",
			"Position" : "Outside",
			"Blend_Mode" : "Normal",
			"opacity" : 100,
			"opacity_unit" : "%"
		},
		
		"Fill" : {
			"Type" : {
				"color" : {"hex" : "#000"},
				"label" : black
			}
			
		}
		
	}
}
4. using the "Select Shapes Tool", modify the shape of the rectangle a few times by dragging the sides or vertices.
5. also using the "Select shapes tool", try moving the rectangle shape a bit, then release click while continuing to hover the cursor rapidly.


OBSERVED RESULT
1. dragging the middle handle or vertices casually causes a glitchy gap between cursor and rectangle once you release mouse or pen click.
2. soon after you release pen click, the rectangle or rectangle handles  stick to the cursor movement for about 2-5 seconds depending on the circumstances(moving constantly right after click is released)
3. Krita shows "waiting for image operation to complete" if you move constantly your cursor.


EXPECTED RESULT
1. no glitchy gap from cursor right after you release mouse or pen click after dragging the corner of the shapes or after moving the shapes with the shapes tool.

2. Right after you release your click drag, the rectangle should not pursue your cursor movement and instead stop at the position you released it

SOFTWARE/OS VERSIONS
Windows 10 21H1
Comment 1 tomtomtomreportingin 2022-09-23 21:10:52 UTC
I can reproduce the issue. At the most basic level, it seems that layer styled vector handling at large canvas sizes (such as 4961x7016) is prone to progress bar popup spam as of 5.1.0. The issue does not occur in 5.0.6. Marking as a regression and renaming the report to be more descriptive of the issue.