Java Code Examples for org.eclipse.jface.viewers.TreeViewer#setColumnProperties()
The following examples show how to use
org.eclipse.jface.viewers.TreeViewer#setColumnProperties() .
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: NodeStatsTableControl.java From depan with Apache License 2.0 | 5 votes |
@Override protected TreeViewer createTreeViewer(Composite parent) { TreeViewer result = super.createTreeViewer(parent); // Initialize the table. Tree tree = result.getTree(); tree.setHeaderVisible(true); tree.setToolTipText("Node Display Properties"); EditColTableDef.setupTree(TABLE_DEF, tree); result.setLabelProvider(new PartLabelProvider()); result.setColumnProperties(EditColTableDef.getProperties(TABLE_DEF)); return result; }
Example 2
Source File: NodeDisplayTableControl.java From depan with Apache License 2.0 | 5 votes |
@Override protected TreeViewer createTreeViewer(Composite parent) { TreeViewer result = super.createTreeViewer(parent); // Initialize the table. Tree tree = result.getTree(); tree.setHeaderVisible(true); tree.setToolTipText("Node Display Properties"); EditColTableDef.setupTree(TABLE_DEF, tree); // Configure cell editing. CellEditor[] cellEditors = new CellEditor[TABLE_DEF.length]; cellEditors[INDEX_NAME] = null; cellEditors[INDEX_SELECTED] = new CheckboxCellEditor(tree); cellEditors[INDEX_XPOS] = new TextCellEditor(tree); cellEditors[INDEX_YPOS] = new TextCellEditor(tree); cellEditors[INDEX_VISIBLE] = new CheckboxCellEditor(tree); cellEditors[INDEX_SIZE] = new ComboBoxCellEditor( tree, buildSizeOptions()); cellEditors[INDEX_COLOR] = new ColorCellEditor(tree); result.setCellEditors(cellEditors); result.setLabelProvider(new PartLabelProvider()); result.setColumnProperties(EditColTableDef.getProperties(TABLE_DEF)); result.setCellModifier(new PartCellModifier()); return result; }