Function: htmlize-attr-escape
htmlize-attr-escape is a byte-compiled function defined in htmlize.el.
Signature
(htmlize-attr-escape STRING)
Source Code
;; Defined in ~/.emacs.d/elpa/htmlize-20250724.1703/htmlize.el
(defun htmlize-attr-escape (string)
;; Like htmlize-protect-string, but also escapes double-quoted
;; strings to make it usable in attribute values.
(setq string (htmlize-protect-string string))
(if (not (string-match "\"" string))
string
(mapconcat (lambda (char)
(if (eql char ?\")
"""
(char-to-string char)))
string "")))