diff --git a/lisp/org-capture.el b/lisp/org-capture.el index 75675c0f3..6aa100fbe 100644 --- a/lisp/org-capture.el +++ b/lisp/org-capture.el @@ -1630,7 +1630,7 @@ The template may still contain \"%?\" for cursor positioning." (org-capture--expand-embedded-elisp 'mark) (let ((regexp "%\\(:[-a-za-z]+\\|<\\([^>\n]+\\)>\\|[aAcfFikKlntTuUx]\\|\ -^\\(?:{\\([^}]*\\)}\\)?\\([CgGLptTuU]\\)?\\)") +\\^\\(?:{\\([^}]*\\)}\\)?\\([CgGLptTuU]\\)?\\)") (strings)) (while (re-search-forward regexp nil t) (let ((pos (copy-marker (match-beginning 0))) @@ -1669,8 +1669,8 @@ The template may still contain \"%?\" for cursor positioning." "org-capture-template-prompt-history::" (or prompt "")))) (setq completions (mapcar #'list completions))) - (pcase (string-to-char key) - ((or ?G ?g) + (pcase key + ((or `"G" `"g") (let* ((org-last-tags-completion-table (org-global-tags-completion-table (cond ((equal key "G") (org-agenda-files)) @@ -1693,7 +1693,7 @@ The template may still contain \"%?\" for cursor positioning." (and (org-at-heading-p) (let ((org-ignore-region t)) (org-set-tags nil 'align)))))) - (?C + (`"C" (cond ((= (length clipboards) 1) (insert (car clipboards))) ((> (length clipboards) 1) @@ -1701,7 +1701,7 @@ The template may still contain \"%?\" for cursor positioning." (car clipboards) '(clipboards . 1) (car clipboards)))))) - (?L + (`"L" (cond ((= (length clipboards) 1) (org-insert-link 0 (car clipboards))) ((> (length clipboards) 1) @@ -1711,7 +1711,7 @@ The template may still contain \"%?\" for cursor positioning." (car clipboards) '(clipboards . 1) (car clipboards)))))) - (?p (org-set-property prompt nil)) + (`"p" (org-set-property prompt nil)) ((guard key) ;; These are the date/time related ones. (let* ((upcase? (equal (upcase key) key))