Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to add a space in front of every line in notepad

Tags:

space

notepad

I have a list of data in notepad and want to insert a space in the beginning of each line.

Example

This is how it looks in the notepad now

Number

"123"

"123"

"124"

"126"

"147"

I want it to look like below

    Number

    "123"

    "123"

    "124"

    "126"

    "147"

I am sure there is some short cut. Please advice.

like image 600
ppp Avatar asked Dec 29 '14 21:12

ppp


People also ask

How do you put a space before every line?

Change the line spacing in a portion of the documentPress Ctrl + A to select all. Select Line Spacing Options and choose an option in the Line spacing box. Adjust the Before and After settings to change spacing between paragraphs. Select OK.

How do you add a space in notepad?

Press the "Enter" or "Return" key on your computer keyboard to insert a space between the lines or blocks of text. You can insert as many paragraph spaces as you want by pressing the key more than once.

How do I add blank space in Notepad ++?

To add a space in a text editor, move the cursor to the place where you want to add the space, using either the arrow keys on your keyboard or by clicking there with your mouse, then press the space bar in your keyboard.


1 Answers

Open your file in Notepad++

Press Ctrl+H to open the Replace window.

Change the "Search Mode" to Regular expression.

In the "Find what" box, type (\n|^)

In the "Replace with" box, type \1     (with your spaces or tab at the end)

Then click "Replace All"

Note: If you want tabs instead of spaces, a tab character can be typed with Alt+09

like image 123
mbomb007 Avatar answered Oct 06 '22 12:10

mbomb007