help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: New function: rcd-highlight-list


From: tomas
Subject: Re: New function: rcd-highlight-list
Date: Tue, 18 May 2021 19:27:21 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On Tue, May 18, 2021 at 08:08:29PM +0300, Jean Louis wrote:
> 
> (defun rcd-highlight-list (list)
>   "Uses LIST to highlight strings in buffer."
>   (hi-lock-mode)
>   (let* ((list (delete "" list))
>       (highlights hi-lock-face-defaults))
>     (while list
>       (highlight-regexp (pop list) (pop highlights)))))
> 
> Just feed to this function a list of strings to highlight:

What happens if one of the strings is ".*"?

Cheers
 - t

Attachment: signature.asc
Description: Digital signature


reply via email to

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