
I need to know the line number where the user clicks the mouse. If the whole content can be visible, it works fine. But if it is larger (so there is a vertical Scrollbar) the line number is wrong.
Say I have 90 lines. I scroll to the bottom of the document. I see last lines. For example lines 81 to 90. If I click third visible line, I expect the information to be 83. What I get is:
SyntaxEditor.ActiveView.CurrentSnapshot.Lines => returns 90
SyntaxEditor.ActiveView.CurrentSnapshotLine.Index +1 => returns 3 (Index start in 0, so I know I have to add 1).
SyntaxEditor.ActiveView.CurrentSnapshotLine.Text => returns the content of line 3 (not of line 83 which is where user clicked).
All properties descendant from the ActiveView related to the line indicate that I am in line 3 instead of 83.
I do not mind doing some computation: if I can know that above the screen there are 80 lines and the user clicked the third visible line, it would be fine. I can add that 80 previous lines + 3 to know the user is in line 83.