use of java.awt.GridLayout in project knime-core by knime.
the class DataValidatorColPanel method createWarningLabel.
/**
* @param warningMessages
* @return
*/
private static Component createWarningLabel(final List<String> warningMessages) {
JPanel thin = new JPanel(new GridLayout(warningMessages.size(), 1));
for (int i = 0; i < warningMessages.size(); i++) {
String message = warningMessages.get(i);
thin.add(new JLabel(message));
}
return thin;
}
use of java.awt.GridLayout in project knime-core by knime.
the class DataValidatorNodeDialogPane method updateDataTableSpecComparison.
private void updateDataTableSpecComparison() {
m_refTableSpecTab.removeAll();
JPanel northern = new JPanel(new GridLayout(0, 1));
DataTableSpecView refTableSpecView = new DataTableSpecView(m_referenceDataTableSpec);
refTableSpecView.setPreferredSize(new Dimension(-1, 150));
northern.add(new JScrollPane(refTableSpecView, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED));
northern.setBorder(BorderFactory.createTitledBorder("Reference Table Spec"));
if (!m_referenceDataTableSpec.equals(m_inputDataTableSpec)) {
m_refTableSpecTab.add(northern);
JPanel southern = new JPanel(new GridLayout(0, 1));
southern.setBorder(BorderFactory.createTitledBorder("Input Table Spec"));
DataTableSpecView inputTableSpec = new DataTableSpecView(m_inputDataTableSpec);
inputTableSpec.setPreferredSize(new Dimension(-1, 150));
southern.add(new JScrollPane(inputTableSpec, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED));
m_refTableSpecTab.add(new JSplitPane(JSplitPane.VERTICAL_SPLIT, northern, southern));
} else {
m_refTableSpecTab.add(northern);
}
}
use of java.awt.GridLayout in project knime-core by knime.
the class DomainNodeDialogPane method createMinMaxTab.
private JPanel createMinMaxTab() {
JPanel minMaxPanel = new JPanel(new BorderLayout());
minMaxPanel.add(m_filterPanelMinMax, BorderLayout.CENTER);
JPanel retainMinMaxPanel = new JPanel(new GridLayout(0, 1));
retainMinMaxPanel.setBorder(BorderFactory.createTitledBorder(UNSELECTED_LABEL));
ButtonGroup group = new ButtonGroup();
group.add(m_minMaxUnselectedRetainButton);
group.add(m_minMaxUnselectedDropButton);
m_minMaxUnselectedRetainButton.doClick();
retainMinMaxPanel.add(m_minMaxUnselectedRetainButton);
retainMinMaxPanel.add(m_minMaxUnselectedDropButton);
JPanel southPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
southPanel.add(retainMinMaxPanel);
minMaxPanel.add(southPanel, BorderLayout.SOUTH);
return minMaxPanel;
}
use of java.awt.GridLayout in project knime-core by knime.
the class DomainNodeDialogPane method createPossValueTab.
private JPanel createPossValueTab() {
JPanel possValPanel = new JPanel(new BorderLayout());
possValPanel.add(m_filterPanelPossValues, BorderLayout.CENTER);
JPanel southPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
JPanel retainPossValPanel = new JPanel(new GridLayout(0, 1));
retainPossValPanel.setBorder(BorderFactory.createTitledBorder(UNSELECTED_LABEL));
ButtonGroup group = new ButtonGroup();
group.add(m_possValUnselectedRetainButton);
group.add(m_possValUnselectedDropButton);
m_possValUnselectedRetainButton.doClick();
retainPossValPanel.add(m_possValUnselectedRetainButton);
retainPossValPanel.add(m_possValUnselectedDropButton);
southPanel.add(retainPossValPanel);
southPanel.add(new JLabel(" "));
southPanel.add(m_maxValuesChecker);
southPanel.add(m_maxValuesSpinner);
possValPanel.add(southPanel, BorderLayout.SOUTH);
return possValPanel;
}
use of java.awt.GridLayout in project knime-core by knime.
the class Joiner2NodeDialog method createDuplicateColumnHandlingUIConstrols.
/**
* @return the duplicate column handling panel
* @since 2.12
* @noreference This method is not intended to be referenced by clients.
*/
protected JPanel createDuplicateColumnHandlingUIConstrols() {
JPanel left = new JPanel(new GridBagLayout());
GridBagConstraints c = new GridBagConstraints();
c.fill = GridBagConstraints.HORIZONTAL;
c.anchor = GridBagConstraints.NORTHWEST;
c.insets = new Insets(2, 2, 2, 2);
c.gridx = 0;
c.gridy = 0;
c.weightx = 0;
c.gridwidth = 1;
left.add(m_filterDuplicates, c);
c.gridy++;
left.add(m_dontExecute, c);
c.gridy++;
left.add(m_appendSuffixAutomatic, c);
c.gridy++;
left.add(m_appendSuffix, c);
c.gridx++;
m_suffix.setPreferredSize(new Dimension(100, m_suffix.getPreferredSize().height));
left.add(m_suffix, c);
m_appendSuffix.addChangeListener(new ChangeListener() {
@Override
public void stateChanged(final ChangeEvent e) {
m_suffix.setEnabled(m_appendSuffix.isSelected());
}
});
ButtonGroup duplicateColGroup = new ButtonGroup();
duplicateColGroup.add(m_filterDuplicates);
duplicateColGroup.add(m_dontExecute);
duplicateColGroup.add(m_appendSuffixAutomatic);
duplicateColGroup.add(m_appendSuffix);
left.setBorder(BorderFactory.createTitledBorder("Duplicate Column Handling"));
JPanel right = new JPanel(new GridBagLayout());
c.gridx = 0;
c.gridy = 0;
right.add(m_removeLeftJoinCols, c);
c.gridy++;
right.add(m_removeRightJoinCols, c);
right.setBorder(BorderFactory.createTitledBorder("Joining Columns Handling"));
JPanel p = new JPanel(new GridLayout(1, 2));
p.add(left);
p.add(right);
return p;
}
Aggregations