summaryrefslogtreecommitdiffstats
path: root/src/pdf/qpdfdocument.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Add missing includes (compile on debian failed)Martin Koller2018-07-091-0/+2
| | | | | Change-Id: I96c81d486050aa2e5c6990ee4abbda070f1235e7 Reviewed-by: Sérgio Martins <sergio.martins@kdab.com>
* Fix documentation of QPdfDocument classTobias Koenig2018-02-181-9/+16
| | | | | Change-Id: I8bc6327e86c4381966da759cbe6295b327c4d808 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add support for render rotation and flagsTobias Koenig2017-04-131-3/+46
| | | | | | | | | Extend the QPdfDocument::render() method with a parameter of new type QPdfDocumentRenderOptions to specify the rotation and additional render flags. Change-Id: I354acc7fad4d094a96cefcea4dfa3513f4955c47 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Fix emission of QPdfDocument::pageCountChanged signalTobias Koenig2017-02-271-8/+16
| | | | | | | | Emit the signal whenever the amount of pages changes on loading/closing the document. Change-Id: I0555a9cad93cb1f125ded19889eda91e08725592 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* change the license to LGPLv3 (with the commercial option)Shawn Rutledge2016-12-201-5/+20
| | | | | | Change-Id: I2caed38ece8067ecdad877dcc278f7828a3cb0bb Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* replace Q_NULLPTR and Q_DECL_OVERRIDEShawn Rutledge2016-12-161-6/+6
| | | | | Change-Id: Icf33776f70bdde71f320de0a129361ac28fd18c8 Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com>
* Fix loading of large PDF documentsTobias Koenig2016-08-241-2/+8
| | | | | | | | Call FPDFAvail_IsPageAvail multiple times and check return value, otherwise the page won't be loaded completely. Change-Id: I9a6de3443eec6819be9b6eaa2a5b054329da4f80 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Encapsulate locking into QPdfMutexLockerTobias Koenig2016-08-241-12/+17
| | | | | | | | | Create a subclass of QMutexLocker which always acts on the global pdfMutex instance. This way other components, outside of qpdfdocument.cpp, can lock/unlock the mutex as well. Change-Id: Id68abb24ac95b2f6d94b20682986a76549518495 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Refactor the state handling of QPdfDocumentTobias Koenig2016-08-191-17/+74
| | | | | | | | Introduce a status property, which describes the current status of the QPdfDocument during loading/closing workflow. Change-Id: I2c095c41cfaacb4cd325682def71f80ffe6ab6d9 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Reduce the critical sections of the PDF mutexTobias Koenig2016-08-081-16/+20
| | | | | | | | Guard only the FPDF_* function calls by the PDF mutex, to make the QPdfDocument kind of reentrant. Change-Id: I76d448dde2604bd258d140fe6bb667cdee9e93c9 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add metaData() accessor method to QPdfDocumentShawn Rutledge2016-08-081-1/+95
| | | | | Change-Id: Ib25ae8940ff8a35627093031a82c1f25c7c940fc Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add passwordChanged() signal to QPdfDocumentTobias Koenig2016-08-081-1/+12
| | | | | | | | The passwordChanged() signal is emitted whenever the password on the document is changed. Change-Id: I8c35274dba7160b81555eac5bbda37d47cb8c9b7 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add close() method to QPdfDocumentTobias Koenig2016-08-081-2/+28
| | | | | | | | | The close() method will close an open document and emit the aboutToBeClosed() signal, so that other component, which keep a pointer to QPdfDocument, can react to it. Change-Id: I93200eb0b4bf96479fc114b43c9f6f2af4d15ffa Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Add license header boilerplateSimon Hausmann2016-07-251-0/+21
| | | | | | | Commercial until we have figured out the licensing :) Change-Id: Ibf60ca98cf04ee23928794a96ae33f87608c3236 Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com>
* Smaller coding style fixesTobias Koenig2016-07-221-20/+34
| | | | | | | | Use Q_NULLPTR and const in a couple of places and reorder includes or remove unneeded includes. Change-Id: Iba999759750424d0251be95badd06b54c41783fa Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* Update to newer FPDF upstream versionSimon Hausmann2016-07-181-1/+1
| | | | | | | | This required extending the gyp2pri "parser" to add dependencies recursively and to have really primitive condition handling for targets. Change-Id: Icd343ec2be492c0cf4cfd013bf2d4594fe7ba5c3 Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com>
* Clean up the loadingSimon Hausmann2014-12-161-49/+62
| | | | Unify the load API and implementation to always go through FPDFAvail.
* Fix memory leak, destroy page after usageSimon Hausmann2014-12-161-0/+3
|
* Clean up error handlingSimon Hausmann2014-12-151-14/+10
|
* Provide unit test for password protected PDFsSimon Hausmann2014-12-151-2/+7
|
* Keep reading until all pages are availableSimon Hausmann2014-12-151-4/+26
|
* Prospective fix for namespace buildsSimon Hausmann2014-12-151-0/+4
|
* Provide async loading through QNetworkReplySimon Hausmann2014-12-151-17/+151
|
* Sprinkle global locks around the API callsSimon Hausmann2014-12-151-19/+15
| | | | | | The library is not thread-safe at all with plenty of global variables. The common use-case seems to be one PDF document per process, which perfectly matches Chromium's architecture.
* Allow loading documents synchronously from a QIODeviceSimon Hausmann2014-12-151-34/+51
|
* Added basic rendering and page size getterSimon Hausmann2014-12-151-0/+28
|
* Implement basic document loading from a fileSimon Hausmann2014-12-151-0/+96