# HG changeset patch # User Eli Zaretskii # Date 1136037087 0 # Node ID cbb3942260ab879b2811684dd220315f6fa93777 # Parent 96503c1f5d7bedefe3d5dff5faeb2a9635d184a2 (gud-display-line): Support hl-line in the source buffer. diff -r 96503c1f5d7b -r cbb3942260ab lisp/progmodes/gud.el --- a/lisp/progmodes/gud.el Sat Dec 31 11:56:21 2005 +0000 +++ b/lisp/progmodes/gud.el Sat Dec 31 13:51:27 2005 +0000 @@ -2735,6 +2735,7 @@ (window (and buffer (or (get-buffer-window buffer) (display-buffer buffer)))) (pos)) + (message "%s %s" (current-buffer) buffer) (if buffer (progn (with-current-buffer buffer @@ -2750,7 +2751,15 @@ (setq pos (point)) (or gud-overlay-arrow-position (setq gud-overlay-arrow-position (make-marker))) - (set-marker gud-overlay-arrow-position (point) (current-buffer))) + (set-marker gud-overlay-arrow-position (point) (current-buffer)) + ;; If they turned on hl-line, move the hl-line highlight to + ;; the arrow's line. + (when (featurep 'hl-line) + (cond + (global-hl-line-mode + (global-hl-line-highlight)) + ((and hl-line-mode hl-line-sticky-flag) + (hl-line-highlight))))) (cond ((or (< pos (point-min)) (> pos (point-max))) (widen) (goto-char pos))))