hallvard / plantuml

Embed UML diagrams in files and view them in Eclipse
http://plantuml.sourceforge.net/
209 stars 57 forks source link

Problems exporting SVGs of multi-page sequence diagrams #119

Closed schmidtjano closed 3 years ago

schmidtjano commented 3 years ago

Hello!

I am unable to export SVG images of page 2 (or higher) of multi-page sequence diagrams (created using the 'newpage' command). I am selecting export by right-clicking on those pages, but the resulting SVG image is always of page 1.

FYI, I am able to export PNG images of each page of a multi-page diagram. However, neither the PNG image nor the print-to-PDF option offers the resolution anywhere near as nice as SVG. Is there something you can do to support SVG export for multi-page diagrams?

Also, is there a way in Eclipse to export all the pages at once vs. tediously doing this one-by-one?

Thank you and best regards,

Jan

hallvard commented 3 years ago

I've verified the issue and it's easy to see why it happens: The image viewer doesn't know the image number, so when generating the SVG it defaults to the first one. I've prototyped a solution, where it knows the original image number and can request the SVG for the correct image.

Since you mentioned exporting all images at once, I prototyped that, too. If you include an image number marker/placeholder in the name, it generates a series of files, so entering "usecase-#.png" will generate usecase-1.png, use case-2.png, ...

What do you think is the "best" marker/placeholder? Is "#" ok?