Function: tooltip-process-prompt-regexp
tooltip-process-prompt-regexp is a byte-compiled function defined in
tooltip.el.gz.
Signature
(tooltip-process-prompt-regexp PROCESS)
Documentation
Return regexp matching the prompt of PROCESS at the end of a string.
The prompt is taken from the value of comint-prompt-regexp in
the buffer of PROCESS.
Source Code
;; Defined in /usr/src/emacs/lisp/tooltip.el.gz
(defun tooltip-process-prompt-regexp (process)
"Return regexp matching the prompt of PROCESS at the end of a string.
The prompt is taken from the value of `comint-prompt-regexp' in
the buffer of PROCESS."
(let ((prompt-regexp (with-current-buffer (process-buffer process)
comint-prompt-regexp)))
(concat "\n*"
;; Most start with `^' but the one for `sdb' cannot be easily
;; stripped. Code the prompt for `sdb' fixed here.
(if (= (aref prompt-regexp 0) ?^)
(substring prompt-regexp 1)
"\\*")
"$")))