Simpler call to sort.
Minor clean up.
Simplified "under mouse" debug lines.

Previously they didn't always work correctly when not starting from the root. This ensures correct clipping, etc.