[Qt-interest] QTableWidget Update() problem

prashant bhutani prashantbhutani2008 at gmail.com
Mon Nov 8 07:40:17 CET 2010


Hi Everyone,

*I have asked this question before but didn't get any answer so posting it
again.
I hope someone might reply this time. Sorry to others for inconvenience.*

I am building System Monitor in Qt.
When I am calling my method for periodical update of processes
via new/child thread, an internal QWidget::update() call is being generated,
which according to documentation occurs and calls paintEvent() and
  erases previous widget's area.
http://doc.qt.nokia.com/4.7/qwidget.html#update

I am using QTabWidget to show processes, file_system and system information
in different tabs. To show processes, I am using QTableWidget.
Now, during periodical update, I am updating the QTableWidget due to which
update() is called. This call is giving me a blank tab (which before thread
working
showing the process table). But as soon as I switch between tabs and come
back
to process tab again, the table(new one ;) is visible again.

Now, how can I update the table without switching in between the tabs as it
would
not be user-friendly if user has to switch again and again between tabs to
see the
update.

Thanks in advance.

Regards,
Prashant Bhutani
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20101108/ecdbdc9b/attachment.html 


More information about the Qt-interest-old mailing list