@Override
      public void customizeRenderer(JTree tree, Object value, boolean selected, boolean expanded, boolean leaf, int row, boolean hasFocus) {
        if (!(value instanceof VirtualFileCheckedTreeNode node)) return;
        VirtualFile file = node.getFile();
        @NlsSafe String text;
        SimpleTextAttributes attributes;
        boolean isValid = true;
        if (leaf) {
          VirtualFile ancestor = ((VirtualFileCheckedTreeNode)node.getParent()).getFile();
          if (ancestor != null) {
            text = VfsUtilCore.getRelativePath(file, ancestor, File.separatorChar);
            if (StringUtil.isEmpty(text)) {
              text = File.separator;
            }
          }
          else {
            text = file.getPresentableUrl();
          }
          if (text == null) {
            isValid = false;
            text = file.getPresentableUrl();
          }
          attributes = SimpleTextAttributes.REGULAR_ATTRIBUTES;
        }
        else {
          text = file.getPresentableUrl();
          attributes = SimpleTextAttributes.REGULAR_BOLD_ATTRIBUTES;
        }
        ColoredTreeCellRenderer textRenderer = getTextRenderer();
        textRenderer.setIcon(PlatformIcons.FOLDER_ICON);
        if (!isValid) {
          textRenderer.append(ProjectBundle.message("invalid.root.label") + ' ', SimpleTextAttributes.ERROR_ATTRIBUTES);
        }
        textRenderer.append(text, attributes);
      }
@Override
      public void customizeRenderer(JTree tree, Object value, boolean selected, boolean expanded, boolean leaf, int row, boolean hasFocus)