| 1827 | |
| 1828 | |
| 1829 | bool TiXmlPrinter::Visit( const TiXmlText& text ) |
| 1830 | { |
| 1831 | if ( text.CDATA() ) |
| 1832 | { |
| 1833 | DoIndent(); |
| 1834 | buffer += "<![CDATA["; |
| 1835 | buffer += text.Value(); |
| 1836 | buffer += "]]>"; |
| 1837 | DoLineBreak(); |
| 1838 | } |
| 1839 | else if ( simpleTextPrint ) |
| 1840 | { |
| 1841 | TIXML_STRING str; |
| 1842 | TiXmlBase::EncodeString( text.ValueTStr(), &str ); |
| 1843 | buffer += str; |
| 1844 | } |
| 1845 | else |
| 1846 | { |
| 1847 | DoIndent(); |
| 1848 | TIXML_STRING str; |
| 1849 | TiXmlBase::EncodeString( text.ValueTStr(), &str ); |
| 1850 | buffer += str; |
| 1851 | DoLineBreak(); |
| 1852 | } |
| 1853 | return true; |
| 1854 | } |
| 1855 | |
| 1856 | |
| 1857 | bool TiXmlPrinter::Visit( const TiXmlDeclaration& declaration ) |