## Show Color or Black and White Emojis in different applications ![](pic/emoji.png) Okay, this is a *very* specific preference. But what is Linux for, if not for working exactly according to a specific preferences? I have mixed opinions about emojis. I find symbols as you see on the screenshot[^win], very useful in notes, documentation, and even [terminal](https://github.com/dmi3/bin/blob/master/control-panel). But I prefer them to be rendered *grayscale* (screenshot left) to not stand out in the text, and look consistent with other symbols I use a lot: `✔` `✖` `⚠` `←↑↓→`. If you search The Internet, there will be a million advices on how to make emojis *colorful*. But I was not able to find a bit of info on how to make them *black or white* or *grayscale*. To make things even more tricky, I want *colorful* emojis in chat applications and Spotify, but *grayscale* in other applications like text editors and browser. It turns out that it is very simple to achieve if you use the right configs. 1. First you need to figure out which font provides color emojis in your system. Most probably it is `Noto Color Emoji` located in `/usr/share/fonts/truetype/noto/NotoColorEmoji.ttf`, but you may have another one. In any case, I recommend replacing it with [Apple Color Emoji for Linux](https://github.com/samuelngs/apple-emoji-linux#readme). Because everything else looks u-u-ugly! 🤪 - Changes should be visible in any application after you run `sudo fc-cache -fv` and restart the app 2. After all emojis are *colorful* we need to [blacklist](https://wiki.archlinux.org/title/font_configuration#Whitelisting_and_blacklisting_fonts) the font, by creating config: `~/.config/fontconfig/fonts.conf`: ```xml */.local/share/fonts/AppleColorEmoji.ttf ``` - Now emojis should be *grayscale* by default - If after blacklisting the font you don't see emoji at all, you need to install font with a black and white emojis like [Symbola font](https://fontlibrary.org/en/font/symbola) and run `sudo fc-cache -fv` 3. Now we need to create another config with same font whitelisted: `~/.config/fontconfig/fonts-color-emojis.conf`: ```xml /etc/fonts/fonts.conf */.local/share/fonts/AppleColorEmoji.ttf ``` 4. After these changes by default emojis will be *grayscale*, but running any app with `FONTCONFIG_FILE=/path/to/config` eviroment variable should enable *colorful* emojis - For example `FONTCONFIG_FILE=~/.config/fontconfig/fonts-color-emojis.conf spotify` - If you need emojis to be *colorful* by default, just swap the `acceptfont`/`rejectfont` in the config files. [^win]: And `💩` when mentioning Windows, obviously. 🏷️Markdown 🏷️CLI 🏷️Symbols