[PyQt] unsetPalette function in qt4?

Peter Shinners peters at imageworks.com
Wed Sep 12 18:07:15 BST 2007

Phil Thompson wrote:
> Possibly...
>     w.setAttribute(QtCore.Qt.WA_SetPalette, False)

It turns out w.setPalette(QtGui.QPalette()) does the trick. I dug around 
the qt source to see what the unsetPalette was doing (still in the qt3 

Testing the results with w.testAttribute show that it is working, so 
pass in the 'default' palette to unset.

More information about the PyQt mailing list