PDA

View Full Version : PyQt Hide off screen widgets



Alterah
21st January 2012, 05:19
I wrote a simple program with PyQt that displays animated gif images. I am using QLabels and QMovies to do this. However, I noticed that it is consuming a bunch of memory to do so. Admittedly this is my fault as I am opening all the gifs and animating all of them at the same time, even ones off screen. Is there a straightforward way to check to see if a widget is off screen? I see the isVisible functions, but it is my impression those will return true in this case because while the widgets are off screen, they are still visible in a code sense. Thanks for any assistance.