ADDITIONAL SYSTEM INFORMATION :
RedHat Linux 8u6
A DESCRIPTION OF THE PROBLEM :
When a ComboBox has items updated whilst on display subsequent updates to the item list are not taken into account when resizing the popup.
The popup remains at the original size even if the new list of items is longer. This is a usability issue if going from a shorter to a longer list - the user cannot see the options and are troublesome to select via a single line scrollable pane. When going from a longer to shorter list the popup contains dead-space.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Run the attached test case
2. Press the "Update" button
3. Wait 5 seconds
4. Interact with the ComboBox
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Popup to be sized to show all the options without any scrolling.
ACTUAL -
ComboBox popup is only 1 cell high and not big enough to use effectively.
The options are shown but you have to navigate to them with an impossibly small ScrollPane
ComboBox remains in 'broken' stage even after selecting an option.
---------- BEGIN SOURCE ----------
import javafx.animation.KeyFrame;
import javafx.animation.Timeline;
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.control.ComboBox;
import javafx.scene.layout.VBox;
import javafx.stage.Stage;
import javafx.util.Duration;
public class ComboBoxPopupSizeIssue extends Application {
@Override
public void start(Stage stage) throws Exception {
ComboBox<String> comboBox = new ComboBox<>();
Timeline animation = new Timeline();
animation.getKeyFrames().add(new KeyFrame(Duration.seconds(1), event -> {
comboBox.show();
comboBox.getItems().setAll("Dave");
}));
animation.getKeyFrames().add(new KeyFrame(Duration.seconds(2), event -> {
comboBox.getItems().setAll("Rigby 1", "Rigby 2", "Rigby 3", "Rigby 4", "Rigby 5");
}));
Button update = new Button("Update");
update.setOnAction(event -> animation.playFromStart());
stage.setScene(new Scene(new VBox(comboBox, update)));
stage.setWidth(200);
stage.setHeight(200);
stage.show();
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
Unknown
FREQUENCY : always
RedHat Linux 8u6
A DESCRIPTION OF THE PROBLEM :
When a ComboBox has items updated whilst on display subsequent updates to the item list are not taken into account when resizing the popup.
The popup remains at the original size even if the new list of items is longer. This is a usability issue if going from a shorter to a longer list - the user cannot see the options and are troublesome to select via a single line scrollable pane. When going from a longer to shorter list the popup contains dead-space.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Run the attached test case
2. Press the "Update" button
3. Wait 5 seconds
4. Interact with the ComboBox
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
Popup to be sized to show all the options without any scrolling.
ACTUAL -
ComboBox popup is only 1 cell high and not big enough to use effectively.
The options are shown but you have to navigate to them with an impossibly small ScrollPane
ComboBox remains in 'broken' stage even after selecting an option.
---------- BEGIN SOURCE ----------
import javafx.animation.KeyFrame;
import javafx.animation.Timeline;
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.control.ComboBox;
import javafx.scene.layout.VBox;
import javafx.stage.Stage;
import javafx.util.Duration;
public class ComboBoxPopupSizeIssue extends Application {
@Override
public void start(Stage stage) throws Exception {
ComboBox<String> comboBox = new ComboBox<>();
Timeline animation = new Timeline();
animation.getKeyFrames().add(new KeyFrame(Duration.seconds(1), event -> {
comboBox.show();
comboBox.getItems().setAll("Dave");
}));
animation.getKeyFrames().add(new KeyFrame(Duration.seconds(2), event -> {
comboBox.getItems().setAll("Rigby 1", "Rigby 2", "Rigby 3", "Rigby 4", "Rigby 5");
}));
Button update = new Button("Update");
update.setOnAction(event -> animation.playFromStart());
stage.setScene(new Scene(new VBox(comboBox, update)));
stage.setWidth(200);
stage.setHeight(200);
stage.show();
}
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
Unknown
FREQUENCY : always
- relates to
-
JDK-8088059 [ComboBox] when visible row count is set, popup height doesn't change
-
- Open
-
-
JDK-8129123 ComboBox popup list view does not scrollTo when ComboBox value/selection is set
-
- Open
-
-
JDK-8146180 ComboBox dropdown list drops out of screen at 1024*768 resolution
-
- Open
-
-
JDK-8095352 [ComboBox] ComboBox popup does not adjust its size properly when the items are changed
-
- Resolved
-