[Qt-interest] Generate colors compatible with current palette

Jugdish jugdizh at gmail.com
Fri Nov 20 16:32:43 CET 2009


Is there a good way to dynamically generate a color that works well with a
given color palette?

I have a QListView and would like to colorize the text of various items in
the list to indicate a status for them. For example: green, red, and blue.
This works well when the Base color role is white, but not so well if it is
something else. I'd like my status colors to work with whatever system theme
the user might be using.

So I'm wondering what the best way is to programmatically create a set of
colors that works well with a given Base + Text color role combination.

Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20091120/e6cb6773/attachment.html 


More information about the Qt-interest-old mailing list