From c239b8d513fae662a4e3be85f85efb794d98d83d Mon Sep 17 00:00:00 2001 From: Jabiertxof Date: Mon, 16 Sep 2019 16:41:18 +0200 Subject: Allow paste preserving new lines into a flowtext element --- src/ui/tools/text-tool.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/ui/tools/text-tool.cpp') diff --git a/src/ui/tools/text-tool.cpp b/src/ui/tools/text-tool.cpp index 161b20aa2..5919d7fb2 100644 --- a/src/ui/tools/text-tool.cpp +++ b/src/ui/tools/text-tool.cpp @@ -1326,6 +1326,10 @@ bool sp_text_paste_inline(ToolBase *ec) if (textitem) { textitem->hide_shape_inside(); } + SPFlowtext *flowtext = dynamic_cast(tc->text); + if (flowtext) { + flowtext->fix_overflow_flowregion(false); + } // Fix for 244940 // The XML standard defines the following as valid characters // (Extensible Markup Language (XML) 1.0 (Fourth Edition) paragraph 2.2) @@ -1374,6 +1378,9 @@ bool sp_text_paste_inline(ToolBase *ec) if (textitem) { textitem->show_shape_inside(); } + if (flowtext) { + flowtext->fix_overflow_flowregion(true); + } DocumentUndo::done(ec->desktop->getDocument(), SP_VERB_CONTEXT_TEXT, _("Paste text")); -- cgit v1.2.3