0
votes

I am kind of a newbie in Java, so my question is. If for example I have a JTable which represents a 2D array of Color

Color [][] array = new ...

So then when I run the JFrame it shows enter image description here

So how do I color it?

1
This answer will help you.Amarnath

1 Answers

4
votes

You can attach a cellrenderer to your JTable and adjust the color with it: http://docs.oracle.com/javase/tutorial/uiswing/components/table.html#renderer