Changing the sort order of default Umbraco tabs

We have a couple of projects where we wanted to gain more control over the sort order of some of the default Umbraco tabs like "Properties" or "Child items". Although I don't know of a way to do this through the Umbraco backoffice or with configuration, it is suprisingly easy to write some custom code to handle this.…