Search in sources :

Example 6 with TitledSeparator

use of com.intellij.ui.TitledSeparator in project android by JetBrains.

the class AndroidDeviceRenderer method renderTitledSeparator.

private static Component renderTitledSeparator(@NotNull String title) {
    TitledSeparator separator = new TitledSeparator(title);
    separator.setBackground(UIUtil.getListBackground());
    separator.setTitleFont(UIUtil.getLabelFont());
    return separator;
}
Also used : TitledSeparator(com.intellij.ui.TitledSeparator)

Example 7 with TitledSeparator

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

the class SearchDialog method createCenterPanel.

@Override
protected JComponent createCenterPanel() {
    myContentPanel = new JPanel(new BorderLayout());
    myEditorPanel = createEditorContent();
    myContentPanel.add(BorderLayout.CENTER, myEditorPanel);
    myContentPanel.add(BorderLayout.SOUTH, Box.createVerticalStrut(8));
    JComponent centerPanel = new JPanel(new BorderLayout());
    {
        JPanel panel = new JPanel(new BorderLayout());
        panel.add(BorderLayout.CENTER, myContentPanel);
        panel.add(BorderLayout.SOUTH, createTemplateManagementButtons());
        centerPanel.add(BorderLayout.CENTER, panel);
    }
    JPanel optionsContent = new JPanel(new BorderLayout());
    centerPanel.add(BorderLayout.SOUTH, optionsContent);
    JPanel searchOptions = new JPanel();
    searchOptions.setLayout(new GridLayout(getRowsCount(), 1, 0, 0));
    searchOptions.setBorder(IdeBorderFactory.createTitledBorder(SSRBundle.message("ssdialog.options.group.border"), true));
    myScopeChooserCombo = new ScopeChooserCombo(searchContext.getProject(), true, false, FindSettings.getInstance().getDefaultScopeName());
    Disposer.register(myDisposable, myScopeChooserCombo);
    JPanel allOptions = new JPanel(new BorderLayout());
    if (myShowScopePanel) {
        JPanel scopePanel = new JPanel(new GridBagLayout());
        TitledSeparator separator = new TitledSeparator(SSRBundle.message("search.dialog.scope.label"), myScopeChooserCombo.getComboBox());
        scopePanel.add(separator, new GridBagConstraints(0, 0, 1, 1, 1, 1, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, JBUI.insetsTop(5), 0, 0));
        scopePanel.add(myScopeChooserCombo, new GridBagConstraints(0, 1, 1, 1, 1, 1, GridBagConstraints.WEST, GridBagConstraints.HORIZONTAL, JBUI.insetsLeft(10), 0, 0));
        allOptions.add(scopePanel, BorderLayout.SOUTH);
        myScopeChooserCombo.getComboBox().addItemListener(new ItemListener() {

            @Override
            public void itemStateChanged(ItemEvent e) {
                initiateValidation();
            }
        });
    }
    buildOptions(searchOptions);
    allOptions.add(searchOptions, BorderLayout.CENTER);
    optionsContent.add(allOptions, BorderLayout.CENTER);
    if (myRunFindActionOnClose) {
        JPanel panel = new JPanel(new BorderLayout());
        panel.setBorder(BorderFactory.createEmptyBorder(0, 4, 0, 0));
        openInNewTab = new JCheckBox(FindBundle.message("find.open.in.new.tab.checkbox"));
        openInNewTab.setSelected(FindSettings.getInstance().isShowResultsInSeparateView());
        ToolWindow findWindow = ToolWindowManager.getInstance(searchContext.getProject()).getToolWindow(ToolWindowId.FIND);
        openInNewTab.setEnabled(findWindow != null && findWindow.isAvailable());
        panel.add(openInNewTab, BorderLayout.EAST);
        optionsContent.add(BorderLayout.SOUTH, panel);
    }
    updateEditor();
    return centerPanel;
}
Also used : ItemEvent(java.awt.event.ItemEvent) ScopeChooserCombo(com.intellij.ide.util.scopeChooser.ScopeChooserCombo) ToolWindow(com.intellij.openapi.wm.ToolWindow) TitledSeparator(com.intellij.ui.TitledSeparator) ItemListener(java.awt.event.ItemListener)

Example 8 with TitledSeparator

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

the class InferNullityAnnotationsAction method getAdditionalActionSettings.

@Override
protected JComponent getAdditionalActionSettings(Project project, BaseAnalysisActionDialog dialog) {
    final JPanel panel = new JPanel(new VerticalFlowLayout());
    panel.add(new TitledSeparator());
    myAnnotateLocalVariablesCb = new JCheckBox("Annotate local variables", PropertiesComponent.getInstance().getBoolean(ANNOTATE_LOCAL_VARIABLES));
    panel.add(myAnnotateLocalVariablesCb);
    return panel;
}
Also used : TitledSeparator(com.intellij.ui.TitledSeparator) VerticalFlowLayout(com.intellij.openapi.ui.VerticalFlowLayout)

Example 9 with TitledSeparator

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

the class UpdateCopyrightAction method getAdditionalActionSettings.

@Nullable
@Override
protected JComponent getAdditionalActionSettings(Project project, BaseAnalysisActionDialog dialog) {
    final JPanel panel = new JPanel(new VerticalFlowLayout());
    panel.add(new TitledSeparator());
    myUpdateExistingCopyrightsCb = new JCheckBox("Update existing copyrights", PropertiesComponent.getInstance().getBoolean(UPDATE_EXISTING_COPYRIGHTS, true));
    panel.add(myUpdateExistingCopyrightsCb);
    return panel;
}
Also used : TitledSeparator(com.intellij.ui.TitledSeparator) VerticalFlowLayout(com.intellij.openapi.ui.VerticalFlowLayout) Nullable(org.jetbrains.annotations.Nullable)

Aggregations

TitledSeparator (com.intellij.ui.TitledSeparator)9 VerticalFlowLayout (com.intellij.openapi.ui.VerticalFlowLayout)3 Nullable (org.jetbrains.annotations.Nullable)2 AnalysisScope (com.intellij.analysis.AnalysisScope)1 AnalysisUIOptions (com.intellij.analysis.AnalysisUIOptions)1 BaseAnalysisActionDialog (com.intellij.analysis.BaseAnalysisActionDialog)1 CleanupLocalInspectionTool (com.intellij.codeInspection.CleanupLocalInspectionTool)1 InspectionProfile (com.intellij.codeInspection.InspectionProfile)1 InspectionManagerEx (com.intellij.codeInspection.ex.InspectionManagerEx)1 InspectionProfileImpl (com.intellij.codeInspection.ex.InspectionProfileImpl)1 InspectionToolWrapper (com.intellij.codeInspection.ex.InspectionToolWrapper)1 ScopeChooserCombo (com.intellij.ide.util.scopeChooser.ScopeChooserCombo)1 AnActionEvent (com.intellij.openapi.actionSystem.AnActionEvent)1 Module (com.intellij.openapi.module.Module)1 UnnamedConfigurable (com.intellij.openapi.options.UnnamedConfigurable)1 Project (com.intellij.openapi.project.Project)1 Splitter (com.intellij.openapi.ui.Splitter)1 ToolWindow (com.intellij.openapi.wm.ToolWindow)1 GlobalSearchScope (com.intellij.psi.search.GlobalSearchScope)1 EditorTextField (com.intellij.ui.EditorTextField)1