I use the instructions to add my own tag http://java-sl.com/custom_tag_html_kit.html
class MyParserDelegator extends ParserDelegator {
public MyParserDelegator()
It works for me using the following (jdk 1.7):
Field f = javax.swing.text.html.parser.ParserDelegator.class.getDeclaredField("DTD_KEY");
The only change is the key: "DTD_KEY"
upper case!!
I found the key "DTD_KEY" using
Field[] flds = javax.swing.text.html.parser.ParserDelegator.class.getDeclaredFields();
for (Field f: flds)
{
System.err.println(f.getName());
}