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

Synth: ComboBox Popup cannot be customized correctly

    Details

    • Subcomponent:
    • Understanding:
      Cause Known
    • CPU:
      x86
    • OS:
      windows_xp

      Description

      FULL PRODUCT VERSION :
      java version "1.6.0-beta2"
      Java(TM) SE Runtime Environment (build 1.6.0-beta2-b86)
      Java HotSpot(TM) Client VM (build 1.6.0-beta2-b86, mixed mode, sharing)

      ADDITIONAL OS VERSION INFORMATION :
      Microsoft Windows XP [Version 5.1.2600]

      A DESCRIPTION OF THE PROBLEM :
      Using Synth LaF the combox popup menu is not customizable by using the xml-file due to two reasons:
      1) The included JList inherits its border from the list-region although it should not have a border.
      2) The popup menu ignores the border settings set in the xml-file.

      ad 1)
      In Basic LaF the list's border ist set to null (configureList in BasicComboPopup) but Synth LaF does not. So the list's border get painted within the popup's border resulting in two boders. A possible workaround is to define a style for ComboBox.list with a border using sourceInsets of 0.

      ad 2)
      In Basic LaF the popup border is set to a black line. Synth LaF inherits this border as it has no own implementation of configurePopup in SynthComboPopup. When "setBorder(LINE_BORDER);" is omitted in Synth LaF an own border can be specified in the xml-file.


      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      - Create an xml-file for synth styling list and popupMenu.
      - Start a application displaying a ComboBox.
      - Open the popup.

      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      The popup has the borders as follows:
      - The list border is not displayed
      - The popup has the specified border
      ACTUAL -
      The popup has the borders as follows:
      - The list border is displayed
      - The popup has a black, one pixel wide border

      REPRODUCIBILITY :
      This bug can be reproduced always.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              ndcosta Nelson Dcosta (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Imported:
                Indexed: