Search in sources :

Example 26 with CheckBox

use of com.intellij.util.ui.CheckBox in project intellij-community by JetBrains.

the class MethodCountInspection method createOptionsPanel.

@Override
public JComponent createOptionsPanel() {
    final JComponent panel = new JPanel(new GridBagLayout());
    final Component label = new JLabel(InspectionGadgetsBundle.message("method.count.limit.option"));
    final JFormattedTextField valueField = prepareNumberEditor("m_limit");
    final GridBagConstraints constraints = new GridBagConstraints();
    constraints.gridx = 0;
    constraints.gridy = 0;
    constraints.insets.right = UIUtil.DEFAULT_HGAP;
    constraints.anchor = GridBagConstraints.WEST;
    panel.add(label, constraints);
    constraints.gridx = 1;
    constraints.weightx = 1.0;
    constraints.insets.right = 0;
    panel.add(valueField, constraints);
    final CheckBox gettersSettersCheckBox = new CheckBox(InspectionGadgetsBundle.message("method.count.ignore.getters.setters.option"), this, "ignoreGettersAndSetters");
    constraints.gridx = 0;
    constraints.gridy = 1;
    constraints.gridwidth = 2;
    constraints.anchor = GridBagConstraints.WEST;
    panel.add(gettersSettersCheckBox, constraints);
    final CheckBox overridingMethodCheckBox = new CheckBox(InspectionGadgetsBundle.message("ignore.methods.overriding.super.method"), this, "ignoreOverridingMethods");
    constraints.weighty = 1.0;
    constraints.gridy = 2;
    constraints.anchor = GridBagConstraints.NORTHWEST;
    panel.add(overridingMethodCheckBox, constraints);
    return panel;
}
Also used : CheckBox(com.intellij.util.ui.CheckBox)

Example 27 with CheckBox

use of com.intellij.util.ui.CheckBox in project intellij-community by JetBrains.

the class PyPep8NamingInspection method createOptionsPanel.

@Nullable
@Override
public JComponent createOptionsPanel() {
    final JPanel rootPanel = new JPanel(new BorderLayout());
    rootPanel.add(new CheckBox("Ignore overridden functions", this, "ignoreOverriddenFunctions"), BorderLayout.NORTH);
    final OnePixelSplitter splitter = new OnePixelSplitter(false);
    splitter.setFirstComponent(new ListEditForm("Excluded base classes", ignoredBaseClasses).getContentPanel());
    splitter.setSecondComponent(new ListEditForm("Ignored errors", ignoredErrors).getContentPanel());
    rootPanel.add(splitter, BorderLayout.CENTER);
    return rootPanel;
}
Also used : CheckBox(com.intellij.util.ui.CheckBox) ListEditForm(com.intellij.codeInspection.ui.ListEditForm) OnePixelSplitter(com.intellij.ui.OnePixelSplitter) Nullable(org.jetbrains.annotations.Nullable)

Example 28 with CheckBox

use of com.intellij.util.ui.CheckBox in project intellij-community by JetBrains.

the class PyChainedComparisonsInspection method createOptionsPanel.

@Nullable
@Override
public JComponent createOptionsPanel() {
    final JPanel rootPanel = new JPanel(new BorderLayout());
    rootPanel.add(new CheckBox(ourIgnoreConstantOptionText, this, "ignoreConstantInTheMiddle"), BorderLayout.PAGE_START);
    return rootPanel;
}
Also used : CheckBox(com.intellij.util.ui.CheckBox) Nullable(org.jetbrains.annotations.Nullable)

Aggregations

CheckBox (com.intellij.util.ui.CheckBox)28 ListTable (com.intellij.codeInspection.ui.ListTable)9 ListWrappingTableModel (com.intellij.codeInspection.ui.ListWrappingTableModel)9 Nullable (org.jetbrains.annotations.Nullable)5 DocumentAdapter (com.intellij.ui.DocumentAdapter)2 NumberFormat (java.text.NumberFormat)2 DocumentEvent (javax.swing.event.DocumentEvent)2 Document (javax.swing.text.Document)2 NotNull (org.jetbrains.annotations.NotNull)2 ListEditForm (com.intellij.codeInspection.ui.ListEditForm)1 RegExFormatter (com.intellij.codeInspection.ui.RegExFormatter)1 RegExInputVerifier (com.intellij.codeInspection.ui.RegExInputVerifier)1 OnePixelSplitter (com.intellij.ui.OnePixelSplitter)1 VerticalLayout (com.intellij.ui.components.panels.VerticalLayout)1 GridBag (com.intellij.util.ui.GridBag)1 TextField (com.siyeh.ig.ui.TextField)1 ParseException (java.text.ParseException)1 Pattern (java.util.regex.Pattern)1 PatternSyntaxException (java.util.regex.PatternSyntaxException)1