unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Juri Linkov <juri@linkov.net>
To: 52605@debbugs.gnu.org
Cc: larsi@gnus.org, mardani29@yahoo.es
Subject: bug#52605: [PATCH] Add isearch-emoji-by-name
Date: Mon, 10 Jan 2022 10:07:58 +0200	[thread overview]
Message-ID: <86pmp0qbf5.fsf@mail.linkov.net> (raw)
In-Reply-To: <m17db860aa.fsf@yahoo.es> ("Daniel Martín via \"Bug reports for GNU Emacs, the Swiss army knife of text editors\""'s message of "Sun, 09 Jan 2022 22:56:29 +0100")

> Also, I forgot to ask in my original message: Is there a plan to add an
> Emoji input method to Emacs? If so, the input method could be used
> during an isearch and this patch won't be necessary, right? Another
> benefit of the input method is that it will work in other situations as
> well, like in a query-replace.

I agree the input method is more general solution than a new isearch command.

#+begin_src emacs-lisp
;;; emoji.el --- Quail package for emoji character composition -*- lexical-binding: t -*-

;; Quail package `emoji' is based on emoji.el package.
;; This input method supports the same key sequences as the names
;; defined by the `C-x 8 e s' completions in emoji.el.

(quail-define-package
 "emoji" "UTF-8" "😀" t
 "Use the same key sequences as in `C-x 8 e s' completions defined in emoji.el."
 '(("\t" . quail-completion))
 t nil nil nil nil nil nil nil nil t)

(eval-when-compile
  (require 'emoji)
  (emoji--init)
  (defmacro emoji--define-rules ()
    `(quail-define-rules
      ,@(let ((rules nil))
          (maphash (lambda (from to)
                     (push (list from (if (stringp to)
                                          (vector to)
                                        to))
                           rules))
                   emoji--all-bases)
          rules))))

(emoji--define-rules)

(provide 'emoji)
;;; emoji.el ends here
#+end_src





  reply	other threads:[~2022-01-10  8:07 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <m135mpyc8p.fsf.ref@yahoo.es>
2021-12-18 18:55 ` bug#52605: [PATCH] Add isearch-emoji-by-name Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-12-18 19:07   ` Eli Zaretskii
2021-12-19  0:48     ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-12-19  6:53       ` Eli Zaretskii
2021-12-19 11:47         ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
2021-12-19 11:10   ` Lars Ingebrigtsen
2022-01-09 21:56     ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-01-10  8:07       ` Juri Linkov [this message]
2022-01-10 22:44         ` Daniel Martín via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-01-12  6:02           ` Lars Ingebrigtsen
2022-01-12 17:50             ` Juri Linkov
2022-01-13  6:05               ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=86pmp0qbf5.fsf@mail.linkov.net \
    --to=juri@linkov.net \
    --cc=52605@debbugs.gnu.org \
    --cc=larsi@gnus.org \
    --cc=mardani29@yahoo.es \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).