HI all. I would like to test something and would like to try inserting a blank line after every period/end of sentence.
To clarify, I do not simply want to change the line spacing, which is purely visual. I want there to be an actual line after every period/end of sentence, as if I had hit enter twice before starting the next line of text.
If there is a command for this it would be greatly appreciated. Thank you in advance for your help!
How to insert line after every period/sentence end.
-
- Posts: 8
- Joined: Sun Apr 11, 2021 1:30 am
How to insert line after every period/sentence end.
OpenOffice 4.1.6 / WIN10
Re: How to insert line after every period/sentence end.
That "command" is:If there is a command for this it would be greatly appreciated.
Find ans Replace - together with the Regular Expressions.
https://help.libreoffice.org/4.2/Common ... xpressions
Do you want insert empty Lines by inserting LineFeed character or empty Paragraphs by inserting ParagraphEnd character?
You need substitute all of the sentence end characters to itself+2*LineFeed/ParagraphEnd character.
1. Write into the Search box: "[.?!]" (without quotation marks)
2. For inserting same text into the document, write into Replace box "what was searched": "&" or "$0"
3. The built-in F&R function can insert ParagraphEnd charater only. RegEx value: "\n". You need two pieces of it, one for paragraph end, and an another for an empty paragraph: "\n\n".
4. The full content of the Search box:
Code: Select all
[.?!]
Code: Select all
&\n\n
Edit: I tried it: Works fine in my LO 6.1.6. |
The Alternative Find&Replace Extension can insert LineFeed character. The codes for the Replace box:
LineBreak: &\n\n
ParagraphEnd: &\p\p
Edit: (I just tried it. The AltSearch extension stopped with Error message.) |
Last edited by Zizi64 on Thu Nov 18, 2021 12:00 pm, edited 1 time in total.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
Re: How to insert line after every period/sentence end.
doing a search for what's in the quotes below (but not including the quotes) and nothing in the replace box should tidy up Zizi64's result
"^ |^ "
Regular expressions need to be checked
^means find the start of the paragraph. The pipe symbol | allows you to find multiple things so that expression finds the start of the paragraph and two spaces and the start of the paragraph and a space.
"^ |^ "
Regular expressions need to be checked
^means find the start of the paragraph. The pipe symbol | allows you to find multiple things so that expression finds the start of the paragraph and two spaces and the start of the paragraph and a space.
Windows 10, Openoffice 4.1.11, LibreOffice 7.4.0.3 (x64)
Re: How to insert line after every period/sentence end.
You are describing adding an empty paragraph. You could change the style that you are using for the paragraphs to increase the spacing below the paragraph; this will give the same effect as inserting an empty paragraph. Note that this is not the same as changing the line spacing.To clarify, I do not simply want to change the line spacing, which is purely visual. I want there to be an actual line after every period/end of sentence, as if I had hit enter twice before starting the next line of text.
Should you need to revert, it is as simple as editing the style to vary the spacing after paragraph.
Cheers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers
David
OS - Slackware 15 64 bit
Apache OpenOffice 4.1.15
LibreOffice 24.2.2.2; SlackBuild for 24.2.2 by Eric Hameleers