Welcome Guest ( Log In | Register)



 
Reply to this topicStart new topic
> Is It Possible To Disable A Jbutton, and make its icon still have colors?
beeseven
post Jul 23 2005, 05:13 PM
Post #1


Privileged Member
*********

Group: Members
Posts: 629
Joined: 26-February 05
Member No.: 3,995



I'm making minesweeper so I have this big matrix of JButtons. I want to have it so that when you click the button is disabled and the ImageIcon is changed to whatever it should be, but when you disable a button it becomes grayscale so the pictures are hard to see/don't look like what they're supposed to.

Is there a way to disable the button and keep the images colorful, or does anyone have any other ideas?

(I've thought about just removing the ActionListener but that might get confusing to have blank buttons that do nothing. Maybe only disabling it if there's not a number or mine, but that might require a lot more code)
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

> Similar Topics

Topics Topics
  1. Help: Disable All Buttons Inside A Div Element(8)


 



- Lo-Fi Version Time is now: 13th October 2008 - 05:28 PM