summaryrefslogtreecommitdiff
path: root/emfio/inc/emfreader.hxx
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2020-12-09 09:38:48 +0100
committerMiklos Vajna <vmiklos@collabora.com>2020-12-09 10:46:31 +0100
commitca67839234e78fe6bea21ec39906d1bd71d34d47 (patch)
tree2003f700fa05bd24bea1efc890e9549aa3507391 /emfio/inc/emfreader.hxx
parentc81fea2e78d66c1978cb2340868c938ba9d6c9f1 (diff)
vcl: improve EMF+ -> WMF conversion
We throw away EMF fallback info when parsing EMF+ data. This means that the resulting GDIMetaFile (containing EMF+ data but no EMF fallback) is tricky to export to WMF, where EMF+ comments are not allowed. Improve the conversion result by re-parsing such EMF+ data with EMF+ disabled, and then converting the GDIMetaFile (containing EMF fallback data) to WMF. Change-Id: Ib2c0388f1344aef7f601ce9be59e4a8924e8085b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/107453 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'emfio/inc/emfreader.hxx')
-rw-r--r--emfio/inc/emfreader.hxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/emfio/inc/emfreader.hxx b/emfio/inc/emfreader.hxx
index 39d576b64aed..e580835fc083 100644
--- a/emfio/inc/emfreader.hxx
+++ b/emfio/inc/emfreader.hxx
@@ -35,6 +35,7 @@ namespace emfio
/// Another format is read already, can ignore actual EMF data.
bool mbReadOtherGraphicFormat = false;
basegfx::B2DTuple maSizeHint;
+ bool mbEnableEMFPlus = true;
bool ReadHeader();
// reads and converts the rectangle
@@ -49,6 +50,7 @@ namespace emfio
/// Parses EMR_COMMENT_MULTIFORMATS.
void ReadMultiformatsComment();
void SetSizeHint(const basegfx::B2DTuple& rSizeHint) { maSizeHint = rSizeHint; }
+ void SetEnableEMFPlus(bool bEnableEMFPlus) { mbEnableEMFPlus = bEnableEMFPlus; }
private:
template <class T> void ReadAndDrawPolyPolygon(sal_uInt32 nNextPos);