woodtluk
21st May 2010, 14:44
Hi there
I've a widget that is created by the QtCreator and containes a QLineEdit.
Then this widget is embbeded in a QGraphicsRectItem. When i click on the line edit it gets the editing focus. But no cursor is shown in the line edit.
This is quite confusing. because the user don't realize that he can edit the text.
Is this a Qt bug?
Probably not...
In the constructor of the QGraphicsRectItem there is code like this:
m_pWidgetsProxy->setWidget(m_pFilterWidgets);
m_pWidgetsProxy->setFocusPolicy(Qt::ClickFocus);
Cheers Luke
I've a widget that is created by the QtCreator and containes a QLineEdit.
Then this widget is embbeded in a QGraphicsRectItem. When i click on the line edit it gets the editing focus. But no cursor is shown in the line edit.
This is quite confusing. because the user don't realize that he can edit the text.
Is this a Qt bug?
Probably not...
In the constructor of the QGraphicsRectItem there is code like this:
m_pWidgetsProxy->setWidget(m_pFilterWidgets);
m_pWidgetsProxy->setFocusPolicy(Qt::ClickFocus);
Cheers Luke