emacs-emojify

fork of https://github.com/iqbalansari/emacs-emojify
Log | Files | Refs | LICENSE

commit 0bffa9223f76dc8dcf5d3e207b9dc7ba4c381ec4
parent a951c22765b0855b6469f90267b5278c1b96b82e
Author: Iqbal Ansari <iqbalansari02@yahoo.com>
Date:   Mon, 26 Oct 2015 09:31:09 +0530

Do not emojify org-mode tags

Diffstat:
Memojify.el | 13++++++++-----
1 file changed, 8 insertions(+), 5 deletions(-)

diff --git a/emojify.el b/emojify.el @@ -46,11 +46,14 @@ (not (and (char-before start) (eq (char-syntax (char-before start)) ?w))) (not (and (char-after end) - (eq (char-syntax (char-after end)) ?w)))) - (add-text-properties start end (list 'display (pcase emoji-substitution-style - (`image (emojify-get-image match))) - 'emojified t - 'point-entered (lambda (x y) (message (format "%s" match))))))) + (eq (char-syntax (char-after end)) ?w))) + (or (not (equal major-mode 'org-mode)) + (equal (face-at-point) 'org-tag))) + (when (gethash match emoji-parsed) + (add-text-properties start end (list 'display (pcase emoji-substitution-style + (`image (emojify-get-image match))) + 'emojified t + 'point-entered (lambda (x y) (message (format "%s" match)))))))) (defun emojify--emojify-region (beg end) (let ((inhibit-point-motion-hooks t))