Locking JPanel size to some aspect-ratio
843804Jul 11 2005 — edited Jul 12 2005Hey there.
If this question sounds like one that's coming from an amateur, it's because it is.
I have a JPanel that holds an Image object, and I am looking for a way to restrict the way my JPanel (and the JFrame as a whole) shrinks & grows as it is being resized to prevent it from messing up with my image display. I've tried using setPreferredSize(), setMinimumSize(), but they have no effects whatsoever. How can I just do that?
Thanks in advance!