Parsing glyph data of OpenType(CFF) font is not supported (Unix- no fonts installed- but provided with word document)

Hi

There are two other threads concerned with the same topic:
(Java, not using latest version, no conversion to PDF).
I wasn’t sure whether to continue one of those are create a new one, thus ended up in creating a new one.

Java Code to reproduce the issue:
public static void main(String[] args) throws Exception {
if (args.length == 0) {
System.err.println(“Input argument missing”);
return;
}

File inputFile = new File(args[0]);
File outputFile = new File(args[0] + “.pdf”);
try (FileInputStream fis = new FileInputStream(inputFile); FileOutputStream fos = new FileOutputStream(outputFile)) {
Document doc = new Document(fis);
doc.save(fos, new PdfSaveOptions());
}
}

Console Output see attached file.
Running this code on Windows with fonts installed works.
Running this code on Unix with fonts installed would probably work too (not tested).
But running this code on Unix with no fonts installed fails (server only, no GUI, no fonts required).
The font (Arial Unicode MS in this example) is explicitly provided with the document itself (embedded).

The watermark cannot be rendered for the PDF Output even if the font is embedded. Using PDF conversion without the watermark works fine. If the font is not embedded in the document, the generated PDF (without watermark) uses the wrong font (Fanwood) on Unix, which is okay because the correct font was not provided. If generated on Windows with installed fonts, the PDF output uses the correct font.

Verified with 15.4.0, 15.7.0 and 15.8.0.

Thanks in advance.

Kind regards
Stephan

Hi Stephan,

We are investigating the issue and will get back to you soon.

Best Regards,


Has there been any progress on this issue as it appears that I have encountered this issue as well.

Hi,

We were able to reproduce the issue and it has been logged into our issue tracking system as WORDSNET-12526. We will keep you updated on this issue in this thread.

Best Regards,

Hi Stephan,

The issue has been analyzed by our product team and following is the result of analysis.

The exception will be fixed in the next release but MS Word does not consider WordArt watermark when embedding fonts. In this particular document embedded "Arial Unicode MS" subset contains glyphs for paragraph text only i.e. there are no glyphs for characters 'D', 'f' and 't' from watermark in the subset. So it is better not to rely on MS Word's font embedding when working with WordArt/watermarks and provide full fonts to Aspose.Words along with the document.

Please feel free to share if you have any concerns.

Best Regards,

The issues you have found earlier (filed as WORDSNET-12526) have been fixed in this .NET update and this Java update.


This message was posted using Notification2Forum from Downloads module by aspose.notifier.

Thanks a lot for the fix and for the information about font embedding too.
I will verify the behavior with the new release as soon as possible (and would get back to you if there is still an issue).

Kind regards
Stephan