From 5e9ceccf233d87444daf002b41592bbb24b98f7f Mon Sep 17 00:00:00 2001 From: syl20bnr Date: Sun, 24 May 2015 20:07:34 -0400 Subject: [PATCH] emoji layer: fix rendering in org buffers There is still an issue with the first colon that is not invisible but I guess we can live with it --- .../emacs-emoji-cheat-sheet-plus/emoji-cheat-sheet-plus.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contrib/fun/emoji/extensions/emacs-emoji-cheat-sheet-plus/emoji-cheat-sheet-plus.el b/contrib/fun/emoji/extensions/emacs-emoji-cheat-sheet-plus/emoji-cheat-sheet-plus.el index a96f5c19b..147b39ee7 100644 --- a/contrib/fun/emoji/extensions/emacs-emoji-cheat-sheet-plus/emoji-cheat-sheet-plus.el +++ b/contrib/fun/emoji/extensions/emacs-emoji-cheat-sheet-plus/emoji-cheat-sheet-plus.el @@ -269,7 +269,7 @@ (goto-char start) (let ((inhibit-read-only t) (modified (buffer-modified-p))) - (while (re-search-forward "\:.+?\:" end t) + (while (re-search-forward "\:[a-z0-9\\+_-]+?\:" end t) (let* ((code (intern (match-string 0))) (image (cdr (assq code emoji-cheat-sheet-plus-image--cache)))) (when image @@ -279,7 +279,7 @@ ;; occurrences of the same emoji (add-text-properties (match-beginning 0) (1+ (match-beginning 0)) - `(invisible t emoji-cheat-sheet-plus-display t)) + '(invisible t emoji-cheat-sheet-plus-display t)) (add-text-properties (1+ (match-beginning 0)) (match-end 0) `(display ,image emoji-cheat-sheet-plus-display t))