emfio/source/reader/emfreader.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
New commits: commit 8d3e7b2f5836106eac5172d8f4868bb540d652e6 Author: Bartosz Kosiorek <gan...@poczta.onet.pl> AuthorDate: Fri Jun 11 13:50:29 2021 +0200 Commit: Bartosz Kosiorek <gan...@poczta.onet.pl> CommitDate: Fri Jun 11 18:41:02 2021 +0200 EMF tdf#59814 tdf#142567 Align RestoreDC record with MSO implementation Some of WMF and EMF behaviours are undocumented. In that case, we are implementing the behaviour, observed in MS Office or MS Paint. With this commit the behaviour of import EMF RestoreDC records, will be the same as for MS Paint and MS Office. Change-Id: I73b65d14018f2667ffd59daf16ecc6d7ce9c1870 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117052 Tested-by: Jenkins Reviewed-by: Bartosz Kosiorek <gan...@poczta.onet.pl> diff --git a/emfio/source/reader/emfreader.cxx b/emfio/source/reader/emfreader.cxx index ac56c64db026..04f591a7eb9a 100644 --- a/emfio/source/reader/emfreader.cxx +++ b/emfio/source/reader/emfreader.cxx @@ -1101,8 +1101,10 @@ namespace emfio sal_Int32 nSavedDC; mpInputStream->ReadInt32( nSavedDC ); SAL_INFO( "emfio", "\t\t SavedDC Index: " << nSavedDC ); - if ( nSavedDC < 0 ) // For EMF values above -1 is ignored + if ( nSavedDC < 0 ) Pop( nSavedDC ); + else + Pop( -1 ); // For RestoreDC values above -1, treat as get last element } break; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits