Export to PDF doesnt keep fonts

Started by DuncanWilliam, May 21, 2020, 13:08:16 PM

Previous topic - Next topic

DuncanWilliam

Hi all,

I have developed a view in Archi and changed the default font to CMU Serif, when I try to export it to PDF the PDF is in Arial.

Can this be changed?

Thanks,
Duncan

Phil Beauvoir

#1
When you say "and changed the default font to CMU Serif" do you mean in Archi's preferences? What is the font when you select the object in a View?

Also, please:

- version of Archi?
- OS platform?
- steps to reproduce the problem...
If you value and use Archi, please consider making a donation!
Ask your ArchiMate related questions to the ArchiMate Community's Discussion Board.

DuncanWilliam

#2
Hi Phil

Yes the default font in the preferences. In the view it is CMU Serif (default). The PDF is however in Arial.

Archi Version: 4.6.0
OS: Windows 10

Im modeling a business view. First I select the view -> file -> export -> view as image -> select location -> as PDF -> save.

Phil Beauvoir

I assume you're exporting the view as an image and selecting the PDF option. Please try:

- setting the default font in preferences back to its default setting
- manually setting an object to CMU serif
- export to image

If no luck try playing with different fonts, it may be that the PDF export library is having a problem with that particular font. ie. is the problem with all fonts, or just one?
If you value and use Archi, please consider making a donation!
Ask your ArchiMate related questions to the ArchiMate Community's Discussion Board.

DuncanWilliam

All of the fonts.

Apologies the pdf is printing out the fonts in the default Segue not Arial.

I restored fonts back to defaults (segue) and chance on item to CMU Serif manually. I then saved and exported to PDF but all fonts are still Segue. I then exported to SVG and I get the output as shown in Archi (one item CMU Serif the rest default).

DuncanWilliam

It seems to be that specific font. I changed the default to a random font and it exports to PDF fine.

Is there a way of importing the CMU Serif font into Archi?

Phil Beauvoir

#6
I tried with that font and got the same result. It might be that the Java graphics library (batik and fop transcoder) has a bug or issue with that particular font.

> Is there a way of importing the CMU Serif font into Archi?

That wont help. The issue is in the Java graphics libraries.

The only thing you can do is use a different font, or export as SVG.

Edit: I tried with the latest versions of batik and fop transcoder - same thing. Just that font.
If you value and use Archi, please consider making a donation!
Ask your ArchiMate related questions to the ArchiMate Community's Discussion Board.

DuncanWilliam

Not too worry. SVG will work fine.

Thanks for your help.

Phil Beauvoir

Duncan - I have found the issue, see here - https://github.com/archimatetool/archi/issues/628

If you uninstall your font, then re-install it by right-clicking on the font file and choosing "Install for all users" it will export in the image. I don't know why this is.
If you value and use Archi, please consider making a donation!
Ask your ArchiMate related questions to the ArchiMate Community's Discussion Board.

DuncanWilliam

Works a treat!

Many thanks for your effort.

Phil Beauvoir

The issue is under investigation, but that's the workaround for now.
If you value and use Archi, please consider making a donation!
Ask your ArchiMate related questions to the ArchiMate Community's Discussion Board.