-
Bug
-
Resolution: Not an Issue
-
P4
-
None
-
5.0
-
None
-
generic
-
generic
Recently I've tried adding JButtons around a central component using nested
Boxes. When the central component is a lightweight (e.g., JPanel), everything
works properly. When the central component is a heavyweight (e.g., Canvas),
resize operations are broken; try making the window in the attached test case
first bigger and then smaller. The central heavyweight doesn't ever seem to
be resized smaller in the X dimension, causing the surrounding buttons to be
pushed off the screen. Run the attached program with "java ResizeBug -swing"
to see the correct behavior.
This problem doesn't happen with, for example, BorderLayout.
Boxes. When the central component is a lightweight (e.g., JPanel), everything
works properly. When the central component is a heavyweight (e.g., Canvas),
resize operations are broken; try making the window in the attached test case
first bigger and then smaller. The central heavyweight doesn't ever seem to
be resized smaller in the X dimension, causing the surrounding buttons to be
pushed off the screen. Run the attached program with "java ResizeBug -swing"
to see the correct behavior.
This problem doesn't happen with, for example, BorderLayout.