diff options
author | Arseny Kapoulkine <arseny.kapoulkine@gmail.com> | 2015-04-13 21:21:26 -0700 |
---|---|---|
committer | Arseny Kapoulkine <arseny.kapoulkine@gmail.com> | 2015-04-13 21:49:08 -0700 |
commit | 2a3435274f0d7d0e3ccb4417e143e5957e820332 (patch) | |
tree | 2cbf0b29bf1bcfa84a8e014f6bdc3b2c956e577c /src/pugixml.hpp | |
parent | 950693be7fb1182644b720d3044a73aaaccee1c9 (diff) |
Refactor format_indent_attributes implementation
Fix code style and revert redundant parameters/whitespace changes.
Also remove format_each_attribute_on_new_line - we're only introducing one
extra formatting flag. The flag implies format_indent but does not include its
bitmask.
Also add a few more tests.
Fixes #14.
Diffstat (limited to 'src/pugixml.hpp')
-rw-r--r-- | src/pugixml.hpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/pugixml.hpp b/src/pugixml.hpp index 36ed955..02ca86b 100644 --- a/src/pugixml.hpp +++ b/src/pugixml.hpp @@ -203,13 +203,13 @@ namespace pugi // Open file using text mode in xml_document::save_file. This enables special character (i.e. new-line) conversions on some systems. This flag is off by default. const unsigned int format_save_file_text = 0x20; - // Set each attribute to new line - const unsigned int format_each_attribute_on_new_line = 0x40; + // Write every attribute on a new line with appropriate indentation. This flag is off by default. + const unsigned int format_indent_attributes = 0x40; + // The default set of formatting flags. // Nodes are indented depending on their depth in DOM tree, a default declaration is output if document has none. const unsigned int format_default = format_indent; - const unsigned int format_indent_attributes = format_indent | format_each_attribute_on_new_line; - + // Forward declarations struct xml_attribute_struct; struct xml_node_struct; |