Sort elements before cloning.

git-svn-id: http://svg-edit.googlecode.com/svn/trunk@2515 eee81c28-f429-11dd-99c0-75d572ba1ddd