I'm using RSyntaxTextArea for some xml related java developments (dispaying xml retrieved from blob in database etc.).
The problem I am facing is that the xml I insert in the TextArea does not get displayed as:
- Code: Select all
<x>
<y>test</y>
</x>
but as
- Code: Select all
<x><y>test</y></x>
--> no autoIndent etc.
Code:
- Code: Select all
RSyntaxTextArea txt = new RSyntaxTextArea();
txt.setSyntaxEditingStyle(SyntaxConstants.SYNTAX_STYLE_XML);
txt.setCodeFoldingEnabled(true);
txt.setAutoIndentEnabled(true);
txt.setText("<x><y>test</y></x>");
Any Idea how I can get full xml "pretty printing" and tag folding?
Thanks
Stefaan
