| CustomTags.java |

    1 import com.toedter.calendar.*;
    2 import org.swixml.SwingEngine;
    3 import org.swixml.ConverterLibrary;
    4 import org.jvnet.substance.SubstanceLookAndFeel;
    5 import org.jvnet.substance.theme.SubstanceEbonyTheme;
    6
    7 import javax.swing.*;
    8 import java.awt.event.WindowAdapter;
    9 import java.awt.event.WindowEvent;
    10
    11public class CustomTags extends WindowAdapter {
    12
    13
    14  public CustomTags() throws Exception {
    15    SwingEngine swix = new SwingEngine(this);
    16    swix.getTaglib().registerTag("Calendar", JCalendar.class);
    17    swix.render("xml/customtags.xml").setVisible(true);
    18  }
    19
    20  /**
    21   * Invoked when a window is in the process of being closed.
    22   * The close operation can be overridden at this point.
    23   */
    24  public void windowClosing(WindowEvent e) {
    25    super.windowClosing(e);
    26    System.exit(0);
    27  }
    28
    29  //
    30  //  Make the class bootable
    31  //
    32  public static void main(String[] args) throws Exception {
    33    new CustomTags();
    34  }
    35}
    36

| CustomTags.java |