[Libreoffice-commits] core.git: include/vcl vcl/source
panoskorovesis (via logerrit)
logerrit at kemper.freedesktop.org
Tue Aug 3 22:53:14 UTC 2021
include/vcl/filter/SvmWriter.hxx | 1 +
vcl/source/filter/svm/SvmWriter.cxx | 15 +++++++++++++++
2 files changed, 16 insertions(+)
New commits:
commit c7dbab2d5e254bc38204b62a15d129be66417799
Author: panoskorovesis <panoskorovesis at outlook.com>
AuthorDate: Tue Aug 3 09:50:52 2021 +0300
Commit: Tomaž Vajngerl <quikee at gmail.com>
CommitDate: Wed Aug 4 00:52:40 2021 +0200
Add Handler for MapMode Write
The handler separates MetaMapModeAction::Write from metaact.hxx
Write implementation is now in SvmWriter.hxx
Change-Id: Ic0a2691eabb96a88ceafbe63af08566a38c6e469
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119922
Tested-by: Jenkins
Reviewed-by: Tomaž Vajngerl <quikee at gmail.com>
diff --git a/include/vcl/filter/SvmWriter.hxx b/include/vcl/filter/SvmWriter.hxx
index c27476bde453..dcd28b812803 100644
--- a/include/vcl/filter/SvmWriter.hxx
+++ b/include/vcl/filter/SvmWriter.hxx
@@ -58,4 +58,5 @@ public:
void TextLineHandler(MetaTextLineAction* pAction);
void OverlineColorHandler(MetaOverlineColorAction* pAction);
void TextAlignHandler(MetaTextAlignAction* pAction);
+ void MapModeHandler(MetaMapModeAction* pAction);
};
\ No newline at end of file
diff --git a/vcl/source/filter/svm/SvmWriter.cxx b/vcl/source/filter/svm/SvmWriter.cxx
index 73dacc499a5e..7ed7df861b76 100644
--- a/vcl/source/filter/svm/SvmWriter.cxx
+++ b/vcl/source/filter/svm/SvmWriter.cxx
@@ -211,6 +211,13 @@ void SvmWriter::MetaActionHandler(MetaAction* pAction, ImplMetaWriteData* pData)
}
break;
+ case MetaActionType::MAPMODE:
+ {
+ auto* pMetaAction = static_cast<MetaMapModeAction*>(pAction);
+ MapModeHandler(pMetaAction);
+ }
+ break;
+
/* default case prevents test failure and will be
removed once all the handlers are completed */
default:
@@ -477,4 +484,12 @@ void SvmWriter::TextAlignHandler(MetaTextAlignAction* pAction)
VersionCompatWrite aCompat(mrStream, 1);
mrStream.WriteUInt16(static_cast<sal_uInt16>(pAction->GetTextAlign()));
}
+
+void SvmWriter::MapModeHandler(MetaMapModeAction* pAction)
+{
+ mrStream.WriteUInt16(static_cast<sal_uInt16>(pAction->GetType()));
+ VersionCompatWrite aCompat(mrStream, 1);
+ TypeSerializer aSerializer(mrStream);
+ aSerializer.writeMapMode(pAction->GetMapMode());
+}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
More information about the Libreoffice-commits
mailing list