void (JTree tree, Object value, boolean selected, boolean expanded, boolean leaf, int row, boolean hasFocus) { if (!(value instanceof CheckedTreeNode node)) return; if (!(node.getUserObject() instanceof Pair pair)) return; ColoredTreeCellRenderer renderer = getTextRenderer(); renderer.setIcon(myExternalSystemUiAware.getProjectIcon()); String projectName = (String)pair.first; renderer.append(projectName, SimpleTextAttributes.REGULAR_ATTRIBUTES); String projectPath = StringUtil.trimMiddle((String)pair.second, MAX_PATH_LENGTH); renderer.append(" (" + projectPath + ")", SimpleTextAttributes.GRAY_ATTRIBUTES); setToolTipText((String)pair.second); }