[Lazarus] Updating Cursor position on Ctrl+Click code navigation

Martin Frb lazarus at mfriebe.de
Fri Apr 17 17:02:04 CEST 2015


On 17/04/2015 14:48, Graeme Geldenhuys wrote:
> Hi,
>
> Is there a way to tell Lazarus to move the current cursor to the
> location where I did a Ctrl+Click, then navigate to the new code?
Yes there is (now)

In Mouse options advanced, select "text" in the tree-view, then double 
click "Source Link" in the grid. A Window opens, and you can select 
"Move Caret"

But it actually goes wrong. Because the jump is executed first. So it 
takes you back after the jump.
You can see it works, if you jump to another unit, and then use the 
mouse to go to the previous tab.

I fixed that in trunk (just now), so if you update this will work for 
you. But there will be no jump point to go back to the original pos. 
(the one a few 100's of lines away)


> Use case:
> I'm navigating huge amounts of code and I find that I scroll in the code
> (cursor position doesn't change), then see what I want, Ctrl+Click it. I
> then review the new code, and press Ctrl+H to go back to my previous
> position. Lazarus now jumps back to last cursor position, not the
> position I navigated from. So now I need to scroll again (sometimes
> 100's of lines of code) to find my place.
>
>
> Regards,
>    - Graeme -
>





More information about the Lazarus mailing list