* bug#17260: 24.4.50; pulse.el: pulse-momentarily-highlight-one-line ignores point argument
@ 2014-04-13 5:44 Matt Curtis
2014-12-08 23:57 ` Lars Magne Ingebrigtsen
0 siblings, 1 reply; 2+ messages in thread
From: Matt Curtis @ 2014-04-13 5:44 UTC (permalink / raw)
To: 17260
[-- Attachment #1: Type: text/plain, Size: 2086 bytes --]
The function "pulse-momentarily-highlight-one-line" (in pulse.el)
ignores the point argument and uses the current point instead.
To reproduce this issue, call the function with a location on
a line other than where the point currently is. The line with
point will be pulsed, not the line containing the supplied
location.
(pulse-momentary-highlight-one-line 259)
The following patch fixes the issue with (goto-char point)
-----
diff --git a/lisp/cedet/pulse.el b/lisp/cedet/pulse.el
index e2a48a4..10ede62 100644
--- a/lisp/cedet/pulse.el
+++ b/lisp/cedet/pulse.el
@@ -227,13 +227,15 @@ (defun pulse-momentary-unhighlight ()
(defun pulse-momentary-highlight-one-line (point &optional face)
"Highlight the line around POINT, unhighlighting before next command.
Optional argument FACE specifies the face to do the highlighting."
- (let ((start (point-at-bol))
- (end (save-excursion
- (end-of-line)
- (when (not (eobp))
- (forward-char 1))
- (point))))
- (pulse-momentary-highlight-region start end face)))
+ (save-excursion
+ (goto-char point)
+ (let ((start (point-at-bol))
+ (end (save-excursion
+ (end-of-line)
+ (when (not (eobp))
+ (forward-char 1))
+ (point))))
+ (pulse-momentary-highlight-region start end face))))
(defun pulse-momentary-highlight-region (start end &optional face)
"Highlight between START and END, unhighlighting before next command.
-----
In GNU Emacs 24.4.50.1 (x86_64-apple-darwin13.1.0, NS apple-appkit-1265.19)
of 2014-04-13 on gonagall.local
Windowing system distributor `Apple', version 10.3.1265
Configured using:
`configure --prefix=/usr/local/Cellar/emacs/HEAD --without-dbus
--enable-locallisppath=/usr/local/share/emacs/site-lisp
--infodir=/usr/local/Cellar/emacs/HEAD/share/info/emacs --with-gnutls
--with-ns --disable-ns-self-contained'
Configured features:
ACL GNUTLS LIBXML2 ZLIB
Important settings:
value of $LC_CTYPE: en_US.UTF-8
locale-coding-system: utf-8-unix
[-- Attachment #2: Type: text/html, Size: 2850 bytes --]
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-12-08 23:57 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-13 5:44 bug#17260: 24.4.50; pulse.el: pulse-momentarily-highlight-one-line ignores point argument Matt Curtis
2014-12-08 23:57 ` Lars Magne Ingebrigtsen
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.