public void setChosen(@NotNull TextAttributesKey key) {
    if (ATTRIBUTES_CUSTOM_NAMES.containsKey(key)) {
      getTemplatePresentation().setText(ATTRIBUTES_CUSTOM_NAMES.get(key));
      return;
    }

    final var attributes = ColorSettingsUtil.getErrorTextAttributes();
    String displayName = key.getExternalName();
    for (Pair<TextAttributesKey, @Nls String> pair: attributes) {
      if (key.toString().equals(pair.first.toString())) {
        displayName = pair.second;
        break;
      }
    }
    final String name = stripColorOptionCategory(displayName);
    getTemplatePresentation().setText(name);
  }
public void setChosen(@NotNull TextAttributesKey key)