summaryrefslogtreecommitdiff
path: root/sw/CppunitTest_sw_uibase_dochdl.mk
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.com>2020-04-22 16:25:51 +0200
committerMiklos Vajna <vmiklos@collabora.com>2020-04-22 20:08:20 +0200
commit8ad0c29f56e5069a3679560d404b603332dcf38a (patch)
treecb8c011fee039d8c27eb1de849071faa3fe02640 /sw/CppunitTest_sw_uibase_dochdl.mk
parent688a520111a2dd3ab4cb3b846b561936d8a887bf (diff)
sw: prefer ODF over RTF when pasting from Writer
Regression from commit e9e6d4b058e13165f3dde1ca7822eec97dfe8aa7 (tdf#116685: Make the RICHTEXT take precedence over EMBED_SOURCE., 2019-09-26), the problem was that now we always prefer RTF over ODF when pasting into Writer. The commit made sense for Calc->Writer paste, but it causes formatting loss for Writer -> Writer paste. The exact use-case was copy&paste of numberings where the pasted content got paragraph indent as direct formatting, so shift-tab at the paragraph start changed only the bullet type, not the indentation -- but it's easy to imagine several other cases where a roundtrip via ODF provides better results than RTF. Fix the problem by leaving the above commit in place, but extending SwTransferable::Paste() so that it prefers ODF over RTF in case of a Writer->Writer paste (and leaves the non-Writer -> Writer paste behavior unchanged to avoid the unwanted OLE objects). Change-Id: Ida745bba65c5a210021cea0d267c02900fc6398a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92705 Reviewed-by: Miklos Vajna <vmiklos@collabora.com> Tested-by: Jenkins
Diffstat (limited to 'sw/CppunitTest_sw_uibase_dochdl.mk')
-rw-r--r--sw/CppunitTest_sw_uibase_dochdl.mk73
1 files changed, 73 insertions, 0 deletions
diff --git a/sw/CppunitTest_sw_uibase_dochdl.mk b/sw/CppunitTest_sw_uibase_dochdl.mk
new file mode 100644
index 000000000000..14cf57687a8f
--- /dev/null
+++ b/sw/CppunitTest_sw_uibase_dochdl.mk
@@ -0,0 +1,73 @@
+# -*- Mode: makefile-gmake; tab-width: 4; indent-tabs-mode: t -*-
+#*************************************************************************
+#
+# 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/.
+#
+#*************************************************************************
+
+$(eval $(call gb_CppunitTest_CppunitTest,sw_uibase_dochdl))
+
+$(eval $(call gb_CppunitTest_use_common_precompiled_header,sw_uibase_dochdl))
+
+$(eval $(call gb_CppunitTest_add_exception_objects,sw_uibase_dochdl, \
+ sw/qa/uibase/dochdl/dochdl \
+))
+
+$(eval $(call gb_CppunitTest_use_libraries,sw_uibase_dochdl, \
+ comphelper \
+ cppu \
+ cppuhelper \
+ editeng \
+ sal \
+ sfx \
+ svl \
+ svx \
+ svxcore \
+ sw \
+ test \
+ unotest \
+ utl \
+ vcl \
+))
+
+$(eval $(call gb_CppunitTest_use_externals,sw_uibase_dochdl,\
+ boost_headers \
+ libxml2 \
+))
+
+$(eval $(call gb_CppunitTest_set_include,sw_uibase_dochdl,\
+ -I$(SRCDIR)/sw/inc \
+ -I$(SRCDIR)/sw/source/core/inc \
+ -I$(SRCDIR)/sw/source/uibase/inc \
+ -I$(SRCDIR)/sw/qa/inc \
+ $$(INCLUDE) \
+))
+
+$(eval $(call gb_CppunitTest_use_api,sw_uibase_dochdl,\
+ udkapi \
+ offapi \
+ oovbaapi \
+))
+
+$(eval $(call gb_CppunitTest_use_ure,sw_uibase_dochdl))
+$(eval $(call gb_CppunitTest_use_vcl,sw_uibase_dochdl))
+
+$(eval $(call gb_CppunitTest_use_rdb,sw_uibase_dochdl,services))
+
+$(eval $(call gb_CppunitTest_use_custom_headers,sw_uibase_dochdl,\
+ officecfg/registry \
+))
+
+$(eval $(call gb_CppunitTest_use_configuration,sw_uibase_dochdl))
+
+$(eval $(call gb_CppunitTest_use_uiconfigs,sw_uibase_dochdl, \
+ modules/swriter \
+))
+
+$(eval $(call gb_CppunitTest_use_more_fonts,sw_uibase_dochdl))
+
+# vim: set noet sw=4 ts=4: