JComponent () { List<Pair<String,SettingsEditor<T>>> editors = myGroup.getEditors(); if (editors.size() == 0) return new JPanel(); if (editors.size() == 1) return editors.get(0).getSecond().getComponent(); JTabbedPane tabs = new JBTabbedPane(); for (int i = 0; i < editors.size(); i++) { Pair<@TabTitle String, SettingsEditor<T>> pair = editors.get(i); tabs.add(pair.getFirst(), pair.getSecond().getComponent()); } tabs.putClientProperty("JTabbedPane.hasFullBorder", Boolean.TRUE); return tabs; }