ICEpdf
  1. ICEpdf
  2. PDF-839

Missing characters (T, A, t) in PDF

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 5.1.1
    • Fix Version/s: 5.1.2
    • Component/s: Core/Parsing
    • Labels:
      None
    • Environment:
      All

      Description

      With the provided PDF file, it is rendering with missing characters (T, A, and t for example).

        Activity

        Arran Mccullough created issue -
        Hide
        Patrick Corless added a comment -

        The root of the problem is related to the LiteralStringObject.getLiteralStringBuffer() method. The method is responsible converting the underlying string data to a string that can be drawn. In this particular case the font is of CID format which mean we check if each glyph can be represented. by font. We also check to see of the character ID is greater then one which is the root of the problem as the CID glyph id for T is zero in this case.

        The code block in question has a comment that glyphs should be zero or more. I do remember a few corner cases where zero character were not valid. I'll have to run a potential fix though qa to see what happens as this is a high risk change.

        Show
        Patrick Corless added a comment - The root of the problem is related to the LiteralStringObject.getLiteralStringBuffer() method. The method is responsible converting the underlying string data to a string that can be drawn. In this particular case the font is of CID format which mean we check if each glyph can be represented. by font. We also check to see of the character ID is greater then one which is the root of the problem as the CID glyph id for T is zero in this case. The code block in question has a comment that glyphs should be zero or more. I do remember a few corner cases where zero character were not valid. I'll have to run a potential fix though qa to see what happens as this is a high risk change.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #43816 Thu Dec 11 15:59:01 MST 2014 patrick.corless PDF-839 addressing zero based cid characters.
        Files Changed
        Commit graph MODIFY /icepdf/branches/icepdf-5.0.1/icepdf/core/src/org/icepdf/core/pobjects/LiteralStringObject.java
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #43817 Thu Dec 11 17:30:30 MST 2014 patrick.corless Creation of P03 for PDF-839.
        Files Changed
        Commit graph ADD /icepdf/tags/icepdf-5.1.1_P03
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #43901 Tue Jan 13 11:11:16 MST 2015 patrick.corless PDF-839 addressing zero based cid characters.
        Files Changed
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/LiteralStringObject.java
        Patrick Corless made changes -
        Field Original Value New Value
        Fix Version/s 5.1.2 [ 11872 ]
        Hide
        Patrick Corless added a comment -

        Applied fix to trunk as well.

        Show
        Patrick Corless added a comment - Applied fix to trunk as well.
        Hide
        Patrick Corless added a comment -

        Fix passed QA, marking as resolved.

        Show
        Patrick Corless added a comment - Fix passed QA, marking as resolved.
        Patrick Corless made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Patrick Corless made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Patrick Corless
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: