emacs-devel
[Top][All Lists]
Advanced

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

Re: ^M in compilation buffers


From: Sam Steingold
Subject: Re: ^M in compilation buffers
Date: Tue, 17 Feb 2009 11:46:49 -0500
User-agent: Thunderbird 2.0.0.14 (X11/20080506)

Sam Steingold wrote:
omake prints progress bar using the usual ^M terminal trick.
last week it was parsed nicely by emacs, i.e., the progress bar was updated in-place and, eventually, overwritten (by the last omake message). today, the freshly compiled cvs head emacs does not do that: the ^M character is inserted into the *compilation* buffer as is (instead of being interpreted as C-a C-k): [=== ] 01358 / 11812^M [====== ] 02995 / 11837^M [====== ] 03039 / 11837^M [====== ] 03244 / 11849^M [====== ] 03337 / 11849^M [====== ] 03428 / 11849^M [====== ] 03502 / 11849^M [======= ] 03598 / 11849^M [======= ] 03659 / 11849^M [======= ] 03692 / ....

this patch fixes *compilation*:



--- compile.el.~1.485.~ 2009-01-05 16:47:34.000000000 -0500
+++ compile.el  2009-02-17 11:31:48.001949000 -0500
@@ -1739,6 +1739,8 @@ Just inserts the text, and runs `compila
               ;; point at `process-mark' scroll along with the output, but we
               ;; now use window-point-insertion-type instead.
               (insert string)
+              (unless comint-inhibit-carriage-motion
+                (comint-carriage-motion (process-mark proc) (point)))
               (set-marker (process-mark proc) (point))
               (run-hooks 'compilation-filter-hook))
           (goto-char pos))))))


alas, this cannot be done from within compilation-filter-hook because (process-mark proc) is overwritten before compilation-filter-hook is called. (also, comint.el calls comint-carriage-motion from comint-output-filter, not a hook).





reply via email to

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