[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Pyatcron-devel-list] Task list in the main window

From: Julien Olivier
Subject: RE: [Pyatcron-devel-list] Task list in the main window
Date: Tue, 11 Nov 2003 23:13:11 +0000

On Tue, 2003-11-11 at 21:17, Childers, Matthew wrote: 
> > In fact you have to specify the color as a string, like "#FF0000" :)
> > Weird, isn't it ?
> > 
> > My only concern would be that hardcoding the "grey-out" color might
> not
> > be a good idea. Isn't there a way to retrieve the exact color from the
> > GTK theme or something ?
> Ok, the theme info is kept in ~/.gtkrc, and there is a line
> text[INSENSITIVE] that keeps the "greyed-out" text color.  I don't know
> of any way to access this information other than accessing the gtkrc
> file itself.  Now, my .gtkrc file has one line which is an include
> statement of the gtkrc file for the theme I am using.  So my question
> is: Do we want to go ahead and write a function that will access the
> gtkrc file, and follow any includes, and parse the information out of
> it?  I imagine that we will have other things that we need to access the
> theme information on, so maybe it should be something we work at.  What
> do you all think?  I will also look at some of the other config tools
> and see what they do, maybe they already have something like that
> written.

I've found it !

Basically, you have to get the rc_style property from any widget (I used and get the colors from the style. The color #4 is the
insensitive one. Then you have to get the red, green and blue values of
the color, transform them in hexa, remove the "0x" part of the hexa,
concatenate each value and prepend "#" :)

I attached the implementation.

The problem now is that, when an inactive task is selected, it uses the
inactive color. We should find a way to tell it not to set the
foreground when the row is selected. I'll look at it tomorrow.

> Matt
> _______________________________________________
> Pyatcron-devel-list mailing list
> address@hidden


Julien Olivier <address@hidden>

Description: Text Data

reply via email to

[Prev in Thread] Current Thread [Next in Thread]