Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-4850870

Apparent bug in Box layout

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not an Issue
    • Icon: P4 P4
    • None
    • 5.0
    • client-libs
    • None

      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.

            apikalev Andrey Pikalev
            kbr Kenneth Russell (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: