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

PIT: Min Size is not honored properly when a smaller size is specified in setSize(), XToolkit

XMLWordPrintable

    • b61
    • x86
    • linux_sun
    • Verified

      I have set the minimum size for a frame to 200, 200 initially before showing the frame and I am showing it. Now the size of the frame is bigger than the min size. I am trying to reduce the size of the frame programmatically by calling setSize() with lesser sizes say 190, 190. But the frame is resized to 202, 202 instead of 200, 200 as defined in the spec.

      This is reproducible for all the top-levels such as Frame, Dialog and Window. This is reproducible only on XToolkit and not on Win32. I could reproduce it on SolSparc10-JDS, Cinnabar and RHAS 3.0.
      Here is the PIT build:
      java version "1.6.0-internal"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.6.0-internal-df153228_24_aug_2005_01_49-b00)
      Java HotSpot(TM) Server VM (build 1.6.0-ea-b48, mixed mode)

      I have attached a sample test. Run it on one of the platforms mentioned above. The min size is set to (200,200). Click on the 'Reduce Size' button. The frame's size will slowly reduce widthwise as well as height wise. You may click 'Get Size' at any point to check the size of the frame. Once the size stops reducing, click on 'GetSize'. You will see that the frame's size is 202, 202 instead of 200, 200.

            vbaranovsunw Vyacheslav Baranov (Inactive)
            pmohansunw Praveen Mohan (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: