[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: shell-command-on-region fooled by long lines
From: |
Kevin Rodgers |
Subject: |
Re: shell-command-on-region fooled by long lines |
Date: |
Thu, 02 Feb 2006 12:54:04 -0700 |
User-agent: |
Mozilla Thunderbird 0.9 (X11/20041105) |
Kevin Rodgers wrote:
> Thanks to the clue posted by Sam Owre in a subsequent thread, this is
> all that's needed:
Oops. A final newline is ignored when displaying the message in the
echo area, so the call to count-screen-lines should specify nil for
the COUNT-FINAL-NEWLINE argument:
2006-02-02 Kevin Rodgers <ihs_4664@yahoo.com>
* simple.el (display-message-or-buffer): Count screen lines
instead of buffer lines when determining whether the message
will fit in the echo area/minibuffer window.
*** simple.el~ Thu Feb 2 09:31:34 2006
--- simple.el Thu Feb 2 09:35:18 2006
***************
*** 1922,1928 ****
(let ((lines
(if (= (buffer-size) 0)
0
! (count-lines (point-min) (point-max)))))
(cond ((= lines 0))
((and (or (<= lines 1)
(<= lines
--- 1922,1928 ----
(let ((lines
(if (= (buffer-size) 0)
0
! (count-screen-lines nil nil nil (minibuffer-window)))))
(cond ((= lines 0))
((and (or (<= lines 1)
(<= lines
--
Kevin Rodgers