paddy2-beta icon indicating copy to clipboard operation
paddy2-beta copied to clipboard

Stack miscalculated if a masked object is contained

Open dngrlux opened this issue 6 years ago • 4 comments

If a group within a stack contains a larger masked element, the stacking uses the inner masked element's dimensions, rather than the mask itself. Paddy2 should ignore the dimensions of the masked element and instead calculate bounds using the mask.

There are some other oddities depending if the masked element's group is at the top, middle, or bottom of the stack, and if the 'Collapse hidden views' is toggled or not. This is a little difficult to explain, but easy to see and experiment with. All of the examples attached are using the same stacking settings.

Thanks for the amazing plugin!

paddy2 mask stacking issue.sketch.zip

paddy2 mask stacking issue screenshot

dngrlux avatar Jul 26 '18 08:07 dngrlux

I have also found this to be an issue and hope there's a fix for the next release.

dlewand691 avatar Jul 26 '18 14:07 dlewand691

Thanks for this @dngrlux — this one is a pretty complex fix. Going to look into it and see what I can do. 👍

DWilliames avatar Jul 29 '18 13:07 DWilliames

Ok. Looks like I've managed to fix this for the next release 👍

DWilliames avatar Jul 29 '18 13:07 DWilliames

This also happens when only setting padding. I hope the fix affect all calculations.

craigmdennis avatar Sep 14 '18 13:09 craigmdennis