Jump to content
You must now use your email address to sign in [click for more info] ×

SVG file imported incorrectly


Recommended Posts

Hi,

I have this svg file (attatched) which is not correctly imported by Affinity Designer. I don't think it's particulary a problem with v2 (as I tested it with v1 as well - same result) but that's the one I'm using now - so I'm posting it in this forum.

affinity_flowers.png.a57d70bd483e3953c83fc3e23e983d2e.png

As you can see in the screenshot above all the outlines of the flowers are messed up. The stroke is too thin and the shape is filled with black color.

Inkscape for example and my browser seem to import / render the file correctly however.

Any help would be appreciated, thanks in advance!

Tested on:
Windows 10.0.19045 Build 19045
Affinity Designer v2.0.4 (hardware accelaration on/off)
Affinity Designer v1.10.6.1665
Inkscape 1.2.2 (732a01da63, 2022-12-09)

inkscape_flowers.png

Flowers.svg

Edited by Lukas.
fixed formatting
Link to comment
Share on other sites

1 hour ago, Lukas. said:

As you can see in the screenshot above all the outlines of the flowers are messed up. The stroke is too thin and the shape is filled with black color.

Inkscape for example and my browser seem to import / render the file correctly however.

Any help would be appreciated, thanks in advance!

Well, if you open that file inside a text editor and review/inspect the SVG XML code there, you will determine that certain of the numbered SVG style settings are split-up into multiple settings (.cls-10,  .cls-12,  .cls-14) ...

flowers_org.jpg.31466506c59e80a8b16c91c4f53feb11.jpg

... and the Affinity SVG parser get's probably puzzled by those!

If one instead defines and edits the styles (.cls-10,  .cls-12,  .cls-14) in a none split-up manner like here ...

flower_test_ok.jpg.6245d16cf8cf53e2123fbef1317a3a7c.jpg

... then the Affinity SVG parser doesn't get puzzled and can shows up the right SVG output instead ...

test_svg.thumb.jpg.d8bd700120b44c6c2f5d45ad782e81b7.jpg

Here's the slightly modified SVG file in terms of it's styles definitions ...

So all in all, as can be seen above, it's in this case overall a matter of how the SVG XML styles are defined and that the Affinity SVG parser isn't as flexible and foolprove here in parsing those in, in contrast to the SVG parsers used/included in webbrowsers and Inkscape!

 

☛ Affinity Designer 1.10.8 ◆ Affinity Photo 1.10.8 ◆ Affinity Publisher 1.10.8 ◆ OSX El Capitan
☛ Affinity V2.3 apps ◆ MacOS Sonoma 14.2 ◆ iPad OS 17.2

Link to comment
Share on other sites

  • Staff

Hi @Lukas.,

Thanks for your report & file provided!

Using the great information from @v_kyr above, I will be logging this with our development team in order to help improve Affinitys SVG importer in a future update. Hopefully the fixed file provided in the above post should help workaround this issue in the meantime.

I hope this helps, and many thanks to v_kyr for your work here :) 

Please note -

I am currently out of the office for a short while whilst recovering from surgery (nothing serious!), therefore will not be available on the Forums during this time.

Should you require a response from the team in a thread I have previously replied in - please Create a New Thread and our team will be sure to reply as soon as possible.

Many thanks!

Link to comment
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

Terms of Use | 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.