Remove blank lines in format action
Are you missing a feature? Request its implementation here.
-
- Posts: 5
- Joined: Wed Apr 29, 2009 4:45 pm
Remove blank lines in format action
Post by ted.habermann »
I am dealing with XML that is generated by a program that inserts blank lines in various places in the file. It would be nice if the Format and Indent Command removed these
-
- Posts: 4141
- Joined: Fri Mar 28, 2003 2:12 pm
Re: Remove blank lines in format action
Post by sorin_ristache »
Hello,
The Format and Indent action removes the blank lines if they are not included in an element that has the atribute xml:space="preserve" and if the option Preserve empty lines is not selected in Preferences -> Editor -> Format -> XML (by default it is selected). Are the blank lines included in an element listed in the Preserve Space Elements list in Preferences -> Editor -> Format -> XML?
Regards,
Sorin
The Format and Indent action removes the blank lines if they are not included in an element that has the atribute xml:space="preserve" and if the option Preserve empty lines is not selected in Preferences -> Editor -> Format -> XML (by default it is selected). Are the blank lines included in an element listed in the Preserve Space Elements list in Preferences -> Editor -> Format -> XML?
Regards,
Sorin
-
- Posts: 5
- Joined: Wed Apr 29, 2009 4:45 pm
Re: Remove blank lines in format action
Post by ted.habermann »
The preferences setting deals with this very nicely... Too many options to keep up with!
Thanks,
Ted
Thanks,
Ted
-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: Remove blank lines in format action
Hi,
If you just want to remove the blank lines and don't need to format the document, simply use Find > Find/Replace to remove them:
Text to find: \n\s*\n
Replace with: \n
Regular expression enabled
Press Replace All to eliminate all blocks of blank lines.
Regards,
Adrian
If you just want to remove the blank lines and don't need to format the document, simply use Find > Find/Replace to remove them:
Text to find: \n\s*\n
Replace with: \n
Regular expression enabled
Press Replace All to eliminate all blocks of blank lines.
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service