hello I\'m new in java programming, and i need someone explaining me these lines of code:
public class drawpanel extends JPanel
{
public void paintCom
paintComponent() is a method originally defined in abstract class JComponent. Components that extend JComponent directly indirectly (if exposed) have the option to override paintComponent(). the call to super.paintComponent(g) calls the super class's implementation of paintComponent() (in your case it's JPanel's). You would want to override paintComponent() if you want to do other stuff with Graphics g besides what JPanel already does.