//HelloFancy2.java //Andy Harris, 4/00 //improved 'Hello' applet with custom font import java.awt.*; import java.applet.*; public class HelloFancy2 extends Applet{ public void init(){ //Create a label object called lblGreeting Label lblGreeting = new Label("Hello, world!!!", Label.CENTER); //Create a new Font called fntMine Font fntMine = new Font("SansSerif", Font.BOLD+Font.ITALIC, 20); //Apply the font to the label lblGreeting.setFont(fntMine); //add the label to the applet so we can see it add(lblGreeting); } // end init } // end applet