• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to change cursor height based on Font size  RSS feed

Ranch Hand
Posts: 205
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello friends, sir, madam

I am using JTextPane and in that textpane I have certain paragraphs. If I select certain words on a line and change the font then the cursor height automatically increases. Now I press the right arrow key to move the cursor towards right. When the cursor is on a font of smaller size then the height of the cursor should also decrease accordingly. But this is not happening. The height of cursor remains the same which it got for the bigger font I had set. So my problem is how to change the height of cursor when it is traversing on text having different font.

Please can anyone help me in this regards

Waiting for your replies.

Thanks and Regards
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!