hi, how can i create a lineedit in the below void?
Code:
void QGraphicsItem::paint ( QPainter * painter, const QStyleOptionGraphicsItem * option, QWidget * widget = 0 )
Printable View
hi, how can i create a lineedit in the below void?
Code:
void QGraphicsItem::paint ( QPainter * painter, const QStyleOptionGraphicsItem * option, QWidget * widget = 0 )
creation widget in paint method it's worth, since that method is called many times (memory leaks can occur) and that will influence on an application performance. it's better to create widgets in ctors.
for taking input you can use QGraphicsProxyWidget.
ya thanks ... but there also we use only our input widgets ... my point is did Qt gives us any option for making our item get input interface ... other than using QLineEdit() or like that
i place the QGraphicsProxyWidget in the paint()?
or create a void for QGraphicsProxyWidget?
am i right? if not can someone enlighten me? thanks
Can you explain what it is that you want to accomplish exactly?