Find character and replace with a new line

In a book document with many paragraphs.
In each paragraph I need to find the character ‘.’ and add after it a new line - not a new paragraph.

Here’s how i go about it at the moment

find : \ .

Replace .\n

but this does not work because it creates new paragraph rather than a new line within the same paragraph

Thanks

Did you consider that full stops at the end of sentences often (if not always in the addressed case) are followed by spaces?
In addition periods not followed by a space may be used with a different meaning.
Example:

Hkjhhjk ljljl jl. Ijkjhjoj. Pikpoipoipoi 15.33 oiuoiuoiu. Jhgjhgjh.  

The way I interpreted your question, you might want to get:

Hkjhhjk ljljl jl.
Ijkjhjoj.
Pikpoipoipoi 15.33 oiuoiuoiu.
Jhgjhgjh.

for it.

And: If you replace the single full stop with a line break you get a subsequent space shifted to the new line.

Hello,

there is an extension called AltSearch.oxt at https://extensions.libreoffice.org/extensions/alternative-dialog-find-replace-for-writer, which allows for distinction of manual line break and new paragraph in Replace field - see screenshot:

Please note: “\n” hast a different meaning than in LibreOffice’s internal Find & Replace dialog

If the answer is correct or helped you to fix your problem, please click the check mark (:heavy_check_mark:) next to the answer.

Just did a short testing of AltSearch under LibO V6.3.0.0.alpha1.
It seems to still work with the next version.

See also: https://bugs.documentfoundation.org/show_bug.cgi?id=106137#c7
Having a way to insert unicode characters (including so-called controll characters) in replace strings (\u000A e.g. for a hard line break) would resolve the issue.

Great I’ll have a look
thank you

Hi ll thanks for your answers

As it happens I did manage to find a solution.

find : \.
replace : . ctrl+shift+U 000A

It seems to work.

1 Like