本文整理汇总了Java中com.rapidminer.gui.look.ui.TableHeaderUI类的典型用法代码示例。如果您正苦于以下问题:Java TableHeaderUI类的具体用法?Java TableHeaderUI怎么用?Java TableHeaderUI使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
TableHeaderUI类属于com.rapidminer.gui.look.ui包,在下文中一共展示了TableHeaderUI类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getVisualizationComponent
import com.rapidminer.gui.look.ui.TableHeaderUI; //导入依赖的package包/类
@Override
public Component getVisualizationComponent(Object renderable, IOContainer ioContainer) {
TableModel tableModel = getTableModel(renderable, ioContainer, false);
if (tableModel != null) {
ExtendedJTable table = new ExtendedJTable(getTableModel(renderable, ioContainer, false), isSortable(),
isColumnMovable(), isAutoresize());
table.setRowHighlighting(true);
table.setRowHeight(PropertyPanel.VALUE_CELL_EDITOR_HEIGHT);
table.getTableHeader().putClientProperty(RapidLookTools.PROPERTY_TABLE_HEADER_BACKGROUND, Colors.WHITE);
((TableHeaderUI) table.getTableHeader().getUI()).installDefaults();
JScrollPane sp = new ExtendedJScrollPane(table);
sp.setBorder(BorderFactory.createEmptyBorder(42, 10, 10, 10));
sp.setBackground(Colors.WHITE);
sp.getViewport().setBackground(Colors.WHITE);
JPanel panel = new JPanel(new BorderLayout());
panel.add(sp, BorderLayout.CENTER);
return panel;
} else {
return ResultDisplayTools.createErrorComponent("No visualization possible for table.");
}
}
示例2: ANOVAMatrixViewer
import com.rapidminer.gui.look.ui.TableHeaderUI; //导入依赖的package包/类
public ANOVAMatrixViewer(ANOVAMatrix matrix) {
super(new BorderLayout());
JPanel panel = new JPanel(new GridBagLayout());
panel.setOpaque(true);
panel.setBackground(Colors.WHITE);
GridBagConstraints gbc = new GridBagConstraints();
gbc.gridx = 0;
gbc.gridy = 0;
gbc.weightx = 1.0;
gbc.weighty = 1.0;
gbc.fill = GridBagConstraints.BOTH;
gbc.insets = new Insets(42, 10, 20, 10);
// table
ANOVAMatrixViewerTable table = new ANOVAMatrixViewerTable(matrix);
table.getTableHeader().putClientProperty(RapidLookTools.PROPERTY_TABLE_HEADER_BACKGROUND, Colors.WHITE);
((TableHeaderUI) table.getTableHeader().getUI()).installDefaults();
table.setRowHighlighting(true);
table.setRowHeight(PropertyPanel.VALUE_CELL_EDITOR_HEIGHT);
JScrollPane scrollPane = new ExtendedJScrollPane(table);
scrollPane.setBorder(null);
scrollPane.setBackground(Colors.WHITE);
scrollPane.getViewport().setBackground(Colors.WHITE);
panel.add(scrollPane, gbc);
// info string
JLabel infoText = new JLabel();
infoText.setText("A colored background indicates that the probability for non-difference between the groups is less than "
+ Tools.formatNumber(matrix.getSignificanceLevel()));
gbc.gridy += 1;
gbc.insets = new Insets(5, 10, 5, 10);
gbc.weighty = 0.0;
gbc.fill = GridBagConstraints.HORIZONTAL;
panel.add(infoText, gbc);
add(panel, BorderLayout.CENTER);
}