void () { myComboBox = new SchemesCombo<>() { @Override protected boolean supportsProjectSchemes() { return mySchemesPanel.supportsProjectSchemes(); } @Override protected boolean isProjectScheme(@NotNull T scheme) { return mySchemesPanel.getModel().isProjectScheme(scheme); } @Override protected int getIndent(@NotNull T scheme) { return mySchemesPanel.getIndent(scheme); } @Override protected @NotNull SimpleTextAttributes getSchemeAttributes(T scheme) { SchemesModel<T> model = mySchemesPanel.getModel(); SimpleTextAttributes baseAttributes = !useBoldForNonRemovableSchemes() || model.canDeleteScheme(scheme) ? SimpleTextAttributes.REGULAR_ATTRIBUTES : SimpleTextAttributes.REGULAR_BOLD_ATTRIBUTES; if (mySchemesPanel.highlightNonDefaultSchemes() && model.canResetScheme(scheme) && model.differsFromDefault(scheme)) { return baseAttributes.derive(-1, MODIFIED_ITEM_FOREGROUND, null, null); } return baseAttributes; } }; myComboBox.addActionListener(new ActionListener() { @Override public void actionPerformed(ActionEvent e) { mySchemesPanel.getActions().onSchemeChanged(getSelectedScheme()); } }); }