Function to shuffle colors in a QPalette - useful?

Matthew Woehlke mw_triad at users.sourceforge.net
Fri Sep 7 00:16:36 BST 2007


I've been "monitoring" Arto Hytönen as he goes through (thanks for the 
help!) nuking deprecated KGlobalSettings and KColorScheme uses, and 
noticed a number of places that seem to be using KCS only to reshuffle 
colors in the palette (i.e. replace Window bg/fg with View bg/fg).

While I suppose it shouldn't hurt to use adjust{Back,Fore}ground (1) for 
this purpose, it almost seems like overkill, so I'm wondering if maybe 
we shouldn't provide a function to do this sort of thing, maybe a 
"swapPaletteColors"?

The places we've found so far that do this are KUrlButton, KDateTable, 
RSIRelaxPopup (from extragear/utils/rsibreak) and LabelViewItem 
(extragear/network/ktorrent/libktorrent).

1: http://permalink.gmane.org/gmane.comp.kde.devel.core/45389

-- 
Matthew
When in doubt, give it a good swift kick.





More information about the kde-core-devel mailing list