Hi @Douglas! I am indeed using the latest version. Since I didn’t use the “Title” and “Description” in Seamly for that pattern, I didn’t have those < title > and < desc > tags. But seeing them in @Grace her file, made me dig deeper into my file and made it so I found the empty groups in each individual pattern piece. I added a title and description to a new file, and they are not causing the alignment issue!
These 2 layers seem to be connected to the 2 pattern pieces and seem to have been causing the problem:
I would dare bet that if @Grace were to open up those piece groups above < desc > and < title >, she would find some empty ones as well.
I believe Evans fixed the issue of extraneous points in a group with a recent update. Please let us know if this is still an issue with the most recent release.
The stray points have always been there, but, just like you said, they seem to have disappeared now! Since it’s now a habit to have Illustrator select and delete them all, I didn’t notice they weren’t there anymore.
The stray points never interfered with aligning pieces that were selected separately though, so this was an issue I never encountered before. But, thanks to @Grace, the fix I found is really easy to do and gets rid of any empty groups and stray points, should there be any, at the same time!
Since “Object > Path > Clean Up” fixes everything in one go, I believe your time is better spent on other issues!
Thank you all so much for all your time and work you put into this!!
Yes… apparently Qt’s SVG renderer was writing an extraneous “origin” point, that @Onetchou recently fixed.
Just as note… each pattern piece should have 7 groups. One main group for the whole piece, 1 group for the seamline, 1 group for the cut line, 1 group for the grainline, 1 group for the pattern label, 1 group for the piece label, and 1 group for the notches. If any of those graphic items are hidden off or not used, they will still be written as an empty group. That’s just a result of how the default QSvgGenerator is rendering is the QGraphicItems… it’s not checking if an item is hidden or a path is empty… it still just writes the < g > tag.
Why Illustrator would choose to add the < title > and < desc > tags as layers (groups)… I don’t know.
Illustrator handles layers slightly differently. The layer is the level that you want something to appear on. Inside the layer are the groups of items (and/or stand-alone items, line the Title & Desc items) and inside the groups can be more groups and/or stand-alone items.
I indeed recently removed the stray points from the pattern pieces, and doing so I started to clean the svg files a little bit, because they were full of empty groups.
I managed to remove most of them, but a few of them are still generated and are not removed by the code I added (or are generated after my code cleans everything). Since I wasn’t aware of a practical need of having those empty groups completely removed and that I was only doing a little bit of cleaning while I was working on the svgs, I didn’t take the time to investigate further.
I could take a look at it and try to completely remove any empty group that remains, since it seems useful
Those groups represent grainlines, labels, or notches that have no data. The graphic items exist, there’s just no data.
That’s why if I counted correctly, there’s aways going to be 7 groups for each piece in an SVG… 1 parent group (this), and the 6 child groups. Unfortunately as you are probably already aware, the SVGGenerator does not allow to render the list of scene items one by one… it just renders the whole scene.
Not sure how you can determine to remove an empty group like this – which is probably a non existent label?
The SVG generator I wrote directly modifies the xml file after it is generated by Qt Svg generator, so I should be able to detect empty groups as they are <g> nodes with no child in the corresponding DOM tree. I’ll take a quick look at it now.