Now we have a hell of a problem, because the change was introduced in the IDE, and we will have to wait many months for the next stable version of Lazarus. Navigation in the code editor has been broken and we will have to deal with this for a long time...
Currently, the only solution that allows consistent operation and to choose the jump target (declaration or implementation) is to use this new option and IDE macros. You should check the
Jump directly to method body option so that
Alt+Up always takes you to the implementation, and then record an IDE macro containing two items —
Find declaration (i.e. jump to the implementation) and then
Find Procedure Definition (jump from body to declaration). Then set the
Alt+Down shortcut for this macro.
The macro should have the following content (see attachment):
begin
ecFindDeclaration;
ecFindProcedureDefinition;
end.
From now on, pressing the
Alt+Down shortcut will execute a macro, first simulating pressing
Alt+Up and then
Shift+Ctrl+Up. If you jump to a routine declaration, the macro will do it for you, but if you use it on the identifier of a constant, variable, data type, etc. (something that does not have implementation), the macro will also jump correctly to the declaration of that identifier (the second macro shortcut will do nothing).
The only problem is that you have to get used to the fact that
Alt+Up jumps to the routine definition and the fact that using the macro adds two items to the
Jump history, so to return to the previous place after jumping, you need to go back twice (press
Alt+Left twice).