Handle locales more safely.

As it turns out, switching to uselocale is a bit more complicated than we originally thought.

@adrientetar, take a look (and try round-tripping a few typefaces in various formats).

And here? It seems like we have two ways of doing the same thing.