Jump to content
Friksel

[AD] Changing Opacity of group or layer disturbes hierarchy and structure in SVG export

Recommended Posts

When exporting a file to SVG from within Designer, for each layer or group having an opacity set below 100%, Designer automatically adds an extra, redundant, group just to apply opacity to:

 

* Adding a group without opacity set less then 100%:

<g id="myID">
  <rect x="152.01" y="85.967" width="142.705" height="84.033"/>
</g>

* But when opacity of the group is set below 100%:

<g id="myID">
  <g opacity="0.5">
     <rect x="152.01" y="85.967" width="142.705" height="84.033"/>
  </g>
</g>

 

This results in larger and more complicated SVG-outputs then necesary, but most importantly: it breaks the structure and hierarcy as meant by the designer causing all kind of problems when using the SVG for styling and javascript usages: interactivity and animations. Because suddenly there is an extra, unexpected level in hierarcy and the ID is on a different level then the opacity. That way webdevelopers can't trust the ID anymore.

 

Instead the opacity should be applied directly to the group like visually done in Designer, keeping the structure the same as in the GUI and so meant by the designer:

<g id="myID" opacity="0.5">
  <rect x="152.01" y="85.967" width="142.705" height="84.033"/>
</g>

 


 

Share this post


Link to post
Share on other sites
On 5/4/2018 at 10:15 AM, Sean P said:

Hi Friksel,

Thanks for letting us know! I can reproduce this here and will get it passed on to development.

@Sean P Nice to see this is fixed in Affinity Designer Customer Beta - 1.6.5.112. Thanks a lot guys!


 

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.

Guest
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.

Loading...

×
×
  • 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.