look at this approach for drawing forms. first of all you need a frame that holds the canvas for your paintings. here is the code of the DrawableFrame.java


public class DrawableFrame extends...