本文整理了Java中javafx.scene.control.TableColumn.setGraphic()
方法的一些代码示例,展示了TableColumn.setGraphic()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。TableColumn.setGraphic()
方法的具体详情如下:
包路径:javafx.scene.control.TableColumn
类名称:TableColumn
方法名:setGraphic
暂无
代码示例来源:origin: com.nexitia.emaginplatform/emagin-jfxcore-engine
private void addSelectColumn() {
headerCheckboxCol.setPrefWidth(40);
headerCheckboxCol.setCellValueFactory(new PropertyValueFactory<>("selected"));
headerCheckboxCol.setCellFactory(param -> buildCell());
headerCheckboxCol.setGraphic(headerColCheckbox);
headerCheckboxCol.setVisible(false);
tableView.getColumns().add(0, headerCheckboxCol);
}
代码示例来源:origin: com.nexitia.emaginplatform/emagin-jfxcore-engine
@SuppressWarnings({"unchecked"})
private void addSelectColumn() {
headerCheckboxCol.setPrefWidth(40);
headerCheckboxCol.setCellValueFactory(new PropertyValueFactory<>("selected"));
headerCheckboxCol.setCellFactory(param -> buildCell());
headerCheckboxCol.setGraphic(headerColCheckbox);
headerCheckboxCol.setVisible(false);
tableView.getColumns().add(0, headerCheckboxCol);
}
代码示例来源:origin: stackoverflow.com
private void makeHeaderWrappable(TableColumn col) {
Label label = new Label(col.getText());
label.setStyle("-fx-padding: 8px;");
label.setWrapText(true);
label.setAlignment(Pos.CENTER);
label.setTextAlignment(TextAlignment.CENTER);
StackPane stack = new StackPane();
stack.getChildren().add(label);
stack.prefWidthProperty().bind(col.widthProperty().subtract(5));
label.prefWidthProperty().bind(stack.prefWidthProperty());
col.setGraphic(stack);
}
代码示例来源:origin: org.controlsfx/controlsfx
.forEach(fp -> {
if (!fp.columnFilter.hasUnselections()) {
fp.columnFilter.getTableColumn().setGraphic(null);
} else {
fp.columnFilter.getTableColumn().setGraphic(filterImageView.get());
if (!bumpedWidth) {
fp.columnFilter.getTableColumn().setPrefWidth(columnFilter.getTableColumn().getWidth() + 20);
columnFilter.getTableFilter().getColumnFilters().stream().forEach(cf -> cf.getTableColumn().setGraphic(null));
contextMenu.hide();
});
代码示例来源:origin: com.aquafx-project/aquafx
final Node graphic1 = new ImageView(new Image("file:src/helloworld/about_16.png"));
lastNameCol = new TableColumn<Person, String>();
lastNameCol.setGraphic(graphic1);
lastNameCol.setText("Last");
lastNameCol.setSortType(TableColumn.SortType.DESCENDING);
内容来源于网络,如有侵权,请联系作者删除!