I have a JTextPane
which has the content type text/plain. I set some texts to that JTextPane
and it contain some texts which display <
You could try this:
pane.setCursor(new Cursor(Cursor.HAND_CURSOR));
Where pane
is your JTextPane
.
Did you read my answer in your posting on Adding tooltips to JTextPane?
Well the concept is the same. You use a MouseListener and convert the mouse point to get the text at the caret position. When you are over a url text then you change the cursor.
The Utilities class might help you access the text at the caret location.
If you need more help then post your SSCCE that shows what you have tried and shows what problems you are having.