sync with develop

@stdweird: You can merge in this one straight away. This only includes stuff that was already in develop, there were no conflicts during the merge.

Merge this one in first to get a clear view in #22