ok i have my swing window...but now i'd like to draw shapes on it, like i've done in applets. i've been trying some different combinations of stuff, but they dont' seem to work, is it a different process with a window?
thanks guysCode:import java.awt.*; import java.awt.event.*; import javax.swing.*; public class window { public static void main(String [] args) { JFrame frame = new JFrame("Ants"); Dimension WindowSize = new Dimension(200, 200); frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); frame.pack(); frame.setSize(400,400); frame.setVisible(true); } }![]()




Reply With Quote