Function: gptel--fontify-preset-keyword
gptel--fontify-preset-keyword is a natively compiled function defined
in gptel.el.
Signature
(gptel--fontify-preset-keyword END)
Documentation
Font-lock function for preset indicators in chat buffers.
Return preset fontification info for text up to END.
Source Code
;; Defined in /nix/store/q3r7g81pvghw7a523kjk2k2zih3pfk8z-emacs-packages-deps/share/emacs/site-lisp/elpa/gptel-20261002.545/gptel.el
;; ;; Alternative approach with string search
;; (search-forward "@" nil t)
;; (if (and (memq (char-syntax (char-before (1- (point)))) '(32 62))
;; (looking-at "\\([^[:blank:]]+?\\)[[:punct:]]?\\s-+"))
;; do-stuff)
(defun gptel--fontify-preset-keyword (end)
"Font-lock function for preset indicators in chat buffers.
Return preset fontification info for text up to END."
(and (re-search-forward "@\\([^[:space:]]+\\)\\_>" end t)
(or (= (match-beginning 0) (point-min))
(memq (char-syntax (char-before (match-beginning 0))) '(32 62)))
(not (plist-get (text-properties-at (match-beginning 1)) 'gptel))))