Jump to content
Sign in to follow this  

Calculation/transform bug when grouping objects in a constraint group

Recommended Posts


the constraint group feature is immensely awesome and helpful. However, I've encountered several problems, where the feature does not work as I'd expect. Here I'd like to document one such bug. It starts with a 320x320 constraint group which holds four containers:


  • Yellow and blue are fixed-height headers and footers, that stretch with the parent
  • Green and red stretch to fill the vertical gap between header and footer and their width will always be 25% of the parent


So far, so good.

Now, I'd like to start adding further elements to the four docked regions. Let's start with centered labels:


The labels are Frame Texts without any constraints.

Now, when I start to group each docked rectangle with its respective label, this happens:


The nested groups do not "wrap" their contents as intended. Actually, the right and bottom groups don't even overlap the geometry of their children at all.


However, the grouped items are still in the right place. Only the newly created "container" groups have the wrong dimensions.

But here's the interesting part: When I scale the parent to match the 1280x720 artboard size, the dimensions of the nested groups almost align with the original 320x320 parent:


Long story short: I believe, the dimensions of the nested groups are not computed in the right coordinate system. Somehow, the transformation from "global Artboard space" to "local 1rst-order constraint group space" is performed twice for the newly created "2nd-order" constraint groups.



Share this post

Link to post
Share on other sites

Hi CaptNeo


We are aware of some issue with constraint not playing nice. However in your example it is also important to take note of layer structure. So you initially create a top level constraint group which works ok as the shapes are all constraining to this master group. next you add text and group it individually with each shape. When grouping this now no longer makes the constraints applied to the shape work in relation to the master group. It now works in relation to this sub group you have created which is what is causing the layer shift. You need to remove the constraints on the shapes before grouping then apply constraints to that entire sub group (not the individual shape inside it) to get it to constraint properly to the master group again.


When working with groups within groups it is important to remember that everything resolves bottom up, so the elements in the sub group resolve to the sub group itself, then this sub group resolves to the main top layer group, which then in this case resolves to the artboard


Hope that helps add some clarity



Serif Europe Ltd - Check the latest news at www.affinity.serif.com

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...

Important Information

Please note the Annual Company Closure section in the Terms of Use. These are the Terms of Use you will be asked to agree to if you join the forum. | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.