Qt Contributors Summit 2022 - Program/QtPDF: Difference between revisions

From Qt Wiki
Jump to navigation Jump to search
m (CristianMaureiraFredes moved page QtPDF to Qt Contributors Summit 2022 - Program/QtPDF)
(Add session notes)
Line 11: Line 11:
==Notes==
==Notes==


(Taken by XXX)
(Taken by Samuel Gaist)


===Title===
=== Design ===
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
- Not a monolith Qt Quick Item on purpose


===Title===
- Page switching at the Image component level (new Image feature)


Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
- Password input is possible using a Document


- It's modular so that application can be as simple as just showing the content of a file or a more full featured application


===Title===
- Architecture is model view based (several different models handling various aspects such as links, search, bookmarks, etc.)
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
 
=== Improvements ===
- Cache
 
- Android support
 
- Layers
 
=== Help ===
- XFA ? ()
 
- Poppler in Qt Quick with same API ?
 
  - Too restrictive of a license
 
- Aleix Pol Gonzalez noted that Okular has a Qt Quick version
 
== QA ==
 
=== Has the security team reviewed the usage of PDF as a image format? (DOS through a crafted PDF image that kills your system through massive rasterization) ?  ===
  1) at least PDF was designed as a subset of PostScript to not be turing complete (no infinite loops), but yeah it could probably end up with a lot of processing
 
  2) Image can be remote and thus bring in additional data so is another attack vector
 
  3) Add on the TODO list of the security team
 
=== Parsing without rendering ? ===
  - Not with the current implementation
 
  - Qt4PDF could be an alternative but must be explored
 
=== Where are QtPDF sources ? ===
  - in the QtWebEngine module under src/pdf
 
=== Can QtPDF be built without building the whole of WebEngine ? ===
  - Yes, just configure with skip qtwebengine core
 
  - <nowiki>https://wiki.qt.io/QtPDF_Build_Instructions</nowiki>
 
=== What about image size ? ===
  - Can be a problem as with other image format
 
- There's a list of known size limits that can be used
 
=== Any interest in the project ? ===
  - It's not GPL only unlike poppler
 
  - Might require some API rework to make it more compatible with the other projects

Revision as of 11:38, 7 June 2022


Session Summary

Quick overview of what has been done (a bit more since https://youtu.be/y6-Khqrrz_U), and discussion of what could be done if the community is interested in helping (annotations, XFA, ??) Future of QtPDF vs. poppler: let's emphasize that we don't necessarily want to displace poppler in the open-source world, but I wonder if there is a chance for synergy, by harmonizing APIs (QTBUG-77517). Perhaps can discuss the future of rendering if there's time (what if https://youtu.be/JTjJpXd7zNc had turned out a bit better: we could render PDF sub-elements directly in the SG).

Session Owners

  • Shawn Rutledge

Notes

(Taken by Samuel Gaist)

Design

- Not a monolith Qt Quick Item on purpose

- Page switching at the Image component level (new Image feature)

- Password input is possible using a Document

- It's modular so that application can be as simple as just showing the content of a file or a more full featured application

- Architecture is model view based (several different models handling various aspects such as links, search, bookmarks, etc.)

Improvements

- Cache

- Android support

- Layers

Help

- XFA ? ()

- Poppler in Qt Quick with same API ?

  - Too restrictive of a license

- Aleix Pol Gonzalez noted that Okular has a Qt Quick version

QA

Has the security team reviewed the usage of PDF as a image format? (DOS through a crafted PDF image that kills your system through massive rasterization) ? 

  1) at least PDF was designed as a subset of PostScript to not be turing complete (no infinite loops), but yeah it could probably end up with a lot of processing

  2) Image can be remote and thus bring in additional data so is another attack vector

  3) Add on the TODO list of the security team

Parsing without rendering ?

  - Not with the current implementation

  - Qt4PDF could be an alternative but must be explored

Where are QtPDF sources ?

  - in the QtWebEngine module under src/pdf

Can QtPDF be built without building the whole of WebEngine ?

  - Yes, just configure with skip qtwebengine core

  - https://wiki.qt.io/QtPDF_Build_Instructions

What about image size ?

  - Can be a problem as with other image format

- There's a list of known size limits that can be used

Any interest in the project ?

  - It's not GPL only unlike poppler

  - Might require some API rework to make it more compatible with the other projects