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

ComboBox popup list is wrong width the first time it is shown if the ComboBox is wider than prefWidth

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • None
    • 7u15
    • javafx
    • Windows 7 64-bit
      Java 7u15

      The width of the pop-uo selection list of my editable ComboBox appears to be using the preferred width of the ComboBox instead of the actual width when it is first shown. Subsequent displays of the list are the correct width. This makes it appear odd as the list is anchored on the left side of the ComboBox, the opposite side from the button that shows the list. In the case where the ComboBox is editable, the button on the right is the only place to click to show the list so having the list appear on the left is particularly bad in that case.
      Since editable ComboBoxes have a field to type, it is not uncommon for the maxWidth and actual width of the ComboBox to be significantly larger that it's "computed" size or preferred size if the field is allowed to expand, perhaps to match other fields on the form.

            jgiles Jonathan Giles
            swpalmer Scott Palmer
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported: