C-H
Peace to you, and thank you for the great tool, TextPad.
I am wondering why every so often I open one of my hand-coded XHTML files to find it somehow has been double spaced. This offends my sense of aesthetics, and takes my time to return the file to normal, crisp single-spaced code.
I am not a power user, just know how to do the simple things with TextPad. I find it the perfect tool for a coder who is also an author.
Any clues as to why a few (not all) of my files get double spaced out?
Thanks in advance,
Bekah
Double spaces
Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard
- Bob Hansen
- Posts: 1516
- Joined: Sun Mar 02, 2003 8:15 pm
- Location: Salem, NH
- Contact:
Not sure what is causing the problem, but you should be able to fix the results with Search/Replace with Regular Expressions
1. Move the cursor to the beginning of your document.
2. Do Search>Replace
Search for \n\n
Replace with \n
3. Make sure you have a checkmark in the box for Regular Expressions.
Click on Replace All.
1. Move the cursor to the beginning of your document.
2. Do Search>Replace
Search for \n\n
Replace with \n
3. Make sure you have a checkmark in the box for Regular Expressions.
Click on Replace All.
Hope this was helpful.............good luck,
Bob
Bob
- talleyrand
- Posts: 624
- Joined: Mon Jul 21, 2003 6:56 pm
- Location: Kansas City, MO, USA
- Contact:
CHET-NUN
Thank you for the help.
The regular expression replacement suggestion worked great.
But, I would add this caution:
Select the text/code you want to remove the double spaces from, else you remove important whitespace from elsewhere in your file. My XHTML headers and footers are clearer when I put blank lines between sections.
How did the mysterious double spaces appear? My best guess is that sneakernetting files between windows and linux, and using various editing tools may be the culprit.
I am glad to know it probably is not TextPad doing it.
Grateful for the help, I am
Bekah
Thank you for the help.
The regular expression replacement suggestion worked great.
But, I would add this caution:
Select the text/code you want to remove the double spaces from, else you remove important whitespace from elsewhere in your file. My XHTML headers and footers are clearer when I put blank lines between sections.
How did the mysterious double spaces appear? My best guess is that sneakernetting files between windows and linux, and using various editing tools may be the culprit.
I am glad to know it probably is not TextPad doing it.
Grateful for the help, I am
Bekah