ICEpdf
  1. ICEpdf
  2. PDF-133

Text Selection/highlight optimizations

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.0 - Beta
    • Fix Version/s: 4.0
    • Component/s: Core/Parsing
    • Labels:
      None
    • Environment:
      any

      Description

      Update the Text data structure to remove Geometric path instances. It appears that the path information is no longer needed and as a result bounds can be used for painting. A refactor is needed to convert the mouse or selection rectangle to page space and then apply paint and selection logic. This will greatly reduce the number of object created to support text extraction.

        Activity

        Repository Revision Date User Message
        ICEsoft Public SVN Repository #20264 Mon Jan 18 06:37:33 MST 2010 patrick.corless PDF-133 text selection optimization, removed geometric path cached data and updated rect and point selection algorithms to convert respective plots to page space, greatly reducing the number of object creations and transforms.
        Files Changed
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/graphics/text/GlyphText.java
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/graphics/text/LineText.java
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/views/common/TextSelectionPageHandler.java
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/Page.java
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/graphics/text/Text.java
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/graphics/text/WordText.java
        Commit graph MODIFY /icepdf/trunk/icepdf/core/src/org/icepdf/core/pobjects/graphics/text/AbstractText.java
        Patrick Corless created issue -
        Patrick Corless made changes -
        Field Original Value New Value
        Salesforce Case []
        Component/s Core [ 10022 ]
        Fix Version/s 4.0 [ 10222 ]
        Affects Version/s 4.0 - Beta [ 10212 ]
        Hide
        Patrick Corless added a comment -

        Thanks to Mark to do a peer review of the text selection code and noticing the large number of Geometric paths that where created for each page.

        I reviewed the text selection code and found two areas that could be improved. The first was to convert the mouse point or selection rectangle to page space before doing containment and intersection tests. Once the mouse coords where in the correct space there was no need to keep the geometric path around in the text object, the pre calculated bounds where all that where needed to calculate selected text.

        Checked in code, marking as fixed.

        Show
        Patrick Corless added a comment - Thanks to Mark to do a peer review of the text selection code and noticing the large number of Geometric paths that where created for each page. I reviewed the text selection code and found two areas that could be improved. The first was to convert the mouse point or selection rectangle to page space before doing containment and intersection tests. Once the mouse coords where in the correct space there was no need to keep the geometric path around in the text object, the pre calculated bounds where all that where needed to calculate selected text. Checked in code, marking as fixed.
        Patrick Corless made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

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

            Dates

            • Created:
              Updated:
              Resolved: