C++ (Qt)QTextEdit *editor = new QTextEdit();QTextCursor cursor(editor->textCursor());cursor.setPosition(3);editor->setTextCursor(cursor);