public GoVendoringUI() { myPanel.setBorder(IdeBorderFactory.createTitledBorder("Vendor experiment")); }
public VimSettingsPanel(@NotNull VimShortcutConflictsTable.Model model) { myShortcutConflictsTable = new VimShortcutConflictsTable(model); setLayout(new BorderLayout()); final JScrollPane scrollPane = new JBScrollPane(myShortcutConflictsTable); scrollPane.setBorder(new LineBorder(UIUtil.getBorderColor())); final JPanel conflictsPanel = new JPanel(new BorderLayout()); final String title = String.format("Shortcut Conflicts for Active Keymap"); conflictsPanel.setBorder(IdeBorderFactory.createTitledBorder(title, false)); conflictsPanel.add(scrollPane); add(conflictsPanel, BorderLayout.CENTER); } }
@Nullable @Override public JComponent createComponent() { FormBuilder builder = FormBuilder.createFormBuilder(); myCbShowImportPopup = new JCheckBox(ApplicationBundle.message("checkbox.show.import.popup")); myCbAddUnambiguousImports = new JCheckBox(ApplicationBundle.message("checkbox.add.unambiguous.imports.on.the.fly")); builder.addComponent(myCbShowImportPopup); builder.addComponent(myCbAddUnambiguousImports); myExcludePackagesList = new JBList(); JComponent excludedPanel = new JPanel(new BorderLayout()); excludedPanel.add(ToolbarDecorator.createDecorator(myExcludePackagesList) .setAddAction(new AddImportExclusionAction()).disableUpDownActions().createPanel(), BorderLayout.CENTER); excludedPanel.setBorder(IdeBorderFactory.createTitledBorder(ApplicationBundle.message("exclude.from.completion.group"), true)); if (!myIsDefaultProject) { builder.addComponent(excludedPanel); } JPanel result = new JPanel(new BorderLayout()); result.add(builder.getPanel(), BorderLayout.NORTH); if (myIsDialog) result.setPreferredSize(new Dimension(300, -1)); return result; }
@SuppressWarnings("unchecked") public GoBuildTagsUI() { myPanel.setBorder(IdeBorderFactory.createTitledBorder("Build tags")); myDefaultOSValue = "Default (" + GoUtil.systemOS() + ")"; myDefaultArchValue = "Default (" + GoUtil.systemArch() + ")"; myDefaultCgo = "Default (" + cgo(GoUtil.systemCgo(myDefaultOSValue, myDefaultArchValue)) + ")"; myCustomTagsField.setDialogCaption("Custom Build Tags"); myOSCombo.setModel(createModel(GoConstants.KNOWN_OS, myDefaultOSValue)); myArchCombo.setModel(createModel(GoConstants.KNOWN_ARCH, myDefaultArchValue)); myCgoComboModel = createModel(ContainerUtil.newArrayList(ENABLED, DISABLED), myDefaultCgo); myCgoCombo.setModel(myCgoComboModel); myCompilerCombo.setModel(createModel(GoConstants.KNOWN_COMPILERS, GoBuildTargetSettings.ANY_COMPILER)); ActionListener updateCgoListener = event -> { String selected = StringUtil.notNullize(myCgoComboModel.getSelected(), myDefaultCgo); String oldDefault = myDefaultCgo; String os = expandDefault(selected(myOSCombo, myDefaultOSValue), GoUtil.systemOS()); String arch = expandDefault(selected(myArchCombo, myDefaultArchValue), GoUtil.systemArch()); myDefaultCgo = "Default (" + cgo(GoUtil.systemCgo(os, arch)) + ")"; myCgoComboModel.update(ContainerUtil.newArrayList(myDefaultCgo, ENABLED, DISABLED)); myCgoComboModel.setSelectedItem(oldDefault.equals(selected) ? myDefaultCgo : selected); }; myOSCombo.addActionListener(updateCgoListener); myArchCombo.addActionListener(updateCgoListener); }
mongoShellOptionsPanel.setBorder(IdeBorderFactory.createTitledBorder("Mongo shell options", true)); shellArgumentsLineField.setDialogCaption("Mongo arguments");
@SuppressWarnings("unchecked") MongoRunConfigurationEditor(Project project) { mongoShellOptionsPanel.setBorder(IdeBorderFactory.createTitledBorder("Mongo shell options", true));
public GlobalExclusionsPanel() { Border b = IdeBorderFactory.createTitledBorder(BORDER_TITLE); panel.setBorder(b); }
JPanel getPanel() { JPanel panel = new JPanel(); panel.setBorder(IdeBorderFactory.createTitledBorder(TEXT_TITLE_ACTIONS)); panel.setLayout(new BoxLayout(panel, BoxLayout.PAGE_AXIS)); panel.add(checkboxes.get(activate)); panel.add(checkboxes.get(activateOnShortcut)); panel.add(checkboxes.get(activateOnBatch)); panel.add(checkboxes.get(noActionIfCompileErrors)); panel.add(Box.createHorizontalGlue()); panel.setMinimumSize(new Dimension(Short.MAX_VALUE, 0)); return panel; }
JPanel getPanel() { JPanel panel = new JPanel(); panel.setBorder(IdeBorderFactory.createTitledBorder(TEXT_TITLE_ACTIONS)); panel.setLayout(new BoxLayout(panel, BoxLayout.PAGE_AXIS)); panel.add(checkboxes.get(organizeImports)); panel.add(checkboxes.get(reformat)); panel.add(checkboxes.get(reformatChangedCode)); panel.add(checkboxes.get(rearrange)); panel.add(Box.createHorizontalGlue()); panel.setMinimumSize(new Dimension(Short.MAX_VALUE, 0)); return panel; }
public JPanel getPanel() { JPanel panel = new JPanel(); if (!SaveActionManager.getInstance().isJavaAvailable()) { return panel; } panel.setBorder(IdeBorderFactory.createTitledBorder(TEXT_TITLE_INSPECTIONS)); panel.setLayout(new BoxLayout(panel, BoxLayout.PAGE_AXIS)); Action.stream(java).map(checkboxes::get).forEach(panel::add); panel.add(Box.createHorizontalGlue()); panel.setMinimumSize(new Dimension(Short.MAX_VALUE, 0)); return panel; }
BuildPanel(Map<Action, JCheckBox> checkboxes, List<String> quickLists) { quickListElements = new ArrayList<>(); quickListModel = new ListComboBoxModel<>(quickListElements); quickListModel.addListDataListener(getListDataListener(quickLists)); panel = new JPanel(); panel.setBorder(IdeBorderFactory.createTitledBorder(TEXT_TITLE_ACTIONS)); panel.setLayout(new BoxLayout(panel, BoxLayout.PAGE_AXIS)); if (SaveActionManager.getInstance().isCompilingAvailable()) { panel.add(wrap(checkboxes.get(compile), null)); panel.add(wrap(checkboxes.get(reload), null)); } // @SuppressWarnings("unchecked") // JComboBox<QuickListWrapper> comboBox = new ComboBox<QuickListWrapper>(quickListModel); // panel.add(wrap(checkboxes.get(executeAction), comboBox)); panel.add(Box.createHorizontalGlue()); panel.setMinimumSize(new Dimension(MAX_VALUE, 0)); }
private void createUIComponents() { impexLabel = new JBLabel(); impexLabel.setBorder(IdeBorderFactory.createTitledBorder(HybrisI18NBundleUtils.message( "hybris.import.settings.impex.title"), false)); projectImportLabel = new JBLabel(); projectImportLabel.setBorder(IdeBorderFactory.createTitledBorder(HybrisI18NBundleUtils.message( "hybris.import.settings.project.title"))); junkListPanel = new MyListPanel("hybris.import.settings.junk.directory.name", "hybris.import.settings.junk.directory.popup.add.title", "hybris.import.settings.junk.directory.popup.add.text", "hybris.import.settings.junk.directory.popup.edit.title", "hybris.import.settings.junk.directory.popup.edit.text", new ArrayList<String>()); junkDirectoriesPanel = junkListPanel; tsdListPanel = new MyListPanel("hybris.import.settings.tsv.diagram.name", "hybris.import.settings.tsv.diagram.popup.add.title", "hybris.import.settings.tsv.diagram.popup.add.text", "hybris.import.settings.tsv.diagram.popup.edit.title", "hybris.import.settings.tsv.diagram.popup.edit.text", new ArrayList<String>()); typeSystemDiagramStopWords = tsdListPanel; extensionsResourcesToExcludeListPanel = new MyListPanel("hybris.import.settings.exclude.resources.name", "hybris.import.settings.exclude.resources.popup.add.title", "hybris.import.settings.exclude.resources.popup.add.text", "hybris.import.settings.exclude.resources.popup.edit.title", "hybris.import.settings.exclude.resources.popup.edit.text", new ArrayList<String>()); extensionsResourcesToExclude = extensionsResourcesToExcludeListPanel; projectTreeViewSettingsLabel = new JBLabel(); projectTreeViewSettingsLabel.setBorder(IdeBorderFactory.createTitledBorder(HybrisI18NBundleUtils.message( "hybris.project.view.tree.settings"))); }
insertPanel.setBorder(IdeBorderFactory.createTitledBorder("Insert completion on SmartEnter")); panel.add(panel = new JPanel(new BorderLayout()), BorderLayout.NORTH); panel.add(insertPanel, BorderLayout.NORTH); sortPanel.setBorder(IdeBorderFactory.createTitledBorder("Sorting of completion entries")); panel.add(panel = new JPanel(new BorderLayout()), BorderLayout.SOUTH); panel.add(sortPanel, BorderLayout.SOUTH);
private void fillChangedFilesList() { DefaultListModel model = new DefaultListModel(); if (changeLists != null && (changeLists.length > 0)) { StringBuilder builder = new StringBuilder(); int count = 1; for(ChangeList changeList: changeLists) { builder.append(changeList.getName()); if (count < changeLists.length) { builder.append(", "); } if (changeList.getChanges().size() > 0) { for(Change change: changeList.getChanges()) { VirtualFile virtualFile = change.getVirtualFile(); if (null != virtualFile) { model.addElement(virtualFile.getPath()); } } } count++; } changedFilesPane.setBorder(IdeBorderFactory.createTitledBorder(String.format("Changelists: %s", builder.toString()), true)); } changedFilesList.setModel(model); }
public JPanel getPanel(String configurationPath) { JPanel panel = new JPanel(); if (!SaveActionManager.getInstance().isJavaAvailable()) { return panel; } panel.setBorder(IdeBorderFactory.createTitledBorder(TITLE)); panel.setLayout(new BorderLayout()); JBLabel label = getLabel(); path = getPath(configurationPath); JButton reset = getResetButton(path); panel.add(label, WEST); panel.add(path, CENTER); panel.add(reset, EAST); panel.setMaximumSize(new Dimension(BOX_LAYOUT_MAX_WIDTH, BOX_LAYOUT_MAX_HEIGHT)); return panel; }
/** * Initializes some UI components in this panel that require special set-up. * * <p>This is automatically called by the IDEA SDK and should not be directly invoked. */ private void createUIComponents() { descriptionTextPane = new JTextPane(); descriptionTextPane.setOpaque(false); linksTextPane = new JTextPane(); linksTextPane.setOpaque(false); linksTextPane.addHyperlinkListener(new BrowserOpeningHyperLinkListener()); apiManagementPanel = new JPanel(); apiManagementPanel.setBorder( IdeBorderFactory.createTitledBorder( GoogleCloudApisMessageBundle.message("cloud.apis.management.section.title"))); managementWarningTextPane = new JTextPane(); managementWarningTextPane.setOpaque(false); warningLabel = new JLabel(); warningLabel.setIcon(General.Information); enableApiCheckbox = new JCheckBox(); enableApiCheckbox.addActionListener( event -> currentCloudApiManagementSpec.setShouldEnable( ((JCheckBox) event.getSource()).isSelected())); }
private void createBindPanel() { Border b = IdeBorderFactory.createTitledBorder("Project binding");
panel.setBorder(IdeBorderFactory.createTitledBorder(ProjectBundle.message("project.roots.output.compiler.title"),true)); panel.add(outputPathsPanel, BorderLayout.NORTH); return panel;
emptyPanel.add(emptyLabel, BorderLayout.CENTER); Border b = IdeBorderFactory.createTitledBorder("SonarQube servers"); panel = new JPanel(new BorderLayout()); panel.setBorder(b);
FileMaskPanel(Set<String> patterns, String textEmpty, String textTitle, String textAddMessage, String textAddTitle, String textEditMessage, String textEditTitle) { this.textAddMessage = textAddMessage; this.textAddTitle = textAddTitle; this.textEditMessage = textEditMessage; this.textEditTitle = textEditTitle; patternList = new JBList<>(patternModels); patternList.setEmptyText(textEmpty); patternPanel = ToolbarDecorator.createDecorator(patternList) .setAddAction(getAddActionButtonRunnable(patterns)) .setRemoveAction(getRemoveActionButtonRunnable(patterns)) .setEditAction(getEditActionButtonRunnable(patterns)) .disableUpDownActions() .createPanel(); patternPanel.setBorder(IdeBorderFactory.createTitledBorder(textTitle)); }