Subject: bug#17346: 24.4.50; Why is the goal column limited to C-n and C-p ?

From: Dani Moncayo <[email-masked]>
Date: Thu, 9 Oct 2014 18:03:31 +0200

On Thu, Oct 9, 2014 at 5:44 PM, Stefan Monnier <[email-masked]> wrote:
>>> Another issue related to the one reported originally: 'C-l'
>>> (recenter-top-bottom) resets the goal column.
>>> Steps to reproduce, from "emacs -Q":
>>> C-p C-p C-f C-n C-p
>>> Note that the goal column (column 1) is honored by now.  Then do:
>>> C-n C-l C-p
>>> Note that the goal column has been (incorrectly) forgotten after typing 'C-l'.
>
> I think it would be fine to make C-l preserve `temporary-goal-column'.
> Currently, only next-line and previous-line do that, and this is
> hardcoded in `line-move' and `line-move-visual'.
>
> We could change that hardcoded list by replacing it with a symbol
> property `preserve-temporary-goal-column' and then add that property to
> recenter-top-bottom.

Sounds right to me.

Note also that, as I said before in this thread, any command intended
for _vertical_ motion of the cursor (scroll-up-command,
scroll-down-command, scroll-bar-toolkit-scroll, mwheel-scroll, ...)
should try to preserve the goal column (whether semi-permanet or
temporary).

-- 
Dani Moncayo