3 ms·
I just have this one liner for Wayland: cat ~/.local/share/emojis/emojis| wofi -i -d -M fuzzy -H 700 | cut -d " " -f 1 | tr -d '\040\011\012\015' | wtype -
by yoavm 2y ago
I just have this one liner for Wayland:
cat ~/.local/share/emojis/emojis| wofi -i -d -M fuzzy -H 700 | cut -d " " -f 1 | tr -d '\040\011\012\015' | wtype -
It shows an overlay fuzzy-searchable list of all emojis, and it writes selected one to the input regardless of the toolkit. assign it to a keyboard shortcut and you're good to go.
the ~/.local/share/emojis/emojis file is just a list of all emojis:
cat ~/.local/share/emojis/emojis | head -n 3
Grinning Face
Grinning Face with Big Eyes
Grinning Face with Smiling Eyes
(HN is removing the emojis but each line starts with the emoji self, followed by the description)
- Zirias 2y agoNote input is "out of scope" for wayland and XKB is used there for keyboard input as well. I just had a quick glance at "wtype" source and indeed, it fiddles with the keymap, using xkbcommon. So, assuming a suitable X11 replacement for this "wofi" tool, you could do exactly the same on X11 using "xdotool".
- yoavm 2y agoIndeed nothing special about Wayland for this, I have used `xdotool` in the old X11 days.
- Y_Y 2y agoAnd where can one obtain this `emojis` file?
- quotemstr 2y agoYou know, we should add an emojis dictionary to http://wordlist.aspell.net/ http://wordlist.aspell.net/ for exactly this purpose. Why not have a /usr/share/dict/emoji just like we have /usr/share/dict/words?
- yoavm 2y agohere it is: https://gist.github.com/bjesus/4b447dcb8a272f4c795b78752acec75f https://gist.github.com/bjesus/4b447dcb8a272f4c795b78752acec...
- deleted 2y ago[deleted]
- StrLght 2y agoI use rofi-emoji [0] on X11, and it's great. [0]: https://github.com/Mange/rofi-emoji https://github.com/Mange/rofi-emoji
- codethief 2y agoHa, I've been using a very similar tool for years, both for emojis but also for math characters: https://github.com/fdw/rofimoji https://github.com/fdw/rofimoji