Review Request: Fix regression in size of shape groups with a lot of shapes

Thorsten Zachmann t.zachmann at zagge.de
Fri Sep 23 05:36:36 BST 2011



> On Sept. 22, 2011, 8:55 p.m., Jan Hambrecht wrote:
> > All in all I think you can commit. However while looking at the code I had another idea. If the calculation of the size and the sizeCached member is moved to group shape model, we do not have to expose the invalidateCacheSize function at all. And you would not need the shape group private anymore. But this is just cosmetics.

Can you explain that a bit more. I'm not clear on how the stuff should be moved to the model. Would we then call a method of the model in size to see if the group size is changed. I will commit the current state and can work on that once I understood it.


> On Sept. 22, 2011, 8:55 p.m., Jan Hambrecht wrote:
> > libs/flake/KoShapeContainerModel.cpp, line 41
> > <http://git.reviewboard.kde.org/r/102645/diff/2/?file=36447#file36447line41>
> >
> >     I am not sure about that. Probably best to check with Caspar if it is ok with him.
> 
> C. Boemann wrote:
>     if the proposeMove is not called due to moving around within then i object as it will break text runaroundof page anchored shapes in words

The CollisionDetected signal is received as usually. It is just that it is not promoted to the parents as it actually changes nothing and it happens very ofter also in cases where it is not needed at all, e.g. in stage. So text run around still works as expected.


- Thorsten


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/102645/#review6744
-----------------------------------------------------------


On Sept. 22, 2011, 2:52 a.m., Thorsten Zachmann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/102645/
> -----------------------------------------------------------
> 
> (Updated Sept. 22, 2011, 2:52 a.m.)
> 
> 
> Review request for Calligra.
> 
> 
> Summary
> -------
> 
> With the fix for the group size now every time the function is called it calculates the size from its children.
> 
> When testing this with cstester I found problmes in the documents I uploaded to.
> 
> http://www.zagge.de/anchor/groupsize/
> 
> The problem there is that due the very huge amount of shapes in the group it takes now quite a very very long time to render the pages.
> 
> The patch fixes that problem by adding a cache to the group size and only recalculates the size when there was a change.
> 
> It additionally don't forward the ChildChanged when a CollisionDetection is encountered. The CollisonChanged is not needed to forward to any parent as if the results in a change this change will be probagated.
> 
> The patch as it is now is ready for inclusion. The comments provided have been implemented.
> 
> Looking forward to your feedback.
> 
> 
> Diffs
> -----
> 
>   libs/flake/KoShapeContainerModel.cpp 7995236 
>   libs/flake/KoShapeGroup.h a53d2ad 
>   libs/flake/KoShapeGroup.cpp 409b18c 
>   libs/flake/KoShape_p.h d055056 
> 
> Diff: http://git.reviewboard.kde.org/r/102645/diff
> 
> 
> Testing
> -------
> 
> Before the patch switching between slides in the www.renaissance.co.il%2Fivbug%2Fmeeting87%2FArchitecture%20and%20design%20patterns.ppt file takes more then 10 seconds, with the patch it is instantly.
> 
> Tested resizing of groups of groups, resizing/modifying of shapes in groups. 
> 
> 
> Thanks,
> 
> Thorsten
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/calligra-devel/attachments/20110923/51e743a8/attachment.htm>


More information about the calligra-devel mailing list