Описание тега qstring
A QString is a class in Qt library which implements character strings.
QString
holds a unicode string inside, and provides a set of useful functions to manipulate the data, including easy concatenation, trimming, search and replace, and conversion functions.
QString
can also be converted to std::string
and vice-versa with toStdString()
and fromStdString()
respectfully:
QString str = QString::fromStdString( std::string("Hello, World!") );
std::string str = QString("Hello world!").toStdString();
The official Qt documentation can be found here for Qt 4.8 and here for Qt 5.