@Override
  public void paintBorder(Component c, Graphics g, int x, int y, int width, int height) {
    if (((JComponent)c).getClientProperty("JTextField.Search.noBorderRing") == Boolean.TRUE) return;

    Rectangle r = new Rectangle(x, y, width, height);

    if (TextFieldWithPopupHandlerUI.isSearchField(c)) {
      paintSearchArea((Graphics2D)g, r, (JTextComponent)c, false);
    }
    else if (isTableCellEditor(c)) {
      paintCellEditorBorder((Graphics2D)g, c, r, isFocused(c));
    }
    else if (!(c.getParent() instanceof JComboBox)) {
      paintNormalBorder((Graphics2D)g, (JComponent)c, r);
    }
  }
@Override
  public void paintBorder(Component c, Graphics g, int x, int y, int width, int height)