Logo Search packages:      
Sourcecode: qt4-x11 version File versions  Download package

void QString::truncate ( int  pos  ) 

Truncates the string at index position pos.

If pos is beyond the end of the string, nothing happens.


        QString str = "Vladivostok";
        // str == "Vlad"

See also:
chop(), resize(), left()

Definition at line 3538 of file qstring.cpp.

References resize().

Referenced by QSqlDriver::formatValue(), fromUtf8(), Q3ListView::keyPressEvent(), Q3Url::setFileName(), simplified(), QAbstractSpinBox::sizeHint(), Q3MultiLineEdit::textLine(), QKeySequence::toString(), and vsprintf().

    if (pos < d->size)

Generated by  Doxygen 1.6.0   Back to index