Bug 43107

Summary: Regular expression "\n" in replace field inputs "\n" instead of paragraph break
Product: LibreOffice Reporter: Christopher M. Penalver <christopher.m.penalver>
Component: UIAssignee: Not Assigned <libreoffice-bugs>
Status: NEW --- QA Contact:
Severity: normal    
Priority: medium CC: advapi32, alex, cno, cpohle, davian818, freedesktop, lionel, mightyiampresence
Version: 3.4.3 release   
Hardware: All   
OS: All   
See Also: https://launchpad.net/bugs/892476
https://bugs.freedesktop.org/show_bug.cgi?id=64144
Whiteboard:
i915 platform: i915 features:

Description Christopher M. Penalver 2011-11-20 05:20:33 UTC
Downstream bug may be found at:
https://bugs.launchpad.net/ubuntu/+source/libreoffice/+bug/892476

1) lsb_release -rd
Description:	Ubuntu 11.10
Release:	11.10

2) apt-cache policy libreoffice-calc
libreoffice-calc:
  Installed: 1:3.4.4-0ubuntu1~ppa1
  Candidate: 1:3.4.4-0ubuntu1~ppa1
  Version table:
 *** 1:3.4.4-0ubuntu1~ppa1 0
        500 http://ppa.launchpad.net/libreoffice/ppa/ubuntu/ oneiric/main i386 Packages
        100 /var/lib/dpkg/status
     1:3.4.3-3ubuntu2 0
        500 http://us.archive.ubuntu.com/ubuntu/ oneiric/main i386 Packages

3) What is expected to happen in LibreOffice Calc is when one of the cells contains a line break -> Edit -> Find and Replace... -> in the "Search for" drop down \n -> in the "Replace with" drop down \n -> Regular expression button checked is the line break is replaced with a paragraph break as noted in http://help.libreoffice.org/Common/List_of_Regular_Expressions

4) What happens instead is the line break is replaced with the characters \n
Comment 1 Christopher M. Penalver 2011-11-20 05:21:38 UTC
*** Bug 43086 has been marked as a duplicate of this bug. ***
Comment 2 Winfried Donkers 2012-05-06 23:30:22 UTC
I think this is a duplicate of bug44398, i.e. isn't this a more general problem than just \n?

(behaviour confirmed with version 3.5.3release, details entered in comment with bug 44398)

*** This bug has been marked as a duplicate of bug 44398 ***
Comment 3 Christopher M. Penalver 2012-05-06 23:51:50 UTC
Winfried Donkers, I do not agree with this being a duplicate of bug 44398, nor do I agree with bug 44398 being accepted as a valid report for that matter based on the title.

Many, purposefully or ignorantly, make wide-scoped "fix everything about a feature set" reports, as 44398's title is, and your subsequent comment https://bugs.freedesktop.org/show_bug.cgi?id=44398#c2 . This makes a report less likely to be resolved quickly.

However, this (43107) report is targeted, specific, and detailed.

Please do not toggle this report further unless you are submitting a patch. Thank you.
Comment 4 Cor Nouws 2012-10-06 21:02:53 UTC
In 3.5.7 rc1 or 3.6.2.2 use "\n\n" in the replace field.
That works for me.
Can you pls check that?
(I remeber in the late OOo times there was a change in this, but can't find the details now).

I intend to close this one soon
Comment 5 Alex Willmer 2012-10-08 14:08:56 UTC
(In reply to comment #4)
> In 3.5.7 rc1 or 3.6.2.2 use "\n\n" in the replace field.
> That works for me.
> Can you pls check that?

In Calc 3.6.2.2 (Build ID: da8c1e6) on Windows 7 64-bit, if I
 - use "\n\n" (excluding quotes) in the replace field
 - Click Replace all

Calc inserts those literal characters into the cell(s), not newline characters. Based on that I don't think this bug is fixed.
Comment 6 cpohle 2012-11-06 13:58:49 UTC
Using Version 3.6.3.2 on Mac OSX, \n is inserted as literal text (i.e., not as a newline) as well.
Comment 7 Johnny Baloney 2013-03-22 17:50:12 UTC
Version 3.6.5.2 (Build ID: 5b93205) on Linux. Same problem - neither \n nor \n\n work.
Comment 8 Jorendc 2013-07-09 10:18:39 UTC
*** Bug 64144 has been marked as a duplicate of this bug. ***
Comment 9 Nemo_bis 2014-11-01 21:51:51 UTC
Confirmed in 4.2.6.3 on Fedora (Build ID: 4.2.6.3-8.fc20).

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.