Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Line Numbers and JEditorPane  RSS feed

 
M.K.A. Monster
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello everyone,
I'm programming a javabased texteditor. And I like to show line-numbers in front of every row. Does there be an extension of JEditorPane, or has anyone build it. That can display linenumbers? I've tried to do this by putting the JEditorPane with a JPanel (showing the linenumbers) in a JScrollPane, the trouble is that the scrolling now is very slow.
I really need some help here. I hope anyone has build an extension of JEditorPane that can display LineNumbers, and off-course wants to share it.
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"M.K.A. Monster" -

Welcome to the JavaRanch! Please adjust your displayed name to meet the
JavaRanch Naming Policy.
You can change it here.

Thanks! and welcome to the JavaRanch!
 
M.K.A. Monster
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Nathan Pruett:
"M.K.A. Monster" -

Welcome to the JavaRanch! Please adjust your displayed name to meet the
JavaRanch Naming Policy.
You can change it here.

Thanks! and welcome to the JavaRanch!

I've had problems with my a few months ago, on this forum. The problem is my real surname is 'Monster', You can find it on my website (it's in Dutch) www.monster-internet.nl . I hope my name won't cause any more problems.
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oops! Sorry about that...

Take a look at JEdit... it's an open source text editor/IDE written in Java... I know that they have a line numbered text area implementation... it might take a little digging, and it's probably not just a self-contained component, but hopefully it will help.
 
M.K.A. Monster
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Nathan Pruett:
Oops! Sorry about that...

Take a look at JEdit... it's an open source text editor/IDE written in Java... I know that they have a line numbered text area implementation... it might take a little digging, and it's probably not just a self-contained component, but hopefully it will help.


I've been there, but that's not really what I seek.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!