S
Si
I have to design a small game which features a grid of clickable squares. I
have already written most of the code and I just need to implement this in a
GUI.
- What is the best object to use which would allow the visible content of a
square to change (possibly an image/text) when clicked? How would I do this?
Are buttons my only option?
- How do I put an image on a button?
- How do I display images in a Java GUI (e.g. a GIF or JPEG)?
- How would I write and retreive game scores to and from an XML file?
Sorry for the basic questions, but I'm very new to Java GUIs.
TIA.
have already written most of the code and I just need to implement this in a
GUI.
- What is the best object to use which would allow the visible content of a
square to change (possibly an image/text) when clicked? How would I do this?
Are buttons my only option?
- How do I put an image on a button?
- How do I display images in a Java GUI (e.g. a GIF or JPEG)?
- How would I write and retreive game scores to and from an XML file?
Sorry for the basic questions, but I'm very new to Java GUIs.
TIA.