-
Bug
-
Resolution: Cannot Reproduce
-
P4
-
8u20
-
windows 7
Consider this simple test where I add a Label inside a Scrollpane which is itself inside an HBox.
In 8u20 b17, the text is shrunk because of a layout problem. This was not the case in Lombard, it's a regression.
Also note that it's the fact that the "fitToWidth" is set to true, and that the ScrollPane is inside an Hbox.
Sample code:
import javafx.application.Application;
import static javafx.application.Application.launch;
import javafx.scene.Scene;
import javafx.scene.control.Label;
import javafx.scene.control.ScrollPane;
import javafx.scene.layout.HBox;
import javafx.stage.Stage;
public class TestScrollpane extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage stage) {
Label label = new Label("This is a simple label");
ScrollPane scrollPane = new ScrollPane(label);
scrollPane.setFitToWidth(true);//This is causing the bug.
HBox box = new HBox(scrollPane);
Scene scene = new Scene(box);
stage.setScene(scene);
stage.show();
}
}
In 8u20 b17, the text is shrunk because of a layout problem. This was not the case in Lombard, it's a regression.
Also note that it's the fact that the "fitToWidth" is set to true, and that the ScrollPane is inside an Hbox.
Sample code:
import javafx.application.Application;
import static javafx.application.Application.launch;
import javafx.scene.Scene;
import javafx.scene.control.Label;
import javafx.scene.control.ScrollPane;
import javafx.scene.layout.HBox;
import javafx.stage.Stage;
public class TestScrollpane extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage stage) {
Label label = new Label("This is a simple label");
ScrollPane scrollPane = new ScrollPane(label);
scrollPane.setFitToWidth(true);//This is causing the bug.
HBox box = new HBox(scrollPane);
Scene scene = new Scene(box);
stage.setScene(scene);
stage.show();
}
}