Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » What happens when user do a left-mouse click on Text Editor
What happens when user do a left-mouse click on Text Editor [message #305031] Wed, 21 June 2006 17:06 Go to next message
Eclipse UserFriend
Originally posted by: milupa_i.hotmail.com

Hi,

Can anyone help me to find out the underlying methods that are called when
user clicks on the Text Editor in the Java Perspective?

How the Editor calculates the line numbers of that method where the caret
position currently is? In the Vertical Ruler bar, the portion appears in
Shade.

Thanks

NI
Re: What happens when user do a left-mouse click on Text Editor [message #305044 is a reply to message #305031] Thu, 22 June 2006 07:19 Go to previous message
Alex Le is currently offline Alex LeFriend
Messages: 649
Registered: July 2009
Senior Member
milupa wrote:

> Hi,
>
> Can anyone help me to find out the underlying methods that are called
> when user clicks on the Text Editor in the Java Perspective?
>
> How the Editor calculates the line numbers of that method where the
> caret position currently is? In the Vertical Ruler bar, the portion
> appears in Shade.
> Thanks
>
> NI
>

Oh, boy...That's a lot of info...I would suggest start playing with the
JFace text framework. What you can do is create a plugin using of the
PDE template to generate an simple XML editor and start stepping into
the code. Read the Eclipse programmer's guide on editors.

To answer your questions at higher level. Use IDocument to calculate
where the current carret is. The vertical ruler is one of the things
JFace text offers. The shading is done by highlighting the text or by
annotations.

Good luck.
Previous Topic:how to get IFolder of this plugin?
Next Topic:WizardNewFileCreationPage on click of TreeNode
Goto Forum:
  


Current Time: Wed Nov 26 02:05:14 GMT 2014

Powered by FUDForum. Page generated in 0.02523 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software