Uploaded image for project: 'PDFBox'
  1. PDFBox
  2. PDFBOX-2530

Improve PDFDebugger

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 1.8.8, 2.0.0
    • 2.0.0
    • Utilities

    Description

      (This is an idea for the Google Summer of Code 2015)

      Our command line utility PDFDebugger (part of the command line pdfbox-app get it here, read description here, see the source code here) needs some improvements:

      • hex view
      • view of non printable characters
      • ✓ saving streams
      • binary copy & paste
      • ✓ Create a status line that shows where we are in the tree. (Like in the Windows REGEDIT)
      • ✓ Copy the current tree string into the clipboard (useful in discussions about details of a PDF)
      • ✓ (Optional, not sure if easy) Jump to specific place in the tree by entering tree string
      • ✓ ability to search in streams (very useful for content streams and meta data)
      • ✓ show images that are streams
      • ✓ show PDIndexed color lookup table, show the index value, the base and RGB color value sets when the mouse moves
      • ✓ show PDSeparation color
      • ✓ show PDDeviceN colors
      • optional, idea should be developed a bit: show meaningful explanation on some attributes, e.g. "appearance stream" when hovering over /AP
      • show font encodings and characters
      • ✓ display flag bits (e.g. Annotation flags) in a way that is easy to understand. There are probably others, I assume that the main work needs to be done only once
      • edit attributes (should be possible to enter values as decimal, hex or binary)
      • edit streams, while keeping or changing the compression filter
      • save altered PDF
      • ✓ color mark of certain PDF operators, especially Q...q and text operators (BT...ET). Ideally, it should help the user understand the "bracketing" of these operators, i.e. understand where a sequence starts and where it ends. (See "operator summary" in the PDF Spec) Other "important" operators I can think of are the matrix, font and color operators. A cool advanced thing would be to show the current color or the font in a popup when hovering above such an operator.

      To see a product with a similar purpose that is better than PDFDebugger, watch this video.

      I'm not asking to implement a clone of that product (I don't use it, all I know is that video), but we at PDFBox really need something that makes PDF debugging easier. As an example of how the current PDFDebugger prevented me from finding a bug quickly, see PDFBOX-2401 and search for "PDFDebugger".

      Prerequisites:

      • java programming, especially the GUI components
      • the ability to understand existing source code

      Using external software components is possible (must have Apache License or a compatible one), but should be decided on a case-by-case basis, we don't want to get too big.

      Development strategy: go from the easy to the difficult. The wished features are already sorted this way (mostly).

      Get introduced: download the source code with svn and build it with maven. Run PDFDebugger and view some PDFs to see the components of a PDF. Start with the file of PDFBOX-2401. Read up something about the structure of PDF on the web or from the PDF Specification.

      Mentor: Tilman Hausherr (European timezone, languages: german, english, french). To see the GSoC2014 project I mentored, go to PDFBOX-1915.

      Attachments

        1. hex_viewer_v1.diff
          65 kB
          khyrul bashar
        2. ArrayIndexOutOfBound_in_find_menu_resolved.diff
          1 kB
          khyrul bashar
        3. screenshot-3.png
          83 kB
          Tilman Hausherr
        4. screenshot-2.png
          79 kB
          Tilman Hausherr
        5. screenshot-1.png
          60 kB
          Tilman Hausherr
        6. Show_thumbnail_image.diff
          6 kB
          khyrul bashar
        7. sonarqube_issue_resolve_26_07.diff
          2 kB
          khyrul bashar
        8. Font_encoding_pane_feature_.diff
          18 kB
          khyrul bashar
        9. Font_encoding_pane_draft.diff
          17 kB
          khyrul bashar
        10. sonarqube_warning_for_method_length_resolved.diff
          4 kB
          khyrul bashar
        11. refactor_ZoomMenu_to_avoid_code_redundancy.diff
          3 kB
          khyrul bashar
        12. Javadoc_for_ZoomMenu_class.diff
          2 kB
          khyrul bashar
        13. Zoom_menu_refactored_and_enabled_for_images.diff
          17 kB
          khyrul bashar
        14. SonarQube_issues_resolved.diff
          7 kB
          khyrul bashar
        15. Content_stream_showing_issues_patch_updated.diff
          16 kB
          khyrul bashar
        16. Content_stream_showing_issues_patch.diff
          18 kB
          khyrul bashar
        17. Stream_text_showing_for_broken_streams.diff
          2 kB
          khyrul bashar
        18. 317669-p213.pdf
          2 kB
          Tilman Hausherr
        19. filters-screenshot.png
          89 kB
          Tilman Hausherr
        20. Class_cast_exception_in_page_mode_avoided.diff
          0.7 kB
          khyrul bashar
        21. Sonarqube_warning_resolved.diff
          17 kB
          khyrul bashar
        22. Stream_Showing_Feature.diff
          76 kB
          khyrul bashar
        23. Parent_dictionary_type_checking_for__f__and__flags.diff
          2 kB
          khyrul bashar
        24. Avoiding_NPE_for_null_Field_Type.diff
          4 kB
          khyrul bashar
        25. sonarqube_warning_resolve.diff
          1 kB
          khyrul bashar
        26. Flag_bits_showing_feature-redesigned.diff
          45 kB
          khyrul bashar
        27. FlagBitsPane-26-06-2015.diff
          47 kB
          khyrul bashar
        28. K4SystemFontsNotEmbeded218.pdf
          9 kB
          John Hewson
        29. Flag_bits_showing_feature.diff
          14 kB
          khyrul bashar
        30. parent_node_redirect_expand_disabled.diff
          3 kB
          khyrul bashar
        31. parent_node_redirect.diff
          2 kB
          khyrul bashar
        32. removed_redundant_codes.patch
          6 kB
          khyrul bashar
        33. openSelectedPath.diff
          1 kB
          khyrul bashar
        34. indexedcs.diff
          19 kB
          khyrul bashar
        35. DeviceNCS.diff
          13 kB
          khyrul bashar
        36. BracketsColorChooser.png
          34 kB
          Maruan Sahyoun
        37. separationCS.diff
          13 kB
          khyrul bashar
        38. tree.diff
          23 kB
          khyrul bashar
        39. treestatus.diff
          4 kB
          khyrul bashar
        40. treestatuspane.diff
          15 kB
          khyrul bashar
        41. PDFDebugger_StatusBar_01.png
          46 kB
          Tanay Abhra
        42. PDFDebugger_StatusBar.png
          156 kB
          Tanay Abhra

        Activity

          People

            kbashar khyrul bashar
            tilman Tilman Hausherr
            Votes:
            1 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: