Setting an Indent Size to Zero
Oxygen XML Developer will automatically format
and indent documents at certain times. This includes indenting the content from the
margin to reflect its structure. In some cases, you may not want your content indented. To
avoid your content being indented, you can set an indent size of zero.
Note: Changing the
indent size does not override the rules that Oxygen XML Developer uses for handling
whitespace when formatting and indenting XML documents. Therefore, changing the indent size
will have no effect on elements that require whitespaces to be maintained.
There are
two cases to consider.- Maintaining zero indent in documents with zero indent
-
If you have existing documents with zero indent and you want Oxygen XML Developer to maintain a zero indent when editing or formatting those documents:
- Open the Preferences dialog box and go to .
- Select Detect indent on open.
- Select Use zero-indent if detected.
Oxygen XML Developer will examine the indent of each document as it is opened and if the indent is zero for all lines, or for nearly all lines, a zero indent will be used when formatting and indenting the document. Otherwise, Oxygen XML Developer will use the indent closest to what it detects in the document.
- Enforcing zero indent for all documents
-
If you want all documents to be formatted with zero indent, regardless of their current indenting:
- Open the Preferences dialog box and go to .
- Deselect Detect indent on open.
- Set Indent size to
0
.
All documents will be formatted and indented with an indent of zero.Warning: Setting the indent size to zero can change the meaning of some file types, such as Python source files.