I have an JEditorPane where in some HTML documents are loaded. I want to add word search facility to this pane like the one which is with Mozilla Firefox. In Firefox, if I press CTRL+F, I (we) get a textbox, to type the word to be searched. Along with this textbox, there are another set of options like Next, Previous, Highlight all and Match case.
I want to have an Hightlight all option along with Match case with the JEditorPane with some background color for the complete word and for all the occurrences of that particular word.
Any guidance?
These would help:
http://download.oracle.com/javase/tutorial/uiswing/components/generaltext.html
http://download.oracle.com/javase/tutorial/uiswing/misc/keybinding.html
Highlight example : http://www.java2s.com/Code/Java/Swing-JFC/JTextPaneHighlightExample.htm