classpath-patches
[Top][All Lists]
Advanced

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

Re: [cp-patches] Patch: BasicTreeUI and DefaultTableCellRenderer fix


From: Roman Kennke
Subject: Re: [cp-patches] Patch: BasicTreeUI and DefaultTableCellRenderer fix
Date: Thu, 03 Nov 2005 22:28:10 +0000

Hi there,

Am 3.11.2005 schrieb "Lillian Angel" <address@hidden>:

>For DefaultTableCellRenderer, Roman suggested I fix it this way. Both
>ways work, but this looks a bit more intuitive.
>
>2005-11-03  Lillian Angel  <address@hidden>
>
[..]
>        * javax/swing/table/DefaultTableCellRenderer.java
>        (getTableCellRendererComponent): Fixed indentation, and changed
>        to set the background color if it is not an instance of
>       ColorUIResource. Prevents overriding a user-set color.

Sorry, my suggestion was wrong. Shame on me. A testcase I've written
shows that the following patch is right (and thinking about ot, it is
even more intuitive than the last one).

2005-11-03  Roman Kennke  <address@hidden>

        * javax/swing/table/DefaultTableCellRenderer.java
        (background): New field.
        (foreground): New field.
        (setBackground): Store the color that is set here.
        (setForeground): Store the color that is set here.
        (getTableCellRendererComponent): For the unselected color, set the
        value of the foreground or background fields if not null,
otherwise
        the value of the according table properties. Don't change
        the color in the focused clause.

/Roman

Attachment: DefaultTableCellRenderer.diff
Description: Text Data


reply via email to

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