user interface - Qt to update (repaint) textbox while processing -
my qt 4 application can update log box area (actually whole gui) until function finishes execution. there way update gui/log box during execution? adding qwidget::repaint() or qwidget::update() in loop, user can see gui processing, rather wait until function finishes , print out log @ once.
you need call qcoreapplication::processevents() during execution of function. keep gui alive , responsive letting event loop run.
an alternative execute function in separate thread. more information on threads in qt can found here: http://qt-project.org/doc/qt-4.8/threads.html.
Comments
Post a Comment