LaurentGomila/SFML — pull request #351 by Shizmob (2013-02-12 12:38:38+00:00)
Title: Unicode window title support.

This patch adds support for Unicode window titles to SFML by changing the API to pass an sf::String instead of an std::string to Window::Window and Window::setTitle and by modifying underlying implementations to take Unicode titles into account.

Despite the fact that this change constitutes an API change, most users will not see the effects of this as sf::String constructors take existing literals and std::strings, thus allowing for implicit compiler promoting.

- Changed SFML API to receive an sf::String as the window title instead of a std::string (in Window::Window and Window::setTitle).
- Changed RenderWindow and WindowImpl APIs accordingly.
- Changed WindowImplWin32 to use a Unicode window title only if the target OS supports it.
- Changed WindowImplCocoa to always use Unicode window titles and added
a utility function to Window/OSX/cpp_objc_conversion.mm.
- Changed WindowImplX11 to set the Unicode window title as part of the _NET_WM_NAME specification, which sadly is not part of the official X standard, but the closest anything can get. Still set regular ASCII title as fallback.