As a follow-up on Qt Invaded By Aliens — The End of All Flicker I’m pleased to inform that the alien branch was integrated into Qt main on Tuesday (2007/08/28).
To get use of aliens (a.k.a. windowless child widgets) simply go here and download the latest Qt 4.4 snapshot.
That’s it!
If you for some reason want to get back to the old behavior with native windows, here’s how you can do it:
1) Use ‘QT_USE_NATIVE_WINDOWS=1′ in your environment (PS! with today’s snapshot and earlier one must use ‘QT_NATIVE=1′ instead).
2) Set the Qt::AA_NativeWindows attribute on the application: All widgets are native.
3) Set the Qt::WA_NativeWindow attribute on widgets: The widget itself and all ancestors are native (unless Qt::WA_DontCreateNativeAncestors is set).
4) Calling QWidget::winId enforces a native window and implies 3).
5) Setting the Qt::WA_PaintOnScreen attribute enforces a native window and implies 3).
Enjoy!
10 Responses to “Say Goodbye To Flicker — Aliens Are Here To Stay”
Great! Just out of interest, are there any before/ after memory usage benchmarks and also bandwidth usage benchmarks when running a remote session over e.g. FreeNX?
Not yet, but they’ll come.
Nice!!
Especially the fallback methods with winId() area brilliant!
I’m looking forward to a flicker-less KDE desktop in the future.
This is very good news!
I was not sure if it was possible to do this in the 4.x series, and was going to suggest it for Qt 5.x, but now we can have windowless widgets even with our KDE 4, which is very nice. Now my last “advantage” of FLTK is void ![]()
Thanks, you trolls are just awesome!
Good work, guys.
If widgets are automatically promoted to native windows when the winId() method is called, there should not be any reason not to have non-native be the default, right?
Think I’ll need to download a 4.4 snapshot now, to try it out. Can hardly wait to go home from work today, now ![]()
That’s good news.
I was eager to try it, as my experience with the Qt 4.x performance has been very bad (and it was getting worse and worse, 4.3 was close to unbearable), but unfortunately, compilation stops on my Debian etch system with the following error:
libQtDesigner.so: undefined reference to `typeinfo for QDesignerMetaDataBaseInterface’
Anyway, I’m really curious if this change will bring some substantial improvement. The video in the previous blog entry looked very promising.
@ J.M.
What exactly was getting slower from 4.0 to 4.3 to the level of being “close to unbearable”? Your statement is at odds with what everyone else reports, and the optimization work we put into Qt. Please elaborate, preferably on qt-interest.
now that i think about it, does it mean achieving http://labs.trolltech.com/blogs/2007/04/11/qt-demo/ “without reinventing the widget wheel on top of QGraphicsScene” should be possible ? In a perfect world, I would like QT to offer me the possibility to code the same demo using QPushButton instead of a a custom graphics item, the button being styled with the help of stylesheets !
what do you think ?
Great!
Just tried on Windows and compared the same app that used 4.3, and it’s really faster. Very nice!
Is this implemented on OS X? If so will it address some of the problems reported with Parallels? (See the following page for details http://forum.parallels.com/printthread10467.html)