Insert SVG Graphics Image with Outlined Fonts in Word DOCX Document using Java | Custom Fonts

This code inserts an SVG into a word document. The produced word document has an SVG with outline fonts that are not rendered correctly. Can you have a look please. The code is:

FontSettings.getDefaultInstance().setFontsSources(new FontSourceBase[] { new SystemFontSource(), new FolderFontSource("fonts", true) });
Document doc = new Document();
DocumentBuilder builder = new DocumentBuilder(doc);
String svgString = Files.readString(Paths.get("svg/input_outline_fonts.svg"));  

It loads the fonts from the fonts subdirectory. Those are required to reproduce the issue. It also loads the SVG from the svg folder.

We are using Aspose.Words for Java 20.6.

The data is in the attached zip file. (753.2 KB)


We managed to reproduce this issue on our end and have logged this issue in our bug tracking system with ID WORDSNET-21277. Your thread has also been linked to this issue and you will be notified here as soon as it will get resolved in future. Sorry for the inconvenience.

The issues you have found earlier (filed as WORDSNET-21277) have been fixed in this Aspose.Words for Java 21.10 update.