-
Bug
-
Resolution: Fixed
-
P4
-
fx2.1
-
Javafx JDK 2.1 b14, Java SE 7u3 JRE i586
Ubuntu 11.10 x64
I create a gridpane with 100 rows constraints with percentHeight = 1 and 100 columns with percentWidth = 1, and set it root of a scene.
For some sizes, last columns or rows are compressed or stretched in a very strange way.
Perfectly visible with this size for columns :
package test;
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.layout.ColumnConstraints;
import javafx.scene.layout.GridPane;
import javafx.scene.layout.RowConstraints;
import javafx.stage.Stage;
public class Test extends Application {
public static void main(String[] args) {
launch();
}
@Override
public void start(Stage stage) throws Exception {
GridPane gp = new GridPane();
RowConstraints rowConstraint;
ColumnConstraints columnConstraint;
for (int x = 0; x < 100; x++) {
rowConstraint = new RowConstraints();
rowConstraint.setPercentHeight(1);
gp.getRowConstraints().add(rowConstraint);
columnConstraint = new ColumnConstraints();
columnConstraint.setPercentWidth(1);
gp.getColumnConstraints().add(columnConstraint);
}
gp.setGridLinesVisible(true);
Scene scene = new Scene(gp, 744, 451);
stage.setScene(scene);
stage.show();
}
}
For some sizes, last columns or rows are compressed or stretched in a very strange way.
Perfectly visible with this size for columns :
package test;
import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.layout.ColumnConstraints;
import javafx.scene.layout.GridPane;
import javafx.scene.layout.RowConstraints;
import javafx.stage.Stage;
public class Test extends Application {
public static void main(String[] args) {
launch();
}
@Override
public void start(Stage stage) throws Exception {
GridPane gp = new GridPane();
RowConstraints rowConstraint;
ColumnConstraints columnConstraint;
for (int x = 0; x < 100; x++) {
rowConstraint = new RowConstraints();
rowConstraint.setPercentHeight(1);
gp.getRowConstraints().add(rowConstraint);
columnConstraint = new ColumnConstraints();
columnConstraint.setPercentWidth(1);
gp.getColumnConstraints().add(columnConstraint);
}
gp.setGridLinesVisible(true);
Scene scene = new Scene(gp, 744, 451);
stage.setScene(scene);
stage.show();
}
}