import javax.swing.*; import java.awt.Graphics; import java.awt.Graphics2D; import java.awt.geom.GeneralPath; import java.awt.BorderLayout; import java.awt.RenderingHints; class Test { public static void main(final String[] args) { JPanel panel = new JPanel() { public void paintComponent(Graphics g) { Graphics2D g2 = (Graphics2D)g; GeneralPath path = new GeneralPath(); g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); path.moveTo(480, 200); path.quadTo(480, 220, 470, 224); path.lineTo(230, 224); path.quadTo(225, 224, 217, 216.1f); path.lineTo(140, 130); g2.draw(path); } }; panel.setOpaque(false); panel.setSize(500, 500); JFrame test = new JFrame("Test"); test.getContentPane().add(panel, BorderLayout.CENTER); test.pack(); test.setSize(500,500); test.show(); } }