Class PDFTranscoder.OpenHtmlFontResolver

  • All Implemented Interfaces:
    org.apache.batik.bridge.FontFamilyResolver
    Enclosing class:
    PDFTranscoder

    public static class PDFTranscoder.OpenHtmlFontResolver
    extends java.lang.Object
    implements org.apache.batik.bridge.FontFamilyResolver
    • Constructor Detail

      • OpenHtmlFontResolver

        public OpenHtmlFontResolver()
    • Method Detail

      • resolve

        public org.apache.batik.gvt.font.GVTFontFamily resolve​(java.lang.String arg0,
                                                               org.apache.batik.bridge.FontFace arg1)
        Specified by:
        resolve in interface org.apache.batik.bridge.FontFamilyResolver
      • resolve

        public org.apache.batik.gvt.font.GVTFontFamily resolve​(java.lang.String family)
        Specified by:
        resolve in interface org.apache.batik.bridge.FontFamilyResolver
      • loadFont

        public org.apache.batik.gvt.font.GVTFontFamily loadFont​(java.io.InputStream arg0,
                                                                org.apache.batik.bridge.FontFace arg1)
                                                         throws java.lang.Exception
        Specified by:
        loadFont in interface org.apache.batik.bridge.FontFamilyResolver
        Throws:
        java.lang.Exception
      • getFamilyThatCanDisplay

        public org.apache.batik.gvt.font.GVTFontFamily getFamilyThatCanDisplay​(char arg0)
        Specified by:
        getFamilyThatCanDisplay in interface org.apache.batik.bridge.FontFamilyResolver
      • getDefault

        public org.apache.batik.gvt.font.GVTFontFamily getDefault()
        Specified by:
        getDefault in interface org.apache.batik.bridge.FontFamilyResolver
      • getStyle

        private java.lang.Float getStyle​(IdentValue fontStyle)
      • getWeight

        private java.lang.Float getWeight​(java.lang.Integer weight)
      • getWeight

        private java.lang.Float getWeight​(IdentValue weight)
      • addFontFaceFont

        private void addFontFaceFont​(java.lang.String fontFamilyNameOverride,
                                     IdentValue fontWeightOverride,
                                     IdentValue fontStyleOverride,
                                     java.lang.String uri,
                                     byte[] font1)
                              throws java.awt.FontFormatException
        Throws:
        java.awt.FontFormatException
      • addFontFile

        public void addFontFile​(java.io.File fontFile,
                                java.lang.String family,
                                java.lang.Integer weight,
                                BaseRendererBuilder.FontStyle style)
                         throws java.io.IOException,
                                java.awt.FontFormatException
        Throws:
        java.io.IOException
        java.awt.FontFormatException