diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-05-22 16:20:18 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2018-05-22 19:30:25 +0200 |
commit | 4c2172a3e973bc6351107a3a1b554c77b40b75dd (patch) | |
tree | 23f46863d12dd137b9d8f40190328c517c66c974 /include/vcl/pdfextoutdevdata.hxx | |
parent | 2c1fb32e0b3f0c51edcbb861977d372ae4eaf5e4 (diff) |
tdf#106702 PDF export: fix missing images from Writer headers/footers
Position of an image is determined by the relevant bitmap scale metafile
action when recompressing images.
The same position was determined by PDFExtOutDevData "meta" info when
not recompressing images. This second rectangle was never correct for
images repeated in Writer headers/footers on non-first pages: the
position was relative to the page, while PDF export sets the map mode
(origin) of the output device during export, so such positions are
expected to be absolute ones.
The root of the problem seems to be that header images in Writer are
both repeated (as the user sees it) and unrepeated (as the doc model
sees it), and by the time we want to get its position, we only see the
unrepeated SdrObject.
Fix the problem by using the correct position from the scale action and
not from PDFExtOutDevData if possible.
(Also give up on running CppunitTest_vcl_pdfexport in the non-pdfium
case, most of the tests there do require pdfium anyway, and the growing
ifdef forest in that file just made it hard to read the code.)
Change-Id: I31c14d4bd223b2804859982542ebd6d5f9abd312
Reviewed-on: https://gerrit.libreoffice.org/54674
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Tested-by: Jenkins <ci@libreoffice.org>
Diffstat (limited to 'include/vcl/pdfextoutdevdata.hxx')
-rw-r--r-- | include/vcl/pdfextoutdevdata.hxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/vcl/pdfextoutdevdata.hxx b/include/vcl/pdfextoutdevdata.hxx index c260f8461fa7..03fa22b77c4d 100644 --- a/include/vcl/pdfextoutdevdata.hxx +++ b/include/vcl/pdfextoutdevdata.hxx @@ -99,7 +99,7 @@ public: PDFExtOutDevData( const OutputDevice& rOutDev ); virtual ~PDFExtOutDevData() override; - bool PlaySyncPageAct( PDFWriter& rWriter, sal_uInt32& rCurGDIMtfAction ); + bool PlaySyncPageAct( PDFWriter& rWriter, sal_uInt32& rCurGDIMtfAction, const GDIMetaFile& rMtf ); void ResetSyncData(); void PlayGlobalActions( PDFWriter& rWriter ); |