From: Nick Roberts <nickrob@snap.net.nz>
Cc: juri@jurta.org, eliz@gnu.org, emacs-devel@gnu.org
Subject: Re: Overlay arrow in *compilation* and *grep* buffers
Date: Sat, 30 Apr 2005 00:19:43 +1200 [thread overview]
Message-ID: <17010.9823.661722.54130@farnswood.snap.net.nz> (raw)
In-Reply-To: <E1DRSWX-0006mA-8l@fencepost.gnu.org>
> SM> I recently realized that while the 0-context sometimes makes sense
> for SM> C-x `, the "don't move" behavior would be preferable when
> getting SM> to an error by using RET or mouse-2 on the actual error
> text.
>
> That is true *if* we use the overlay arrow. However, as has just been
> pointed out, using the overlay arrow in error message lists is very
> annoying on text consoles. On text consoles, I think it would be
> better to move to the top, even for RET or Mouse-2, than to display
> the overlay arrow.
This patch does what you are suggesting. It doesn't do what Stefan suggested
(not because I don't think it is a good idea, but because I don't know how to
implement it cleanly). It might be better to change the condition for a text
terminal to one that checks for a left-hand fringe, if thats possible.
Nick
*** /home/nick/emacs/lisp/progmodes/compile.el.~1.352.~ 2005-04-24 07:39:26.000000000 +1200
--- /home/nick/emacs/lisp/progmodes/compile.el 2005-04-30 00:15:11.000000000 +1200
***************
*** 1247,1253 ****
(make-local-variable 'compilation-messages-start)
(make-local-variable 'compilation-error-screen-columns)
(make-local-variable 'overlay-arrow-position)
! (set (make-local-variable 'overlay-arrow-string) "=>")
(setq next-error-overlay-arrow-position nil)
(add-hook 'kill-buffer-hook
(lambda () (setq next-error-overlay-arrow-position nil)) nil t)
--- 1247,1253 ----
(make-local-variable 'compilation-messages-start)
(make-local-variable 'compilation-error-screen-columns)
(make-local-variable 'overlay-arrow-position)
! (set (make-local-variable 'overlay-arrow-string) "")
(setq next-error-overlay-arrow-position nil)
(add-hook 'kill-buffer-hook
(lambda () (setq next-error-overlay-arrow-position nil)) nil t)
***************
*** 1576,1593 ****
(defcustom compilation-context-lines 0
"*Display this many lines of leading context before message.
! If nil, don't scroll the compilation output window."
:type '(choice integer (const :tag "No window scrolling" nil))
:group 'compilation
:version "22.1")
(defsubst compilation-set-window (w mk)
"Align the compilation output window W with marker MK near top."
! (if (integerp compilation-context-lines)
! (set-window-start w (save-excursion
! (goto-char mk)
! (beginning-of-line (- 1 compilation-context-lines))
! (point))))
(set-window-point w mk))
(defvar next-error-highlight-timer)
--- 1576,1599 ----
(defcustom compilation-context-lines 0
"*Display this many lines of leading context before message.
! If nil, don't scroll the compilation output window. Text terminals never
! scroll because no overlay arrow is present."
:type '(choice integer (const :tag "No window scrolling" nil))
:group 'compilation
:version "22.1")
(defsubst compilation-set-window (w mk)
"Align the compilation output window W with marker MK near top."
! (if (display-graphic-p)
! (if (integerp compilation-context-lines)
! (set-window-start w (save-excursion
! (goto-char mk)
! (beginning-of-line (- 1 compilation-context-lines))
! (point))))
! (set-window-start w (save-excursion
! (goto-char mk)
! (beginning-of-line 1)
! (point))))
(set-window-point w mk))
(defvar next-error-highlight-timer)
prev parent reply other threads:[~2005-04-29 12:19 UTC|newest]
Thread overview: 49+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-04-24 10:45 Overlay arrow in *compilation* and *grep* buffers Eli Zaretskii
2005-04-24 18:42 ` Kim F. Storm
2005-04-24 20:04 ` Eli Zaretskii
2005-04-27 13:10 ` Kim F. Storm
2005-04-27 14:39 ` Eli Zaretskii
2005-04-28 11:01 ` Richard Stallman
2005-04-28 19:51 ` Eli Zaretskii
2005-04-28 20:54 ` Nick Roberts
2005-04-29 7:08 ` Eli Zaretskii
2005-04-29 8:52 ` Nick Roberts
2005-05-09 20:55 ` Juri Linkov
2005-05-10 6:40 ` David Kastrup
2005-05-12 11:38 ` Nick Roberts
2005-05-13 1:34 ` Richard Stallman
2005-05-13 5:03 ` Juri Linkov
2005-05-13 6:08 ` Eli Zaretskii
2005-05-13 7:18 ` Nick Roberts
2005-05-13 13:28 ` Eli Zaretskii
2005-05-14 0:26 ` Richard Stallman
2005-05-14 7:17 ` Eli Zaretskii
2005-05-14 22:20 ` Kim F. Storm
2005-05-15 15:58 ` Richard Stallman
2005-05-13 13:02 ` Nick Roberts
2005-05-14 0:25 ` Richard Stallman
2005-05-15 2:44 ` Nick Roberts
2005-05-15 4:12 ` Eli Zaretskii
2005-05-15 4:21 ` Eli Zaretskii
2005-05-15 22:39 ` Richard Stallman
2005-05-16 1:20 ` Nick Roberts
2005-05-16 19:28 ` Richard Stallman
2005-05-16 19:28 ` Richard Stallman
2005-05-16 22:16 ` Nick Roberts
2005-05-17 13:23 ` Richard Stallman
2005-04-29 10:49 ` Nick Roberts
2005-05-07 16:20 ` Eli Zaretskii
2005-05-07 21:10 ` Kim F. Storm
2005-05-08 0:41 ` Nick Roberts
2005-05-08 4:21 ` Eli Zaretskii
2005-05-08 5:49 ` Nick Roberts
2005-05-08 16:12 ` Richard Stallman
2005-05-08 19:37 ` Eli Zaretskii
2005-04-25 16:05 ` Richard Stallman
2005-04-25 16:46 ` Eli Zaretskii
2005-04-26 14:33 ` Richard Stallman
2005-04-28 11:34 ` Nick Roberts
2005-04-28 19:50 ` Eli Zaretskii
2005-04-28 21:16 ` Nick Roberts
2005-04-29 10:15 ` Richard Stallman
2005-04-29 12:19 ` Nick Roberts [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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=17010.9823.661722.54130@farnswood.snap.net.nz \
--to=nickrob@snap.net.nz \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=juri@jurta.org \
/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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).