Using Character Array
Full code
Full code
package javacourse; import java.applet.Applet; import java.awt.Color; import java.awt.Graphics; /** * * @author Backtrace */ public class TestApplet extends Applet{ char[] c={'d','r','a','w'}; public void init() { setBackground(Color.red); } public void paint (Graphics g) { g.drawChars(c,0, c.length, 50, 100); } }
0 Comments:
Post a Comment