Now that we know how to create various 2D shapes, the next step would be to use colors in our UI components. Not everything looks fine in black and white. Colors bring some radiance and class to the look and feel of a UI component. In this chapter, we are going to learn how to do just that.
So, lets get started!!!
Using Colors:
The setPaint method of the Graphics2D class lets you select a