How to update eventFilter function?
I use update( ) function but it`s not worked .
bool CLASS_NAME::eventFilter(QObject *o, QEvent *e)
{
for ( int i = 0; i < 42; i++ ) {
if (o == tree_widget[i]->viewport() && e->type() == QEvent::Paint) {
QPainter p;
p.begin(tree_widget[i]->viewport() );
p.drawText( 35, 70, "something");
p.end();
}
}
return QWidget::eventFilter(o, e);
}
Bookmarks