Mercurial > emacs
comparison lisp/progmodes/compile.el @ 16519:b96e56680038
(compile-auto-highlight): Renamed from
compile-highlight-display-limit.
author | Richard M. Stallman <rms@gnu.org> |
---|---|
date | Tue, 05 Nov 1996 18:42:30 +0000 |
parents | 851101d4ba84 |
children | 3244576af168 |
comparison
equal
deleted
inserted
replaced
16518:851101d4ba84 | 16519:b96e56680038 |
---|---|
36 | 36 |
37 ;;;###autoload | 37 ;;;###autoload |
38 (defvar compilation-window-height nil | 38 (defvar compilation-window-height nil |
39 "*Number of lines in a compilation window. If nil, use Emacs default.") | 39 "*Number of lines in a compilation window. If nil, use Emacs default.") |
40 | 40 |
41 (defvar compile-highlight-display-limit nil | 41 (defvar compile-auto-highlight nil |
42 "*Specify how many compiler errors to highlight (and parse) initially. | 42 "*Specify how many compiler errors to highlight (and parse) initially. |
43 \(Highlighting applies to ean error message when the mouse is over it.) | |
43 If this is a number N, all compiler error messages in the first N lines | 44 If this is a number N, all compiler error messages in the first N lines |
44 are highlighted and parsed as soon as they arrive in Emacs. | 45 are highlighted and parsed as soon as they arrive in Emacs. |
45 If t, highlight and parse the whole compilation buffer as soon as possible. | 46 If t, highlight and parse the whole compilation output as soon as it arrives. |
46 If nil, don't highlight or parse any of the buffer until you try to | 47 If nil, don't highlight or parse any of the buffer until you try to |
47 move to the error messages. | 48 move to the error messages. |
48 | 49 |
49 Those which are not parsed and highlighted initially | 50 Those messages which are not parsed and highlighted initially |
50 will be parsed and highlighted as soon as you try to move to them.") | 51 will be parsed and highlighted as soon as you try to move to them.") |
51 | 52 |
52 (defvar compilation-error-list nil | 53 (defvar compilation-error-list nil |
53 "List of error message descriptors for visiting erring functions. | 54 "List of error message descriptors for visiting erring functions. |
54 Each error descriptor is a cons (or nil). Its car is a marker pointing to | 55 Each error descriptor is a cons (or nil). Its car is a marker pointing to |
627 (setq mode-line-process (format ":%s [%s]" process-status (cdr status))) | 628 (setq mode-line-process (format ":%s [%s]" process-status (cdr status))) |
628 ;; Force mode line redisplay soon. | 629 ;; Force mode line redisplay soon. |
629 (force-mode-line-update) | 630 (force-mode-line-update) |
630 (if (and opoint (< opoint omax)) | 631 (if (and opoint (< opoint omax)) |
631 (goto-char opoint)) | 632 (goto-char opoint)) |
632 ;; Automatically parse (and highlight) error messages: | 633 ;; Automatically parse (and mouse-highlight) error messages: |
633 (cond ((eq compile-highlight-display-limit t) | 634 (cond ((eq compile-auto-highlight t) |
634 (compile-reinitialize-errors nil (point-max))) | 635 (compile-reinitialize-errors nil (point-max))) |
635 ((numberp compile-highlight-display-limit) | 636 ((numberp compile-auto-highlight) |
636 (compile-reinitialize-errors nil (save-excursion | 637 (compile-reinitialize-errors nil |
637 (goto-line | 638 (save-excursion |
638 compile-highlight-display-limit) | 639 (goto-line compile-auto-highlight) |
639 (point))))) | 640 (point))))) |
640 (if compilation-finish-function | 641 (if compilation-finish-function |
641 (funcall compilation-finish-function (current-buffer) msg)) | 642 (funcall compilation-finish-function (current-buffer) msg)) |
642 (let ((functions compilation-finish-functions)) | 643 (let ((functions compilation-finish-functions)) |
643 (while functions | 644 (while functions |
644 (funcall (car functions) (current-buffer) msg) | 645 (funcall (car functions) (current-buffer) msg) |
864 (nconc compilation-old-error-list compilation-error-list)) | 865 (nconc compilation-old-error-list compilation-error-list)) |
865 (if error-list-pos | 866 (if error-list-pos |
866 ;; We started in the middle of an existing list of parsed | 867 ;; We started in the middle of an existing list of parsed |
867 ;; errors before parsing more; restore that position. | 868 ;; errors before parsing more; restore that position. |
868 (setq compilation-error-list error-list-pos)) | 869 (setq compilation-error-list error-list-pos)) |
869 ;; Highlight (the first line of) each error message when the | 870 ;; Mouse-Highlight (the first line of) each error message when the |
870 ;; mouse pointer moves over it: | 871 ;; mouse pointer moves over it: |
871 (let ((inhibit-read-only t) | 872 (let ((inhibit-read-only t) |
872 (error-list compilation-error-list)) | 873 (error-list compilation-error-list)) |
873 (while error-list | 874 (while error-list |
874 (save-excursion | 875 (save-excursion |