javafx.scene.control.TableColumnBase Java Examples
The following examples show how to use
javafx.scene.control.TableColumnBase.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ResizableJfxTreeTableView.java From milkman with MIT License | 6 votes |
public void resizeColumns() { try { Method method = getClass().getClassLoader() .loadClass("javafx.scene.control.skin.TableSkinUtils") .getMethod("resizeColumnToFitContent", TableViewSkinBase.class, TableColumnBase.class, int.class); method.setAccessible(true); for (TreeTableColumn<R, ?> column : this.getColumns()) { method.invoke(null, getSkin(), column, -1); } } catch (Throwable t) { //for some reason, a NPE will be thrown now and then, some racing condition? log.warn("Failed to resize columns"); } // TableSkinUtils.resizeColumnToFitContent((TableViewSkinBase<?, ?, ?, ?, ?>) getSkin(), getTreeColumn(), -1); // ((ResizableJfxTreeTableViewSkin<R>)getSkin()).resizeAllColumns(); }
Example #2
Source File: Tools.java From logbook-kai with MIT License | 6 votes |
/** * TableColumnの名前を取得する * @param column TableColumn * @return TableColumnの名前 */ public static String getColumnName(TableColumn<?, ?> column) { LinkedList<String> names = null; TableColumnBase<?, ?> parent = column; while ((parent = parent.getParentColumn()) != null) { if (names == null) { names = new LinkedList<>(); } names.addFirst(parent.getText()); } if (names != null) { return names.stream().collect(Collectors.joining(".")) + "." + column.getText(); } else { return column.getText(); } }
Example #3
Source File: JFXNestedTableColumnHeader.java From JFoenix with Apache License 2.0 | 4 votes |
public JFXNestedTableColumnHeader(TableViewSkinBase skin, TableColumnBase tc) { super(skin, tc); }
Example #4
Source File: JFXNestedTableColumnHeader.java From JFoenix with Apache License 2.0 | 4 votes |
protected TableColumnHeader createTableColumnHeader(TableColumnBase col) { return col.getColumns().isEmpty() ? new JFXTableColumnHeader(getTableViewSkin(), col) : new NestedTableColumnHeader(getTableViewSkin(), col); }
Example #5
Source File: JFXTableColumnHeader.java From JFoenix with Apache License 2.0 | 4 votes |
public JFXTableColumnHeader(TableViewSkinBase skin, TableColumnBase tc) { super(skin, tc); }