How to view XML files generated by Sesarray programs?
Posted: Tue Aug 14, 2007 1:19 pm
[Moved from FAQ page]
All XML files generated by sesarray programs (.page, .layer, .mkup, .dinver, .target, ...) are in fact gzipped tar files including file 'contents.xml' encoded in UTF-16 (unicode characters).
You can take advantage of the XML structure with any XML viewer (firefox, vi, kwrite,...), expanding or collapsing some parts. Currently, kwrite does not recognize the encoding automatically, and you can see weird characters on opening 'contents.xml'. Go to menu 'Tools/Encoding/Unicode ( utf16 )', however you won't be able to edit the file. Another option would be to force encoding in kwrite's command line but it does not work. Hence the best way to edit is currently 'vi' which automatically recognize UTF-16.
One other option is to convert unicode to UTF-8, for instance, with 'iconv':
All XML files generated by sesarray programs (.page, .layer, .mkup, .dinver, .target, ...) are in fact gzipped tar files including file 'contents.xml' encoded in UTF-16 (unicode characters).
Code: Select all
$ tar xvfz file.page
contents.xml
$ kwrite contents.xml
$ vi contents.xml
$ firefox contents.xml
One other option is to convert unicode to UTF-8, for instance, with 'iconv':
Code: Select all
$ iconv -f UTF-16 -t UTF-8 contents.xml > tmp; mv tmp contents.xml
$ kwrite contents.xml
$ tar cvfpz file.page contents.xml