LaurentGomila/SFML — pull request #649 by Rapptz (2014-06-26 02:17:06+00:00)
Title: Improve standard library compatibility.

At the moment, the string class currently specifies typedefs in CamelCase while the standard library specifies things in snake_case. While usually this is okay, in specific cases it can be quite damaging for the standard library that expects things to have snake_case such as generic algorithms. As an example, supposing I have a templated function like so:

```cpp
template
void do_things(const Container& t, typename Container::value_type x) {
// do stuff
}
```

The generic algorithm would work for standard containers but would fail for SFML because SFML doesn't provide typedefs that are compatible with the rest of the standard library. Other libraries, such as [Qt][qt], also provide typedefs in their own special case but provide alternatives that fit with the standard library to aid with generic programming, which is a pretty strong paradigm in C++.

I tried to keep the style consistent and only provided the three major ones that I believe are commonly used (`iterator`, `const_iterator`, `value_type`, and `npos` for generic string algorithms). I hope the patch is fine. It doesn't introduce any breaking changes just alternative names.

[qt]: http://qt-project.org/doc/qt-4.8/qvector.html