summaryrefslogtreecommitdiff
path: root/include
AgeCommit message (Collapse)Author
2020-12-21xmlsecurity: handle MDP permission during PDF verifyMiklos Vajna
(cherry picked from commit 586f6abee92af3cdabdce034b607b9a046ed3946) Conflicts: include/vcl/filter/PDFiumLibrary.hxx vcl/source/filter/ipdf/pdfdocument.cxx vcl/source/pdf/PDFiumLibrary.cxx xmlsecurity/inc/pdfio/pdfdocument.hxx xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx xmlsecurity/source/helper/pdfsignaturehelper.cxx (cherry picked from commit 00479937dc071246cc27f33fd6397668448a7ed9) Change-Id: I626fca7c03079fb0374c577dcfe024e7db6ed5b3 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107966 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-12-21xmlsecurity: pdf incremental updates that are non-commenting are invalidMiklos Vajna
I.e. it's OK to add incremental updates for annotation/commenting purposes and that doesn't invalite existing signatures. Everything else does. (cherry picked from commit 61834cd574568613f0b0a2ee099a60fa5a8d9804) Conflicts: include/vcl/filter/PDFiumLibrary.hxx vcl/source/pdf/PDFiumLibrary.cxx xmlsecurity/qa/unit/signing/signing.cxx xmlsecurity/source/pdfio/pdfdocument.cxx xmlsecurity/workben/pdfverify.cxx Change-Id: I4607c242b3c6f6b01517b02407e9e7a095e2e069 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107944 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-12-21pdfium: only init pdfium library one and destroy on LO exitTomaž Vajngerl
With more and more usage of PDFium, it is hard to keep track of the life-time of the PDFium library, so it can happen that a FPDF_DestroyLibrary happens when we still have another instance where PDFium is still use. The result of this is a crash. To prevent this, just initialize the library once and delete, when on LO exit. This can be improved in the future to only keep the library active when in actual use. Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95391 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 067a8a954c8e1d8d6465a4ab5fb61e93f16c26c2) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/95933 Tested-by: Tomaž Vajngerl <quikee@gmail.com> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 3538b83c8d83e66f63c745bd769d118117704026) Conflicts: vcl/qa/cppunit/pdfexport/pdfexport.cxx vcl/source/filter/ipdf/pdfread.cxx vcl/source/graphic/VectorGraphicSearch.cxx Change-Id: I5c7e5de7f8b97d10efb394c67c7a61b976c8d57c Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107943 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2020-12-21xmlsecurity: detect unsigned incremental update between signaturesMiklos Vajna
(cherry picked from commit 7468d5df5ec79783eae84b62bdc5ecf12f0ca255) Conflicts: vcl/source/filter/ipdf/pdfdocument.cxx xmlsecurity/inc/pdfio/pdfdocument.hxx xmlsecurity/qa/unit/pdfsigning/pdfsigning.cxx xmlsecurity/source/pdfio/pdfdocument.cxx Change-Id: I269ed858852ee7d1275adf340c8cc1565fc30693 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/99510 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
2019-11-27Added Orientation argument to LOKIT renderFontMert Tumer
method for rendering watermarks with angle Reviewed-on: https://gerrit.libreoffice.org/82404 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> (cherry picked from commit 1dd66357752b01fbf3f1aee9966a55d4a16038e4) Change-Id: Id422ed62e4f78390661e4e1efa45101af9ecfc23 Reviewed-on: https://gerrit.libreoffice.org/83937 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-10-09shave 10% off load time of large docx fileNoel Grandin
Change-Id: I5aacde7b6886bf47e79d055639e1b911da3be168 Reviewed-on: https://gerrit.libreoffice.org/78900 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> (cherry picked from commit 096b91ee15e2686d4eb7118fdb9688ba9dbc44b2) Reviewed-on: https://gerrit.libreoffice.org/78901 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Andras Timar <andras.timar@collabora.com> (cherry picked from commit 4659671f3c696a27139a4df98dc0894548169ace) Reviewed-on: https://gerrit.libreoffice.org/80504 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-09-27lok: deduplicate code related to notifyDocumentSizeChanged() callTamás Zolnai
co-author: Michael Meeks <michael.meeks@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/79498 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit e9260633df07b6796b19bc92523671cb345597a1) Change-Id: Ia4cef7b23fc682ec32aeb9be4dcdd582464c64e9 Reviewed-on: https://gerrit.libreoffice.org/79624 Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2019-09-27lok: send an invalidation by document size changeTamás Zolnai
It was sent by the kit code earlier. Now we move it to the LO core code, so we can optimize it later. co-author: Michael Meeks <michael.meeks@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/79491 Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> Tested-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit cd7ff1797d754018db1d47888781c9d7ecb24dcf) Change-Id: Id0a8991016dbe8d13891071e2d5b4c9250720da9 Reviewed-on: https://gerrit.libreoffice.org/79617 Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com> Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
2019-08-29sc: LOK: commit cell edits before saveascd-6.0-29-20190828Ashod Nakashian
Users typically don't recognize that changes done to a cell need to be committed (typically by hitting RETURN) before they are saved to file. This is especially true on the web. This patch commits any in-flight changes before SaveAs. This is currently done only for LOK and unconditionally at that. This can be controlled via a flag, if there is such a use-case. Change-Id: I2a88b2f1df47be764058f4505561b22830d9d67a Reviewed-on: https://gerrit.libreoffice.org/78012 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com> (cherry picked from commit cc7eb4d345e3fede698a3f255c1938d275305c14) Reviewed-on: https://gerrit.libreoffice.org/78149 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-06-12tdf#125360: PPTX: Shape fill transparency is not exportedTamás Zolnai
.. if the original shape fill is defined with a theme Override the alpha value with the current value get from FillTransparence API attirbute even if the color is defined with a style or a color scheme. Reviewed-on: https://gerrit.libreoffice.org/72596 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit 259d01a34d27df2fbfd11c3bf6fe9dc508ff6ac2) Change-Id: I09d26238a9c2b501279e6749687dc535e614bbd6 Reviewed-on: https://gerrit.libreoffice.org/72617 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-06-12tdf#125346: PPTX export: Shape has wrong fill color comming from themeTamás Zolnai
Write the correct theme path to the InteropGrabBag, the same path what is generated and checked in the export code. Reviewed-on: https://gerrit.libreoffice.org/72500 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit a8bba60e8b655167ad91edcd0c2d1723d525b546) Change-Id: I32617c1a11cf3bafb142f7c8839b498aaac49aa0 Reviewed-on: https://gerrit.libreoffice.org/72522 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-05-03lok: allow paste content to popup dialogHenry Castro
Change-Id: I1893d52df505bc43428c37a624ca05c569ba1bc0 Reviewed-on: https://gerrit.libreoffice.org/70958 Tested-by: Jenkins Reviewed-by: Henry Castro <hcastro@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/71369 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-04-24lok: emit ProfileZone data in messages when requested.Michael Meeks
Change-Id: I42a773e2d5b8e4deeafa8eeb2785913db36a47d7 Reviewed-on: https://gerrit.libreoffice.org/70688 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/70766 Reviewed-by: Tor Lillqvist <tml@collabora.com> Tested-by: Tor Lillqvist <tml@collabora.com>
2019-04-15LOK: support for ordering/moving partsAshod Nakashian
Currently reordering of slides is only supported for presentations, although it is provisioned for spreadsheets as well. Change-Id: I6c35066d6a5ef7586d34a8e8b89db69a20b86572 Reviewed-on: https://gerrit.libreoffice.org/69612 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-15LOK: getPartInfo now returns list of selected partsAshod Nakashian
For spreadsheets, selected parts are still unimplemented, so returns false for all. For presentations, visible parts seem to be always return false at load time. Change-Id: I90c79617f88deec98849bb374ca0ba177cd9c9af Reviewed-on: https://gerrit.libreoffice.org/69611 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-15slide-sorter: multiple selectionAshod Nakashian
Change-Id: I8624de25b0bb66020002890f33758e52059a24ab Reviewed-on: https://gerrit.libreoffice.org/69610 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-13sd: unit-test to check that PDF stream is shared among Graphic instancesAshod Nakashian
Change-Id: Iebd85e5e60c76e6d0756d15e1fa6107a3fcc837d Reviewed-on: https://gerrit.libreoffice.org/70162 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-11Run clang-formatTor Lillqvist
Change-Id: I6287aee720bbddcb28142bcbdb910b89e942c4ec
2019-04-11Don't crash if the BSTR pointer in a VARIANT is (weirdly) nullTor Lillqvist
Change-Id: I8473b1f411a45c7c17e742ca0d69245d77f078f7
2019-04-11tdf#82009 TreeList move painting of drag target into Paint func.Tomaž Vajngerl
When we drag a entry in TreeListBox, we execute a PaintDDCursor which paints a "cursor" of a possible drag target (for example to show where the entry will be moved to if we want to change the order). The problem with this fuction is that it paints a line directlly at that location, and that it uses invert raster operation to draw a line. So to hide the line it just needs to draw again. On MacOS this invertion causes a problem and draws the whole area black, which is the cause of this bug. So instead of inverting the drawing of the drag target cursor has now been moved into the main Paint method, where it redraws the whole entry, and if present, also the drag target cursor. This means that all we need to do is Invalidate the entry, which then just gets redrawn in a normal Paint pass. One exception is still MacOS, which doesn't invalidate the entry, but redraws the entry directly. DnD is MacOS is a bit different as it is not async (if I understand correctly) so the invalidate has no effect. Reviewed-on: https://gerrit.libreoffice.org/70521 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 14abbc6e86ba234996dfed477a54030adeac2a52) Change-Id: I8542f47940a3b90114ea4bbbac57fd303ca3434b
2019-04-05support opacity for widget definition draw SVGsTomaž Vajngerl
This opacity influences the whole shape (stroke and fill). Reviewed-on: https://gerrit.libreoffice.org/70292 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit fcb00ac8ebe2acb429f09ef5b728b8c73a5bbc37) Change-Id: I82e10e07dbf2f321805b55a5f4831a513e52dab8
2019-04-04tdf#124155 fix slider to not go beyond rect boundsTomaž Vajngerl
We need to ask the NWF for the size of the thumb and not just use the hard-coded value. Reviewed-on: https://gerrit.libreoffice.org/70201 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 9956cf0692058414ef3efdb0e8058fbb0b39f6bc) Change-Id: I98c6b5782c6a043fc358198ddf844d36d7aa90d6
2019-04-04tdf#124155 change "gradient tab page" - increment & angle sliderTomaž Vajngerl
Remove slider for increments as the increments should better be left to "auto" and rarely modified (setting a value means it will use a limitied amount of increments, but auto effectively means as much as it is needed and can use the native backend for drawing). OTOH use a slider for setting the "angle" as it is already present in hatch tab page. Angle needs a slider as it is usually one of the main properties of a gradient (especially linear). Increase the tab pages a bit (10px on every side) to have a bit of breating space for all the widgets. Reviewed-on: https://gerrit.libreoffice.org/70175 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 994b41a6c69d20637dcb95894c385f5c0102d600) Change-Id: I66167fe2c97b53bc3627237279332bdd59fb03d7
2019-04-03pdfium: Returning a const std::shared_ptr<...>& is not recommended.Jan Holesovsky
Change-Id: Iff6acef712c5b95c8cc222fc5293c9304b1c03ec
2019-04-03pdfium: Use std::vector to hold the PdfData.Jan Holesovsky
This fixes the destruction of the static cache of the PDF data; without this, there were already missing uno runtime info. Change-Id: I877c9ccf96c4b7eabf3d643e17f324d86d987f94
2019-04-03pdfium: Import PDF with unloaded images.Ashod Nakashian
Change-Id: I5e4a16ff38b9643127ce16879b35f456c13bcff8 Reviewed-on: https://gerrit.libreoffice.org/56268 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com>
2019-04-03pdfium: Keep the PDF data in memory, so that we can really share them.Jan Holesovsky
Otherwise the swap out / swap in creates new copy of the underlying PDF stream. Change-Id: I88a16a69143783a998201e183bea1a9553e337bd Reviewed-on: https://gerrit.libreoffice.org/56266 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/69626 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-04-03pdfium: Share the GfxLink for PDF files.Jan Holesovsky
Partially based on work by Ashod Nakashian, thanks! Reviewed-on: https://gerrit.libreoffice.org/56265 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com> Change-Id: Id7e8c4543368b0caf3e459abaff8c53997779c83 Reviewed-on: https://gerrit.libreoffice.org/69625 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-04-01tdf#124150 increase size of color valueset widgetTomaž Vajngerl
Size of the color value set can be set through settings, but there was no setter. Added a setter and set it to a bigger value so it is better suited for touch. Change-Id: I8c9b17f7379c4702b0faf7847f1e6292cd89b0d0 Reviewed-on: https://gerrit.libreoffice.org/70031 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit c2108dd683ec7ff0bcaac8456c6cce9610a2993a)
2019-03-28Revert "pdfium: Share the GfxLink for PDF files."Jan Holesovsky
This reverts commit 62654a8c29b945d00afe9f32e87b44ba0d8b84a2.
2019-03-28Revert "pdfium: Keep the PDF data in memory, so that we can really share them."Jan Holesovsky
This reverts commit 6a96ea6378986ad7a8951dde583ae590edae1a65.
2019-03-27MSO lockfiles: Deduplicate MSO lock file reading codeTamás Zolnai
The removed code was extracted to MSODocumentLockFile class so use that class here too. Use openStreamNoLock() for reading MSO lockfiles, because otherwise we can not read lock files written by MSO. Change-Id: Ib31cb9f3783d0b0ce784f900821047b9d32156f2 Reviewed-on: https://gerrit.libreoffice.org/69759 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit ad47e9b1c0d3f1720665b2786090e8c0927b5b45) Reviewed-on: https://gerrit.libreoffice.org/69844 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Generate MSO lock files when the related MSO compat. option is setTamás Zolnai
Added a new compatibility option to the Tools -> Load / Save -> Microsoft. When this option is set on the UI or or set in the configuration files LO generates lock files for MSO supported file formats, similar to the lock files MSO generates itself. Reviewed-on: https://gerrit.libreoffice.org/69678 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit 41dc917b9b55b8c0c4307ffc58a1fb7257df2b69) Change-Id: I2f882723841162add01be9d3f7285a5162a60331 Reviewed-on: https://gerrit.libreoffice.org/69843 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Introduce new lockfile handler for MSO like lockfilesTamás Zolnai
* Implement writing of MSO lockfiles * Grab the already implemented parsing code (tryMSOwnerFile method) and put it together into one class * Add tests about the generated URL for lockfiles and the lockfile content * MSO lockfiles are not written yet by LO, next step is to integrate this code into the locking mechanism. Reviewed-on: https://gerrit.libreoffice.org/69582 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit 5db1e20b8b0942dac2d50f3cd34532bb61147020) Change-Id: I3b0ed1975cd57dfd006d4e1890b23c307890de5c Reviewed-on: https://gerrit.libreoffice.org/69842 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Add style options to redaction exportMuhammet Kara
* Add 2 new uno command aliases to handle 2 different styles of redaction export/sanitization: * .uno:RedactedExportBlack & .uno:RedactedExportWhite * Replace the single export button with the 2 new buttons * Add a new toolbox names .uno:RedactedExportToolbox which consists of the new 2 commands. It will be added to the Redaction toolbar after we solve the icon issue. * Now new redaction shapes are named as RectangleRedactionShape or FreeformRedactionShape based on their type. * While exporting to PDF, a seamless step of "Sanitization" takes place, in which, all shapes in the Draw doc are traversed and turned into opaq black or white (with black border) shapes, then the whole doc is converted into bitmap (page by page). * After the export operation is completed. All shapes are converted back to the usual redaction style (gray and transparent). * Icon issue: * We need 2 new icons for our new commands, one for black redaction shapes without border, and one for white redaction shapes with black border. * I tried adding links to a current icon, but it didn't work, so they are iconless for now. * Next to do: Handle icon issue, and take the redaction implementation into a separate helper class because it is growing fast. Change-Id: I9b2b7716289b800cdbe7bf3ffa4a442fe5afc474 Reviewed-on: https://gerrit.libreoffice.org/68072 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/69836 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Use named shapes for redactionMuhammet Kara
Change-Id: Ibb55bd503d264b618c3fbebfdbcf3fe9958c6783 Reviewed-on: https://gerrit.libreoffice.org/68031 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/69835 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Support bitmap PDF export for RedactionMuhammet Kara
* Add a new parameter IsRedactMode (SID_IS_REDACT_MODE) to .uno:ExportDirectToPDF * Make sure the new param makes it into PDFExport as part of FilterData * Hijack the metafile before being sent to ImplExportPage(), convert to bitmap, and replace the original * Add a new entry to GenericCommands.xcu to make our button with param visible * Nitpick: For things to be included in the bitmap conversion, they need to be added to the metafile before the conversion in PDFExport::ExportSelection(). Things added after that point (inside ImplExportPage() for example) will not be bitmapped/pixelized Change-Id: Iec7020917da920a968ea969b98e53f17eadaa275 Reviewed-on: https://gerrit.libreoffice.org/67108 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/69833 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Redaction: Adjust offset for multiple Calc pagesMuhammet Kara
* Add an enum and some methods to DocumentToGraphicRenderer to differentiate between the doc/module types: isWriter(), isCalc(), isImpress() * Put some checks for module/doc type * The result seems ok for a Calc document of multiple sheets with hundreds of pages Change-Id: Idf3e1966d4239df30a48a947a95c9085c25ee1bb Reviewed-on: https://gerrit.libreoffice.org/66605 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/69815 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Add method DocumentToGraphicRenderer::getPageCount()Muhammet Kara
And use that in sfx2 Redaction code to be independent of the document/module type Change-Id: Ic206f7a10a27d8d44566df34a10d009a34adf0a5 Reviewed-on: https://gerrit.libreoffice.org/65971 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/69813 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27svtools: expose document position in DocumentToGraphicRendererMiklos Vajna
Writer pages always have an offset inside the root frame, and this is visible in the generated metafile as well. The offset is minimal for a small window and a single page, but the vertical offset increases with every page. Make this information visible, so sfx2 can compensate this. This is somewhat similar to what SfxObjectShell::DoDraw_Impl() does, but that works for the first page only (use case is thumbnail generation), while this is 0 offset for Calc/Impress and a proper offset for all Writer pages. Change-Id: I1075c98faf74f9e77c916572b4d63d40fbd80ab1 Reviewed-on: https://gerrit.libreoffice.org/65850 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins Reviewed-on: https://gerrit.libreoffice.org/69758 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27Redaction: First stepsMuhammet Kara
- Add an uno command to create an empty draw document - Create a meta file from the first page of a Writer document - Insert meta file to the draw page - Doesn't work with normal/default view on big/high-res screens because of a bug in the MapModes. Manually setting zoom level to %200 or "Page Width" (to get rid of the extra space around the actual page) works for now as workaround. Change-Id: I05a987617efdda6690400ef550b81b58b21aa27e Reviewed-on: https://gerrit.libreoffice.org/64858 Tested-by: Jenkins Reviewed-by: Muhammet Kara <muhammet.kara@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/69728 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-27tdf#124146 support posting of gesture event for LOKitTomaž Vajngerl
Reviewed-on: https://gerrit.libreoffice.org/69657 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 4a68361d578fe3bf313f80d8e186079bd34b2300) Change-Id: I51845f2e41dbcbe1ae6cb0a18cf9f42d5549968b
2019-03-27tdf#124146 add (general) gesture event support to VCLTomaž Vajngerl
Reviewed-on: https://gerrit.libreoffice.org/69655 Tested-by: Jenkins Reviewed-by: Tomaž Vajngerl <quikee@gmail.com> (cherry picked from commit 6b476080da0678faa59606ef814760bd4235de24) Change-Id: I766930bb35071442e132b91477cd3d55e8f00f48
2019-03-26pdfium: Keep the PDF data in memory, so that we can really share them.Jan Holesovsky
Otherwise the swap out / swap in creates new copy of the underlying PDF stream. Change-Id: I88a16a69143783a998201e183bea1a9553e337bd Reviewed-on: https://gerrit.libreoffice.org/56266 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com> Reviewed-on: https://gerrit.libreoffice.org/69626 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-03-26pdfium: Share the GfxLink for PDF files.Jan Holesovsky
Partially based on work by Ashod Nakashian, thanks! Reviewed-on: https://gerrit.libreoffice.org/56265 Reviewed-by: Ashod Nakashian <ashnakash@gmail.com> Tested-by: Ashod Nakashian <ashnakash@gmail.com> Change-Id: Id7e8c4543368b0caf3e459abaff8c53997779c83 Reviewed-on: https://gerrit.libreoffice.org/69625 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-03-26vcl: svx: misc improvements to pdfium importingAshod Nakashian
Change-Id: I58f2fd973a731b148f40b37139cd74bac097a7d2 Reviewed-on: https://gerrit.libreoffice.org/69621 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-03-18MSForms: Add a drop-down button for drop-down form fieldTamás Zolnai
* Introduce a editing frame with a button for drop-down form field. ** The frame is mouse transparent. ** Pushing the button opens the popup window with the items of the field. * The button is visible when the cursor is inside the field. Reviewed-on: https://gerrit.libreoffice.org/68961 Tested-by: Jenkins Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com> (cherry picked from commit 10be5b6ce972dff517f3ceed41cab04d3e051f57) Change-Id: I5c7db138d14380899fee046c95a5afe14cfea213 Reviewed-on: https://gerrit.libreoffice.org/69195 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-15LOK: re-factor async key & mouse event re-posting.Michael Meeks
A fairly pure re-factor, although adding disposed window checking to a number of sites with a warning. Moves the event emission helpers from VCL into SfxLokHelper: we're going to need more view / integration here next anyway. Removes lots of copy/paste horror. Change-Id: I279c11a1d8093b4feeeb6b7850f500806fff80dd Reviewed-on: https://gerrit.libreoffice.org/69218 Tested-by: Jenkins Reviewed-by: Michael Meeks <michael.meeks@collabora.com> Reviewed-on: https://gerrit.libreoffice.org/69268 Reviewed-by: Jan Holesovsky <kendy@collabora.com> Tested-by: Jan Holesovsky <kendy@collabora.com>
2019-03-12Move the Help URL to a different config pathAshod Nakashian
This partially reverts e5a0bafa330c58d6c9352d3acbe4e97fafa1ad56 and simplifies the Help URL configuration. Change-Id: Icc7c31b8955f3df978b57dbd8aa8816a9e1f98ad Reviewed-on: https://gerrit.libreoffice.org/69106 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>
2019-03-12Make the Help URL configurableAshod Nakashian
When the Help URL is blank, the Help buttons are hidden LOK (but not desktop). Change-Id: Ibd76452108d1e3a92fb43f2c0af0586b0cbed073 Reviewed-on: https://gerrit.libreoffice.org/69071 Reviewed-by: Andras Timar <andras.timar@collabora.com> Tested-by: Andras Timar <andras.timar@collabora.com>