Hi, everybody, I wanted to implemented that a JButton in a JFrame, And when I click which button, a picture will be displayed on the JFrame. But how can I enable the size of the JFrame be changed into a suitable size ? And this is also my problem.
You use setSize(width, height) to change the size of a JFrame. How are you getting/storing the image? The Image class has getHeight() and getWidth() methods.