tgui::String

Started by Garwin, 30 September 2023, 09:17:08

Garwin

I find it an excellent class that can be used not only in TGUI but in the whole program.
Would not be good to add operator << and >> overloading for UTF8 strings as it is in line with returning UTF8 strings.

There is the possibility to use functions to convert it to UTF8 but simple ability for parsing templates would be better:
out << tgui::String
in >> tgui::String

texus

What type would "in" and "out" be here?

For std::ostream and std::wostream, there already is a << operator. There currently isn't a >> operator.

Garwin

operator >> especially for filestreams

texus

I'm not sure what you mean with filestreams, but I've added an operator >> for std::istream now

Garwin

Thanks, this is exactly what I need.