1 19 20 package org.netbeans.modules.form; 21 import java.awt.BorderLayout ; 22 import java.awt.Color ; 23 import java.util.ResourceBundle ; 24 import javax.swing.BorderFactory ; 25 import javax.swing.JLabel ; 26 import javax.swing.JPanel ; 27 28 35 public class InvalidComponent extends JPanel { 36 37 private JLabel label = new JLabel (); 38 39 public InvalidComponent() { 40 this.setBorder(BorderFactory.createLineBorder(Color.RED)); 41 this.setLayout(new BorderLayout ()); 42 43 label.setForeground(Color.RED); 44 ResourceBundle bundle = FormUtils.getBundle(); 45 label.setText("<html><center>" + bundle.getString("CTL_LB_InvalidComponent") + "</center></html>"); add(label); 47 48 } 49 50 } 51 | Popular Tags |