all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Dani Moncayo <dmoncayo@gmail.com>
Cc: control@debbugs.gnu.org, 15894@debbugs.gnu.org
Subject: bug#15894: 24.3.50; unwarranted horizontal auto-scrolling
Date: Thu, 14 Nov 2013 19:26:37 +0200	[thread overview]
Message-ID: <83k3gazygi.fsf@gnu.org> (raw)
In-Reply-To: <CAH8Pv0hrqd9ot6gCtW_6hAA_fcGbDMk=a1M9vKBnCcwJdks1UQ@mail.gmail.com>

severity 15894 wishlist
thanks

> Date: Thu, 14 Nov 2013 14:59:09 +0100
> From: Dani Moncayo <dmoncayo@gmail.com>
> 
> >From "emacs -Q":
> 1. M-x toggle-truncate-lines
> 2. Visit a file with a single long line (say, about 300 characters)
> 3. Move point to the right until horizontal auto-scrolling take
>    place. (note that now the point is centered horizontally in the
>    window - ok).
> 4. Now move the point a bit to the left, but not too much, so that
>    horizontal auto-scrolling doesn't happen again, and thereby the point
>    ends up in a position closer to the left edge of the window.
> 5. C-x b C-x b (i.e. display another buffer and then display our buffer
>    again).
> 
> I observe that the cursor is re-centered horizontally, which IMO is not
> TRT.  The cursor should be at the same position it was last time I
> displayed the buffer (i.e. where I put it).

This isn't a bug, but a missing feature.  Emacs was never coded to
support what you expect.  The amount of hscroll is recorded in the
window object, so when another buffer is displayed in a window, that
information is thrown away and recomputed from scratch.  IOW, Emacs
does not remember what was the hscroll with which the buffer was last
displayed.

Patches are welcome to add such a feature.





      reply	other threads:[~2013-11-14 17:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-14 13:59 bug#15894: 24.3.50; unwarranted horizontal auto-scrolling Dani Moncayo
2013-11-14 17:26 ` Eli Zaretskii [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83k3gazygi.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=15894@debbugs.gnu.org \
    --cc=control@debbugs.gnu.org \
    --cc=dmoncayo@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.