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

QRect QPlainTextEdit::cursorRect ( const QTextCursor cursor  )  const

returns a rectangle (in viewport coordinates) that includes the cursor.

Definition at line 2196 of file qplaintextedit.cpp.

References QTextCursor::isNull(), and QRect::translate().

    Q_D(const QPlainTextEdit);
    if (cursor.isNull())
        return QRect();

    QRect r = d->control->cursorRect(cursor).toRect();
    return r;

Generated by  Doxygen 1.6.0   Back to index