All I can find is "whenever the widget needs to be painted."
When is that, specifically?
All I can find is "whenever the widget needs to be painted."
When is that, specifically?
When you call updateGL()
on your widget (or update()
), or just Qt decides to redraw your widget. Reasons why Qt might choose to ask for a redraw include:
In short, you have very little control about when Qt asks for a repaint. Just be sure to paint fast! :-)
update()
)? –
Rubefaction Each widget performs all painting operations from within its paintEvent() function. This is called whenever the widget needs to be redrawn, either as a result of some external change or when requested by the application.
–
Rubefaction © 2022 - 2024 — McMap. All rights reserved.
paintGL()
is not even called "instantly" when you callupdateGL()
. Instead, Qt waits and call it later when appropriate, so that successive calls ofupdateGL()
only result in one call ofpaintGL()
. – Clever