Newbie Request
Submitted by Monday, 19 January, 2004 - 20:43
on
Hi,
I'm a newbie jEdit plug-in developer and have a quick request for help/pointers for a particular effect that I'm trying to achieve. I've been designing/developing an open hypermedia system, Chimera, since 1992 and over the years Chimera has been integrated with a number of text editors including vi, emacs, MS Word, etc. and now, hopefully, jEdit! The main difficulty in integrating a text editor is figuring out how to "create anchors" that is, understanding how to ask the editor to display a piece of text in a format that indicates that an anchor/link exists within the document (using the ubiquitous format of blue, underlined text).
So, what I'm working on is a plug-in that adds a menu item to jEdit: Plugins -> Chimera -> Create Anchor
The idea is that I'll open a jEdit document, select some text, select this menu item, and the text will become formatted in blue and underlined. (The anchor will be "stored" in Chimera, I just need jEdit to do the visual formatting for me.)
So, is this possible? Is there an easy way to tell jEdit: in buffer 1, line 10, from characters 10 to 14, please format the text like this. ??
Will I have to create a subclass of "org.gjt.sp.jedit.textarea.TextAreaPainter" or is there an easier way to do this?
Any help would be appreciated! Both, here, in the forum, and/or at "kena at cs.colorado.edu".
Thanks in advance!
Ken Anderson
Assistant Professor
Dept. of Computer Science
University of Colorado, Boulder
I'm a newbie jEdit plug-in developer and have a quick request for help/pointers for a particular effect that I'm trying to achieve. I've been designing/developing an open hypermedia system, Chimera, since 1992 and over the years Chimera has been integrated with a number of text editors including vi, emacs, MS Word, etc. and now, hopefully, jEdit! The main difficulty in integrating a text editor is figuring out how to "create anchors" that is, understanding how to ask the editor to display a piece of text in a format that indicates that an anchor/link exists within the document (using the ubiquitous format of blue, underlined text).
So, what I'm working on is a plug-in that adds a menu item to jEdit: Plugins -> Chimera -> Create Anchor
The idea is that I'll open a jEdit document, select some text, select this menu item, and the text will become formatted in blue and underlined. (The anchor will be "stored" in Chimera, I just need jEdit to do the visual formatting for me.)
So, is this possible? Is there an easy way to tell jEdit: in buffer 1, line 10, from characters 10 to 14, please format the text like this. ??
Will I have to create a subclass of "org.gjt.sp.jedit.textarea.TextAreaPainter" or is there an easier way to do this?
Any help would be appreciated! Both, here, in the forum, and/or at "kena at cs.colorado.edu".
Thanks in advance!
Ken Anderson
Assistant Professor
Dept. of Computer Science
University of Colorado, Boulder