import java.awt.*;
import javax.swing.*;
public class JavaExamplePlafComponenetInJApplet extends JApplet
{
public void init()
{
Container Cntnr = getContentPane();
JNewLabel JLbl = new JNewLabel("This Is Duplicate Label");
Cntnr.setLayout(new FlowLayout());
Cntnr.add(new JLabel("This is Real Lable"));
Cntnr.add(JLbl);
}
}
class JNewLabel extends JTextField
{
public JNewLabel(String s1)
{
super(s1);
}
public void updateUI()
{
super.updateUI();
setHighlighter(null);
setEditable(false);
LookAndFeel.installBorder(this,"Label.border");
LookAndFeel.installColorsAndFont(this,"Label.background","Label.foreground", "Label.font");
}
}
/*<APPLET CODE=JavaExamplePlafComponenetInJApplet.class WIDTH=210 HEIGHT=200 ></APPLET>*/
Dinesh Thakur holds an B.SC (Computer Science), MCSE, MCDBA, CCNA, CCNP, A+, SCJP certifications. Dinesh authors the hugely popular Computer Notes blog. Where he writes how-to guides around Computer fundamental , computer software, Computer programming, and web apps. For any type of query or something that you think is missing, please feel free to Contact us.
Related Articles
Basic Courses
Advance Courses