void (final boolean isRow, final Graphics2D g2d, final Rectangle rc) { g2d.setColor(Color.BLACK); if (!isRow) { int maxX = (int) rc.getMaxX(); int midY = (int) rc.getCenterY()+3; final int xStart = Math.max(maxX - 10, rc.x + 2); final int xEnd = maxX - 2; g2d.drawLine(xStart, midY, xEnd, midY); g2d.drawLine(xStart, midY, xStart+2, midY-2); g2d.drawLine(xStart, midY, xStart+2, midY+2); g2d.drawLine(xEnd, midY, xEnd-2, midY-2); g2d.drawLine(xEnd, midY, xEnd-2, midY+2); } else { int maxY = (int) rc.getMaxY(); int midX = (int) rc.getCenterX()+3; final int yStart = Math.max(maxY - 10, rc.y + 2); final int yEnd = maxY - 2; g2d.drawLine(midX, yStart, midX, yEnd); g2d.drawLine(midX, yStart, midX-2, yStart+2); g2d.drawLine(midX, yStart, midX+2, yStart+2); g2d.drawLine(midX, yEnd, midX-2, yEnd-2); g2d.drawLine(midX, yEnd, midX+2, yEnd-2); } }