Hacker News new | ask | show | jobs
by kozak 1933 days ago
By the way, we already have an "emoji button" on our keyboards: on Windows, it's the Win+. keystroke. Try it if your Windows 10 is updated enough.
10 comments

That UI is hilarious (for a given value of hilarious) in the sense that the search for emojis uses whichever input language you're using, even if your UI language is something else.

So, for instance to find the light bulb emoji, I need to start typing "valo" (light in Finnish), which really threw me off at first.

The default Android keyboard has similar behaviour. I was learning Spanish so I switched my phone to Spanish then back in English at some point later. Yet the change never propagated to the keyboard for some reason so my emojis are still in Spanish.
eggplants in Spanish
la berenjena
I originally thought the typing didn't work at all, because the couple of times I tried pressing Win+. the emoji UI came up, and it said "Keep typing to find an emoji", but nothing happened when I typed.

Turns out the search only works when you have a text entry area selected elsewhere.

The iOS and I believe macOS emoji picker let’s you use any language to search for emojis. ハート brings up hearts for example.
But you have to switch to that language first.

For example on my iPhone if I type in Norwegian and jump to emoji then I can type “hjerte” and find the heart. But if I type “heart” then there are no results when the language is Norwegian. So if I want to search for emojis by English name, then I must first ensure that my keyboard is in English. And this is good I think, but wanted to point it out.

On my phone at least (latest iOS) it will search any installed keyboard languages.
A couple of alternatives for Linux users.

https://wiki.archlinux.org/index.php/IBus#Emoji_input

The kitty terminal emulator supports this out of the box (it also works on two other platforms):

https://github.com/kovidgoyal/kitty

Ctrl+Shift+U opens a Unicode input panel with fuzzy search by symbol code or name.

I use Compose key for this, surprised nobody mentioned it here yet. This way it works in all X11 apps (Sway supports this out of the box as well), with no need for extra software or some specific desktop environment.

Just put something like

  <Multi_key> <semicolon> <parenright>  : ""
  <Multi_key> <t> <u>                   : ""
  <Multi_key> <t> <d>                   : ""
in your ~/.XCompose.

Yes, you have to put all the emojis you want there manually, but I use very few of them so it works for me.

EDIT: HN removed the emojis from my snippet. The double quotes there contained smiling face, thumb up, and thumb down.

My n00buntu derivative has some emojis and other logograms out of the box, eg. lines 326–337 of /usr/share/X11/locale/en_US.UTF-8/Compose:

  <Multi_key> <C> <C> <C> <P>             : ""   U262D # HAMMER AND SICKLE
  <Multi_key> <O> <A>                     : "Ⓐ"   U24B6 # CIRCLED LATIN CAPITAL LETTER A
  <Multi_key> <less> <3>                  : "♥"   U2665 # BLACK HEART SUIT
 
  <Multi_key> <colon> <parenright>        : ""   U263A # WHITE SMILING FACE
  <Multi_key> <colon> <parenleft>         : ""   U2639 # WHITE FROWNING FACE
  <Multi_key> <backslash> <o> <slash>     : ""      # PERSON RAISING BOTH HANDS IN CELEBRATION
 
  <Multi_key> <p> <o> <o>                 : ""  U1F4A9 # PILE OF POO
 
  <Multi_key> <F> <U>                     : ""  U1F595 # REVERSED HAND WITH MIDDLE FINGER EXTENDED
  <Multi_key> <L> <L> <A> <P>             : ""  U1F596 # RAISED HAND WITH PART BETWEEN MIDDLE AND RING FINGERS
Unbutchered: http://ix.io/2SsC
Oh, those are in Debian, as a matter of fact!
https://github.com/kragen/XCompose for those who prefer a more methodical approach.
There's also https://github.com/salty-horse/ibus-uniemoji if you want something a little more interactive.

I wrote https://github.com/sphaerophoria/ibus-memebox for myself because I wasn't quite happy with the performance of any of the solutions I found.

And another character picker for Rofi:

https://github.com/fdw/rofimoji/

GNOME has Ctrl+period.
KDE has one, too. Not sure what the default was, I remapped it to Super+Period
I use KDE and I've never tried it before. Win+. works!
Does it? I am in stock gnome and this shortcut isn't bound by default. What distro are you using?
I believe it has to be a GTK app - which almost none of the things I use on a daily basis are. Try in gedit or something like that.

My daily drivers are IntelliJ, Firefox, Chrome, and Terminator so it's not super useful to me... :'(

Check out this extension: https://extensions.gnome.org/extension/1162/emoji-selector/

It implements a system level emoji keyboard that you can trigger with <Super + e>. It works pretty great and on all apps, I use it a lot.

Oh wow, you are totally right, that does work in GTK apps. My daily drivers are about the same :(
It doesn't do anything for me. Can you point to a doc?
For other readers: emoji keyboard is ctrl + cmd + space on macOS.
On macOS I use Rocket [0]. It's not perfect but it's the best I've used and it does make finding the emoji you want pretty easy. You can add custom alias/shortcuts for the emojis and you can also use it to insert images/gifs from the searcher.

[0] https://matthewpalmer.net/rocket/

The globe button on newer Macs can be retasked to call up the emoji input panel (I guess any button could be before with custom keyboard shortcuts but now it's a simple dropdown in keyboard preferences.)
Holly mothballs. I didn't know this trick. Works in Slack as well.
Not always; that's app-specific, not a system-wide setting.
I think it is system-wide. At least I've not encountered any input field where it doesn't work. Even Microsoft Office, which uses its own input routines, supports it.
It's a shortcut to an Edit menu item within the application, so whatever shortcut the app gives it; e.g. in Firefox it appears to be simply Cmd-<space>.

But wait... that doesn't actually work (it just switches to the next input layout). Maybe that depends on my keyboard settings in System Preferences. Or maybe it's just a Firefox bug.

Cmd-space launches Spotlight. Ctrl-space switches the input layout. Ctrl-Cmd-Space launches the emoji viewer (even in Firefox...)
Not for me. (I suspect the details of this vary between system versions, and they certainly depend on settings chosen in System Preferences / Keyboard / Shortcuts.)
It doesn't work in every app sadly. Qt based apps for example
Hmm, I guess I've never used any Qt-based apps.
I use two now, Quassel which is an IRC client, and QtPass which is a password manager. Both are cross-platform which is great because I don't use just Mac. I use pretty much everything. Mac, Windows, Linux, FreeBSD.

That means most of the built-in facilities of the Mac (like iCloud Keychain) are no good for me. Because they only work on Apple OSes.

But anyway both these apps don't support this. When I press the keystroke, nothing happens. I suppose it only works for apps that use the native text input boxes, or that have built specific support for the feature like browsers.

In my password manager I can do without Emoji, though it allows for text comments and it would be handy there. In IRC it's quite handy to have the option these days.

Thanks, did not know this. In fact, learned both Win + plus (and discovered Win + minus along the way) as well as Win + dot :)
> Try it if your Windows 10 is updated enough

And if it's not, please go update your Windows. You should not be reading HN with out outdated operating system.

laughs in Windows 7
If your Windows isn't updated enough, grab AutoHotkey[0], and try this: [1]. It's a little "emoji keyboard" I wrote a few years ago, to insert most important emojis into team conversations. Globally binds itself to F2, and it's ergonomic. You press F2, then number, then CTRL+V (that last step could be automated too).

The script is easy to extend with new emojis, and also supports selecting alternatives based on which program you had focus on when invoking the keyboard - you can see it using Skype-specific notation for Skype.

--

[0] - https://www.autohotkey.com/ - it's the keyboard rebinding / advanced automation platform for Windows. Literally the first thing I install on a new Windows machine (mostly for rebinding Caps Lock to Ctrl).

[1] - https://gist.github.com/TeMPOraL/d330edccf8ba9a2b13d01b4e7f1...

On my work computer on Win10 it just opens up the magnifier :(
it's <winkey> AND <periodkey>. I tried <winkey> AND <pluskey> the first time too :)
There is an actual emoji button on new dell keyboards as well as a lock button. Not just a repurposed FN key but really a separate key with a smiley on it and one with a lock next to it. Both work without extra drivers in Windows 10.
Do you know if this key produces the regular shortcut for invoking the emoji input method in Windows, or if it has its own key code?
Not sure. And I only know how to figure that out in Linux but it's my windows work computer. Is there a windows method to see what key code the keyboard is sending?
Win+Period or Win+Semicolon
<-- Yes!

Edit: Alas, it does not work on HN. Pity.

Where does this work?
Literally everywhere. HN just strips out emojis from posts, because they're obnoxious.
Unless, apparently, you're trying to post your sweet new email address. Honest question: if this takes off, do you think HN will stop stripping them?
No. Because

1) it won't take off 2) punycode 3) other reasons