Hello,
Yep I currently just use libxml to check if the document contains a valid XML. Then my script process the pretty-printing on a char* buffer and I do the parsing manually (but I don't need to verify XML). The idea is also to provide a simple XML PrettyPrinter script in C. So far I had never found one that can suit to my needs...
I'll commit all my sources to the svn asap :-) If you have any advices, just tell me so I can learn !
Thanks & best regards,
Cedric
On Sun, 9 Aug 2009 18:37:34 +0200, Cédric wrote:Ah ok, I didn't think of these two problems. It also was just an idea,
>Hi Enrico,
>
>Thanks for your advices. Since I don't develop pretty much in C, I
>don't know the geany-standards very well. I'll correct that :-) For
>formatting the current selection there are two technical problems I
>see :
>- The selected text must be a valid XML (from start node to its closing
>tag).
>- How do I get the depth of the selected node ?
no need to implement this if it isn't easily possible.
In addition to Philipp's suggestion about writing an own parser, GLib
also has a simple XML parser builtin. Not sure whether it is suitable
for your needs but maybe it's worth having a look, then you could also
ditch the external dependency on libxml.
But again, just an idea.
Handled, added and confirmed to you via PM :).
>I just sent you a request to join the geany project on sourceforge.
_______________________________________________
Geany-devel mailing list
Geany-devel@uvena.de
http://lists.uvena.de/cgi-bin/mailman/listinfo/geany-devel