Icon icon = getCurrentControlIcon(path); int iconW = icon.getIconWidth();
  protected void paintHorizontalPartOfLeg(Graphics g, Rectangle clipBounds,                                          Insets insets, Rectangle bounds,                                          TreePath path, int row,                                          boolean isExpanded,                                          boolean hasBeenExpanded,                                          boolean isLeaf)  {    if (row != 0)      {        Icon icon = getCurrentControlIcon(path);        int iconW = icon.getIconWidth();        paintHorizontalLine(g, tree, bounds.y + bounds.height / 2,                            bounds.x - iconW/2 - gap, bounds.x - gap);      }  }