| 2098 | |
| 2099 | |
| 2100 | void XMLPrinter::OpenElement( const char* name, bool compactMode ) |
| 2101 | { |
| 2102 | SealElementIfJustOpened(); |
| 2103 | _stack.Push( name ); |
| 2104 | |
| 2105 | if ( _textDepth < 0 && !_firstElement && !compactMode ) { |
| 2106 | Print( "\n" ); |
| 2107 | } |
| 2108 | if ( !compactMode ) { |
| 2109 | PrintSpace( _depth ); |
| 2110 | } |
| 2111 | |
| 2112 | Print( "<%s", name ); |
| 2113 | _elementJustOpened = true; |
| 2114 | _firstElement = false; |
| 2115 | ++_depth; |
| 2116 | } |
| 2117 | |
| 2118 | |
| 2119 | void XMLPrinter::PushAttribute( const char* name, const char* value ) |