Check out the latest version of Routino: svn co http://routino.org/svn/trunk routino
Change the xsd-to-xmlparser functions to output the source code in the same order as the XSD file and do not attempt to sort them into reverse order of reference.