How to set text color using pyKDE 0.8?

Richard Jones Richard.Jones at fulcrum.com.au
Thu Jul 29 19:41:27 EDT 1999


["Peter Torstenson"]
> I'm using pyKDE 0.8 binding for python.
> I made a QLabel on the main widget. Now I'd like to change the color of the
> text inside this QLabel.
> I managed to change the backgroundcolor and the font. But I can't find any
> info on how to change the color of the text, or the foregroundcolor.

   I've just done some poking around... Qt 2.0 looks like it has really good 
support for color control (presumably as part of the introduction of styles), 
but of course we need pyKDE 0.9 for that...

   I even tried supplying a QPainter through drawContents, but of course a 
setBrush()'ed QColor gets nuked when the drawContents does a begin()...

   A friend says he did it once, but he can't remember offhand how...


       Richard






More information about the Python-list mailing list