how to change button color on click java jbutton code example Example: change button color java swing botton.SetBackground(Color.red);