Skip to content

Commit

Permalink
update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
leethomason committed Nov 21, 2023
1 parent 9d02652 commit 428cd1b
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ by the Document. When the Document is deleted, so are all the nodes it contains.

### White Space

#### Whitespace Preservation (default)
#### Whitespace Preservation (default, PRESERVE_WHITESPACE)

Microsoft has an excellent article on white space: http://msdn.microsoft.com/en-us/library/ms256097.aspx

Expand Down Expand Up @@ -125,7 +125,7 @@ valuable. TinyXML-2 sees these as the same XML:

<document><data>1</data><data>2</data><data>3</data></document>

#### Whitespace Collapse
#### Whitespace Collapse (COLLAPSE_WHITESPACE)

For some applications, it is preferable to collapse whitespace. Collapsing
whitespace gives you "HTML-like" behavior, which is sometimes more suitable
Expand All @@ -143,7 +143,15 @@ However, you may also use COLLAPSE_WHITESPACE, which will:
Note that (currently) there is a performance impact for using COLLAPSE_WHITESPACE.
It essentially causes the XML to be parsed twice.

#### Error Reporting
#### Pedantic Whitespace (PEDANTIC_WHITESPACE)

For applications that need to know about text nodes that are composed entirely of
whitespace, PEDANTIC_WHITESPACE is available. PEDANTIC_WHITESPACE maintains all the
whilespace between elements.

PEDANTIC_WHITESPACE is a new mode and not as tested as the other whitespace modes.

### Error Reporting

TinyXML-2 reports the line number of any errors in an XML document that
cannot be parsed correctly. In addition, all nodes (elements, declarations,
Expand Down

0 comments on commit 428cd1b

Please sign in to comment.