drawio icon indicating copy to clipboard operation
drawio copied to clipboard

Text setting is exporting as svg image is missing

Open shanhx2000 opened this issue 1 year ago • 1 comments

Preflight Checklist

  • [x] I agree to follow the Code of Conduct that this project adheres to.
  • [x] I have searched the issue tracker for a feature request that matches the one I want to file, without success.

You must agree to search and the code of conduct. You must fill in this entire template. If you delete part/all or miss parts out your issue will be closed.

If you are technical, you should reporting bugs along the lines of https://marker.io/blog/how-to-write-bug-report. If you are not technical, we will make allowances, please try to make an effort to understand the process.

Describe the bug I knew draw.io has a setting when exporting SVG image "Convert labels to SVG". However, since yesterday and today, I am not able to find that setting (follows the similar step in https://github.com/jgraph/drawio/issues/4056). image

To Reproduce Steps to reproduce the behavior:

  1. Open a new diagram
  2. File, export as, svg..., or File, export as, advanced, change format to svg
  3. Got the image attached.

Expected behavior There is no "Text Settings" "Convert labels to SVG" in SVG export interface. Missing this function leads to words getting incorrectly wrapped after being exported as SVG images.

Screenshots image

draw.io version (In the Help->About menu of the draw.io editor):

  • draw.io version v23.0.2

I tested the problem in incognito/private mode with all browser extensions switched off, write "yes" below:

  • yes, firefox and chrome (not turn off extensions in chrome)

shanhx2000 avatar Jan 29 '24 15:01 shanhx2000

This was removed in the v23 release. Could you please show an example output where there are problems. Includes which items you ticked in the SVG export dialog.

davidjgraph avatar Feb 13 '24 10:02 davidjgraph

I have the same problem. Previously I was able to export the images with the setting "Convert labels to SVG" without any problems and insert them into a Word document. Then the image could also be zoomed without problems.

Since this setting is now missing, embedded graphics and text become blurred when zooming.

Can you restore the setting as soon as possible? I am currently writing a paper and would need the SVG option.

I have selected the following settings:

Screenshot 2024-02-14 104357

saire-lancelot avatar Feb 14 '24 09:02 saire-lancelot

We can't, no, it requires a server element that we're no longer running. Could you please show me an example of a problem export?

davidjgraph avatar Feb 14 '24 09:02 davidjgraph

Yes sure. I tick the following options in the SVG export: Screenshot 2024-02-14 105456

When I then import the SVG image into word, the text is already slightly blurred (strangely enough not for the labels, only for the text elements).

Screenshot 2024-02-14 110333

If I then create a PDF export, the graphics and the text are extremely blurred. Previously this worked perfectly with exactly the same settings.

Screenshot 2024-02-14 110324

I don't know how else I can embed the graphics so that they are always sharp when zooming. Even if I embed a high-resolution PNG, the PDF export is then unsharp.

Is there any other solution if you can no longer offer this? This option was never available in the desktop app, so I can't do it there either.

Many thanks for your assistance

saire-lancelot avatar Feb 14 '24 10:02 saire-lancelot

You could export to PDF and then go to SVG with that PDF via inkscape.

davidjgraph avatar Feb 14 '24 10:02 davidjgraph

inkscape in.pdf --pdf-poppler --export-text-to-path --export-plain-svg --export-filename out.svg

davidjgraph avatar Feb 14 '24 10:02 davidjgraph

I have just tried that. The image remains sharp until it is exported from the Word document to a PDF document. Why exactly is this option no longer possible in draw.io? That was an awesome and simple option.

saire-lancelot avatar Feb 14 '24 10:02 saire-lancelot

The text elements are now sharp but the graphics are not embedded correctly. Screenshot 2024-02-14 112438

saire-lancelot avatar Feb 14 '24 10:02 saire-lancelot

are you sure your graphics aren't just images?

davidjgraph avatar Feb 14 '24 10:02 davidjgraph

They are 512x512 pngs but i think draw.io converted them to svg before without any problems. Definitely it worked before with exactly these settings.

This is an example of a PDF export via Word when the option was still available:

Screenshot 2024-02-14 113302

saire-lancelot avatar Feb 14 '24 10:02 saire-lancelot

There's no conversion from PNG to SVG. If you use vector images in your diagram then this process should be good.

We used inkscape behind the scenes previously, you just need to repeat this locally.

davidjgraph avatar Feb 14 '24 11:02 davidjgraph

This way it is now working. Many thanks for the support!

saire-lancelot avatar Feb 14 '24 19:02 saire-lancelot

This way it is now working. Many thanks for the support!

Hi Saire, could you please share how you solved it?

xu-jiachen avatar Mar 22 '24 06:03 xu-jiachen