You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "John Hewson (JIRA)" <ji...@apache.org> on 2015/01/19 20:36:35 UTC
[jira] [Commented] (PDFBOX-2606) Support OS with no fonts
[ https://issues.apache.org/jira/browse/PDFBOX-2606?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14282918#comment-14282918 ]
John Hewson commented on PDFBOX-2606:
-------------------------------------
The problem is that if getType1FallbackFont fails then it executes the following line:
{code}
throw new IllegalStateException("No fonts available on the system for " + fontName);
{code}
The solution is to return {{ttfFallbackFont}}, which is bundled with PDFBox.
> Support OS with no fonts
> ------------------------
>
> Key: PDFBOX-2606
> URL: https://issues.apache.org/jira/browse/PDFBOX-2606
> Project: PDFBox
> Issue Type: Bug
> Components: Rendering
> Affects Versions: 2.0.0
> Reporter: simon steiner
> Assignee: John Hewson
>
> when {{/usr/share/fonts}} is not available:
> {code}
> Jan 16, 2015 11:32:57 AM org.apache.pdfbox.pdmodel.font.ExternalFonts getType1FallbackFont
> SEVERE: No fallback font for 'Helvetica-Bold', dumping debug information:
> Jan 16, 2015 11:32:57 AM org.apache.pdfbox.pdmodel.font.ExternalFonts getType1FallbackFont
> SEVERE:
> Exception in thread "main" java.lang.IllegalStateException: No fonts available on the system for Helvetica-Bold
> at org.apache.pdfbox.pdmodel.font.ExternalFonts.getType1FallbackFont(ExternalFonts.java:270)
> {code}
> See the discussion in PDFBOX-2263.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)