I need help with drawing lines on a JTable. After making my table this is what i did
Graphics g = table.getGraphics();
g.setColor(Color.red);
g2.draw(new Line2D.Double(x1, y1, x2, y2));
where table is a JTable.
This draws a line with red color where i want it to but then that line disappears in like a second. Can someone help me?