Details
-
Bug
-
Resolution: Fixed
-
P4
-
8
-
OS X 10.9, JDK8 b116
Description
Create a TableView and apply the following CSS file:
.table-cell {
-fx-alignment: center-left;
}
.table-row-cell {
-fx-cell-size: 50px;
}
The text in the table cells will be aligned top-left instead of center-left, Screenshot: https://dl.dropboxusercontent.com/u/84552/issues/rt-34446_1.png.
If you change the CSS to:
.table-cell {
-fx-alignment: center-right;
}
Now the text will be aligned to the center-right position like expected, Screenshot: https://dl.dropboxusercontent.com/u/84552/issues/rt-34446_2.png.
Please find some code to test it here: https://dl.dropboxusercontent.com/u/84552/issues/rt-34446.zip
.table-cell {
-fx-alignment: center-left;
}
.table-row-cell {
-fx-cell-size: 50px;
}
The text in the table cells will be aligned top-left instead of center-left, Screenshot: https://dl.dropboxusercontent.com/u/84552/issues/rt-34446_1.png.
If you change the CSS to:
.table-cell {
-fx-alignment: center-right;
}
Now the text will be aligned to the center-right position like expected, Screenshot: https://dl.dropboxusercontent.com/u/84552/issues/rt-34446_2.png.
Please find some code to test it here: https://dl.dropboxusercontent.com/u/84552/issues/rt-34446.zip
Attachments
Issue Links
- relates to
-
JDK-8122708 FX 8 Tree/TableCell.setAlignment(..) doesn't change the default state.
- Resolved