Details
-
Type:
Bug
-
Status:
Resolved
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: FEST-Swing 1.2a2
-
Fix Version/s: FEST-Swing 1.2a3
-
Component/s: Swing
-
Labels:None
-
Number of attachments :
Description
I am using SwingX's JXTreeTable. When I try this:
fix.cell(row(3).column(0)).background().requireEqualTo(Color.GRAY);
it fails. It says the cell is white. Visually, I can tell it is gray. Stepping through the code, it appears that this code goes and grabs the table cell renderer and returns information based on that. However, I'm using highlighters, that's why it's gray. The
highlighters are handled in the table: they decorate the cell renderer's result. So, FEST never sees the correct color.
The following code works:
assertEquals(Color.GRAY, table.prepareRenderer(table.getCellRenderer(3, 0), 3, 0).getBackground());
The prepareRenderer does the decorating. I think FEST needs to be altered to use the result of prepareRenderer instead of just the raw cell renderer.