-
Bug
-
Resolution: Cannot Reproduce
-
P4
-
7u6
-
2.2.0b18
Run code:
import javafx.application.Application;
import javafx.geometry.Pos;
import javafx.scene.Scene;
import javafx.scene.control.ProgressBar;
import javafx.scene.layout.HBox;
import javafx.scene.layout.StackPane;
import javafx.stage.Stage;
public class TreeViewSample extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage primaryStage) {
HBox hbox = baseFill(new HBox());
hbox.setAlignment(Pos.BASELINE_CENTER);
hbox.setTranslateX(10);
hbox.setTranslateY(10);
StackPane root = new StackPane();
root.getChildren().add(hbox);
primaryStage.setScene(new Scene(root, 400, 400));
primaryStage.show();
}
protected HBox baseFill(HBox hbox) {
hbox.getChildren().add(new ProgressBar());
hbox.getChildren().add(new ProgressBar());
hbox.setPrefSize(270, 270);
hbox.setFillHeight(false);
return hbox;
}
}
If you resize scene, two controls will jump.
import javafx.application.Application;
import javafx.geometry.Pos;
import javafx.scene.Scene;
import javafx.scene.control.ProgressBar;
import javafx.scene.layout.HBox;
import javafx.scene.layout.StackPane;
import javafx.stage.Stage;
public class TreeViewSample extends Application {
public static void main(String[] args) {
launch(args);
}
@Override
public void start(Stage primaryStage) {
HBox hbox = baseFill(new HBox());
hbox.setAlignment(Pos.BASELINE_CENTER);
hbox.setTranslateX(10);
hbox.setTranslateY(10);
StackPane root = new StackPane();
root.getChildren().add(hbox);
primaryStage.setScene(new Scene(root, 400, 400));
primaryStage.show();
}
protected HBox baseFill(HBox hbox) {
hbox.getChildren().add(new ProgressBar());
hbox.getChildren().add(new ProgressBar());
hbox.setPrefSize(270, 270);
hbox.setFillHeight(false);
return hbox;
}
}
If you resize scene, two controls will jump.