Uploaded image for project: 'FOP'
  1. FOP
  2. FOP-2491

[PATCH] Adobe Reader error with OTF subset PDF

    XMLWordPrintableJSON

Details

    Description

      Symptom: Based on FOP 2.0 release, the open-type font can be embedded into PDF document, however, based on the testing with FOP 2.0, the google-noto-sans-Cjk font cannot be embedded into PDF document.

      How to repeat:
      1. Get FOP 2.0 library.
      2. Get Google-Noto-Sans from https://noto-website.storage.googleapis.com/pkgs/NotoSansCJKTC-hinted.zip.
      3. Set the fop.xconf as following:
      <font embed-url="file:///C:/Font/NotoSans.otf" embedding-mode="subset">
      <font-triplet name="Noto Sans CJK TC Regular" style="normal" weight="normal"/>
      </font>
      4. Set the FOP as following:
      <?xml version="1.0" encoding="UTF-8"?>
      <fo:root xmlns:fo="http://www.w3.org/1999/XSL/Format">
      <fo:layout-master-set>
      <fo:simple-page-master margin="2cm" page-width="21.0cm" page-height="29.7cm" master-name="A4-portrait">
      <fo:region-body/>
      </fo:simple-page-master>
      </fo:layout-master-set>
      <fo:page-sequence master-reference="A4-portrait">
      <fo:flow flow-name="xsl-region-body">
      <fo:block font-family="Noto Sans CJK TC Regular">Hello Noto-OTF!</fo:block>
      </fo:flow>
      </fo:page-sequence>
      </fo:root>
      5. Generate the PDF, there is no error reported.
      6. Open the PDF file in Acro-Reader, it will report the "cannot extract the embedded font" error.

      Attachments

        1. after.pdf
          9 kB
          Thanasis Giannimaras
        2. before.pdf
          9 kB
          Thanasis Giannimaras
        3. test.fo
          0.5 kB
          Thanasis Giannimaras
        4. fop.xconf
          0.5 kB
          Thanasis Giannimaras
        5. svnSubset.patch
          1 kB
          Thanasis Giannimaras

        Activity

          People

            Unassigned Unassigned
            leoyanghpcom@gmail.com Leo Yang
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: