1 53 package org.swixml; 54 55 import javax.swing.*; 56 import javax.swing.table.JTableHeader ; 57 import java.awt.*; 58 59 70 public final class SwingTagLibrary extends TagLibrary { 71 72 private static SwingTagLibrary INSTANCE = new SwingTagLibrary();; 73 public static SwingTagLibrary getInstance() { 74 return SwingTagLibrary.INSTANCE; 75 } 76 77 80 private SwingTagLibrary() { 81 registerTags(); 82 } 83 84 89 protected void registerTags() { 90 registerTag( "Applet", JApplet.class ); 91 registerTag( "Button", JButton.class ); 92 registerTag( "ButtonGroup", ButtonGroup.class ); 93 registerTag( "HBox", XHBox.class ); 94 registerTag( "VBox", XVBox.class ); 95 registerTag( "Checkbox", JCheckBox.class ); 96 registerTag( "CheckBoxMenuItem", JCheckBoxMenuItem.class ); 97 registerTag( "ComboBox", JComboBox.class ); 98 registerTag( "Component", JComponent.class ); 99 registerTag( "DesktopPane", JDesktopPane.class ); 100 registerTag( "Dialog", XDialog.class ); 101 registerTag( "EditorPane", JEditorPane.class ); 102 registerTag( "FormattedTextField", JFormattedTextField.class ); 103 registerTag( "Frame",JFrame.class); 104 registerTag( "Glue", XGlue.class ); 105 registerTag( "GridBagConstraints", XGridBagConstraints.class ); 106 registerTag( "InternalFrame", JInternalFrame.class ); 107 registerTag( "Label", JLabel.class ); 108 registerTag( "List", JList.class ); 109 registerTag( "Menu", JMenu.class ); 110 registerTag( "Menubar", JMenuBar.class ); 111 registerTag( "Menuitem", JMenuItem.class ); 112 registerTag( "Panel", JPanel.class ); 113 registerTag( "PasswordField", JPasswordField.class ); 114 registerTag( "PopupMenu", JPopupMenu.class ); 115 registerTag( "ProgressBar", JProgressBar.class ); 116 registerTag( "RadioButton", JRadioButton.class ); 117 registerTag( "RadioButtonMenuItem", JRadioButtonMenuItem.class ); 118 registerTag( "OptionPane", JOptionPane.class ); 119 registerTag( "ScrollPane", JScrollPane.class ); 120 registerTag( "Separator", JSeparator.class ); 121 registerTag( "Slider", JSlider.class ); 122 registerTag( "Spinner", JSpinner.class ); 123 registerTag( "SplitPane", XSplitPane.class ); 124 registerTag( "TabbedPane", XTabbedPane.class ); 125 registerTag( "Table", JTable.class ); 126 registerTag( "TableHeader", JTableHeader .class ); 127 registerTag( "TextArea", JTextArea.class ); 128 registerTag( "TextField", JTextField.class ); 129 registerTag( "TextPane", JTextPane.class ); 130 registerTag( "ToggleButton", JToggleButton.class ); 131 registerTag( "Tree", JTree.class ); 132 registerTag( "Toolbar", JToolBar.class ); 133 134 } 135 } 136 137 | Popular Tags |