emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Preserving sanity in Emacs [Re: rampant region highlighting]


From: Lennart Borgman (gmail)
Subject: Re: Preserving sanity in Emacs [Re: rampant region highlighting]
Date: Tue, 08 Apr 2008 12:20:29 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071031 Thunderbird/2.0.0.9 Mnenhy/0.7.5.666

Alan Mackenzie wrote:
Morning, Lennart!

Morning, Alan!

On Mon, Apr 07, 2008 at 11:37:09PM +0200, Lennart Borgman (gmail) wrote:
Alan Mackenzie wrote:
I acknowledge that having the point always on-screen has benefits too
(though e.g. a fringe indicator could "point towards the offscreen
point" to address some concerns there...), but what if I'm just
scrolling up to look at something?  Martin's hack ensured that I can
scroll away to have a look, and the point will reliably be where I left
it when I scrolled back.

The functions you're talking about are fulfilled in Emacs by the mark,
not the point.  I frequently scoll a bit to look at things.  Then I
scroll back to get where I was, unless I want to stay where I've got to.

The point is, by your mechanism, having scrolled away from point (leaving
point off the screen), how do you then indicate where on the screen you
want point to be set to, and how do you set point there?  The general
Emacs answer is that you indicate a position by setting point.  Hmm.
We're going round in circles.  (You're presumably going to say "you click
the mouse to set point."  This violates the Emacs principle that
everything must be doable without a mouse.)

Another way to look at this would perhaps be to:

- Regard the buffer in a kind of read-only state when the window-point is outside the window ;-)

Hmm.

- If a command concerns the current buffer and it is not a scroll command then just bring back window-point to where it was inside the window before scrolling.

Sorry, I can't parse that.  What is "window-point"?  Does "where it was"
refer to the buffer position, or the position on the screen relative to
the top of the window?

window-point? Just a little joke. We are talking about the buffer point in the current window. The function window-point returns that. window-point may in the situation pictured above still return the point, but it is outside the window ... (or maybe it could return nil?)

"where it was": I meant the position on the screen.

Don't do more (ie do not execute the command), just tell that point was
outside of the window therefore have been brought back.

Don't execute the command?  Yikes!!  Yet one more frivolous item of state
to clog up one's brain.

Yes, I think that must be the price if you always want to be able to see what you are doing. (This could be made an option - perhaps.)

And a few million "..., except when ...."s to
clog up commands' doc strings.

Not much to add there I think. A note somewhere about scrolling is all I can see is really needed.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]