Add support for locale-switching on Windows.
Implement a very dirty work-around for the absurdity of Windows.
Fix a few things.
Remove last uncontrolled calls to threaded locale functions.
Cleanup the defines
Merge pull request #1717 from fontforge/locale_threadsafe_1

Add support for locale-switching on Windows.