I created two classes, one extends JButton and the other extends JPanel. In both cases, both overrides the paint method. Basically I'm extending JPanel so I can place an image as the back ground. The issue I'm having is that every time the button is drawn, if it's drawn past 100,100 , it will not show up. Also the area that listening to the mouse is a bit off from where the image is drawn. If I draw components through my class it shows up fine, but it still draws the off set one. What method to I have to override to stop the other one from being drawn.