Using the selected text color in the date picker

Maks Orlovich mo002j at mail.rochester.edu
Thu Mar 25 16:06:46 GMT 2004


On Thursday 25 March 2004 06:17 am, Reinhold Kainhofer wrote:
> Attached is a patch that fixes the KDateTable to use the correct text color
> for the selected text. So far, it always used white (hardcoded) for the
> selected day, even if the system-wide color setting used a light selection
> color and a dark selected text color. This was reported as bug 78162 for
> korganizer, but is a general date picker bug.
>
> Okay to apply the patch and close the report?
>
> The other problem in the date table is the hardcoded gray color for days
> outside the current month. Any ideas how to determine that value
> automaticallly from the system-wide color settings? Using inactiveTextColor
> doesn't work, as that would be white text on white background here...
>
> Reinhold

There is actually more stuff broken than that --- thinks like:
     painter->setPen(KGlobalSettings::highlightColor());
     painter->setBrush(KGlobalSettings::highlightColor());

are technically wrong, as they breaks palette inheritance (and for that matter 
disabling); this should not be using KGlobalSettings but rather 
colorGroup().highlight(), etc. 

-Maks




More information about the kde-core-devel mailing list