[Libreoffice-commits] core.git: filter/Configuration_filter.mk filter/source writerperfect/source
David Tardon (via logerrit)
logerrit at kemper.freedesktop.org
Sun Sep 27 17:03:57 UTC 2020
filter/Configuration_filter.mk | 2
filter/source/config/fragments/filters/PocketWord_File.xcu | 29 ++++++++++
filter/source/config/fragments/types/writer_PocketWord_File.xcu | 29 ++++++++++
writerperfect/source/writer/MSWorksImportFilter.cxx | 3 +
4 files changed, 63 insertions(+)
New commits:
commit 1e6e891016ae926868de493ab0e29871a2d06b95
Author: David Tardon <dtardon at redhat.com>
AuthorDate: Sun Sep 27 15:29:44 2020 +0200
Commit: David Tardon <dtardon at redhat.com>
CommitDate: Sun Sep 27 19:03:20 2020 +0200
restore PocketWord filter, this time backed by libwps
Change-Id: If9843ae717f58e683252c8ea55360a567978395e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/103514
Tested-by: Jenkins
Reviewed-by: David Tardon <dtardon at redhat.com>
diff --git a/filter/Configuration_filter.mk b/filter/Configuration_filter.mk
index e71ffacf8f25..d53afa704fc9 100644
--- a/filter/Configuration_filter.mk
+++ b/filter/Configuration_filter.mk
@@ -367,6 +367,7 @@ $(eval $(call filter_Configuration_add_types,fcfg_langpack,fcfg_writer_types.xcu
Palm_Text_Document \
StarOffice_Writer \
writer_EPUB_Document \
+ writer_PocketWord_File \
))
$(eval $(call filter_Configuration_add_filters,fcfg_langpack,fcfg_writer_filters.xcu,filter/source/config/fragments/filters,\
@@ -415,6 +416,7 @@ $(eval $(call filter_Configuration_add_filters,fcfg_langpack,fcfg_writer_filters
Palm_Text_Document \
StarOffice_Writer \
EPUB \
+ PocketWord_File \
))
# fcfg_web
diff --git a/filter/source/config/fragments/filters/PocketWord_File.xcu b/filter/source/config/fragments/filters/PocketWord_File.xcu
new file mode 100644
index 000000000000..1ce83aa68fe4
--- /dev/null
+++ b/filter/source/config/fragments/filters/PocketWord_File.xcu
@@ -0,0 +1,29 @@
+<!--
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+-->
+ <node oor:name="PocketWord File" oor:op="replace">
+ <prop oor:name="FileFormatVersion"><value>0</value></prop>
+ <prop oor:name="Type"><value>writer_PocketWord_File</value></prop>
+ <prop oor:name="DocumentService"><value>com.sun.star.text.TextDocument</value></prop>
+ <prop oor:name="UIComponent"/>
+ <prop oor:name="FilterService"><value>com.sun.star.comp.Writer.MSWorksImportFilter</value></prop>
+ <prop oor:name="TemplateName"/>
+ <prop oor:name="UIName">
+ <value>Pocket Word</value>
+ </prop>
+ <prop oor:name="Flags"><value>IMPORT ALIEN 3RDPARTYFILTER</value></prop>
+ </node>
diff --git a/filter/source/config/fragments/types/writer_PocketWord_File.xcu b/filter/source/config/fragments/types/writer_PocketWord_File.xcu
new file mode 100644
index 000000000000..3f146aba5e26
--- /dev/null
+++ b/filter/source/config/fragments/types/writer_PocketWord_File.xcu
@@ -0,0 +1,29 @@
+<!--
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+-->
+ <node oor:name="writer_PocketWord_File" oor:op="replace" >
+ <prop oor:name="DetectService"><value>com.sun.star.comp.Writer.MSWorksImportFilter</value></prop>
+ <prop oor:name="URLPattern"/>
+ <prop oor:name="Extensions"><value>psw</value></prop>
+ <prop oor:name="MediaType"><value>application/x-pocket-word</value></prop>
+ <prop oor:name="Preferred"><value>false</value></prop>
+ <prop oor:name="PreferredFilter"><value>PocketWord File</value></prop>
+ <prop oor:name="UIName">
+ <value>Pocket Word</value>
+ </prop>
+ <prop oor:name="ClipboardFormat"><value>doctype:pwi</value></prop>
+ </node>
diff --git a/writerperfect/source/writer/MSWorksImportFilter.cxx b/writerperfect/source/writer/MSWorksImportFilter.cxx
index 5339d9e3f202..ab0efc04f670 100644
--- a/writerperfect/source/writer/MSWorksImportFilter.cxx
+++ b/writerperfect/source/writer/MSWorksImportFilter.cxx
@@ -115,6 +115,9 @@ bool MSWorksImportFilter::doDetectFormat(librevenge::RVNGInputStream& rInput, OU
case libwps::WPS_RESERVED_1:
rTypeName = "writer_DosWord";
break;
+ case libwps::WPS_RESERVED_4:
+ rTypeName = "writer_PocketWord_File";
+ break;
default:
break;
}
More information about the Libreoffice-commits
mailing list