This week's book giveaway is in the OCAJP forum.
We're giving away four copies of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) and have Khalid A Mughal & Rolf W Rasmussen on-line!
See this thread for details.
Win a copy of Programmer's Guide to Java SE 8 Oracle Certified Associate (OCA) this week in the OCAJP forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

custom tags using an HTMLEditorKit subclass

 
Scott Presley
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've created a subclass of HTMLEditorKit called CustomEditorKit(see code below) At the point in the code marked with the 'UGH' comment, I want to check to see if the unknown element is of type <expression>x+4</expression> and create return a Custom View object containing the 'x+4' inside the tags... I figured out how to check to see that the element is indeed 'expression', but it's unclear from reading online and reading through javadoc how to extract the 'x+4'.

Thanks in advance for any help,
Scott


[ July 13, 2004: Message edited by: Scott Presley ]
 
Stanislav Lapitsky
Ranch Hand
Posts: 53
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have an example of the feature.

See
http://java-sl.com/custom_tag_html_kit.html

It's implemented to support <button> tag but can be easy extended.

Regards,
Stas
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic