I am trying to use a class which extends JFrame to build a GUI. ex : class Deck extends JFrame The GUI is built in its constructor.
I am making a brick game. I want the screen to get clear after every 0.1 second so that i can redraw every thing on the frame screen.
I want to display two (or more) JFrames at the same time. When I close one of them (use the default close button), the other frames should stil开发者_如何学运维l be visible.
I have set up a JFrame like this: public class XFrame extends JFrame { public XFrame() { setSize(100, 100);
Ho开发者_StackOverflow中文版w would you write a method to detect if the mouse cursor is inside a JFrame in java? The method should return true if it is inside or else false.
Okay, I\'m NOT a Java noob, it just so happens that I\'ve forgotten a tad bit about core Java while I was learning more fun stuff like MySQL, Servlets, Java EE, JDBC etc etc; so don\'t frame your answ
I\'m playing with things I don\'t really understand at the moment for a JAVA project on a Robot exploring an unknown territory (a grid of valid positions and blocked positions). Anyway, I tried to imp
I\'m using Vista, my old Java app ran on Win XP has thin borders, about 2 pixels thick, but now on Vista, the borders deafults to thick lines, maybe 6,7 pixels thick, can 开发者_StackOverflow社区I spe
What is th开发者_Go百科e main difference between setSize() and setPreferredSize(). Sometimes I used setSize(), sometimes setPreferredSize(), sometimes one does what I want, sometimes the other.
I have created a custom JPanel that displays images (lets call it MyPanel), I have added this to JFrame\'s contentPane.