QLineEdit *currentLineEdit = new QLineEdit;
currentLineEdit->setText(QString("LineEdit")
currentLineEdit->setFocus(); //设置焦点
currentLineEdit->setCursorPosition(currentLineEdit->text().size()); //设置焦点(光标) 位置,设置在末尾
QLineEdit定位光标到末尾
最新推荐文章于 2024-07-09 15:36:20 发布