9

Enable color emojis in Chrome, Xubuntu 18.04.1

 3 years ago
source link: https://askubuntu.com/questions/1060146/enable-color-emojis-in-chrome-xubuntu-18-04-1/1107311#1107311
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client
Enable color emojis in Chrome, Xubuntu 18.04.1

By using our site, you acknowledge that you have read and understand our Cookie Policy, Privacy Policy, and our Terms of Service.

Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.

Sign up to join this community

Anybody can ask a question
Anybody can answer
The best answers are voted up and rise to the top
Asked 2 years, 5 months ago
Viewed 5k times

I have followed this question: 18.04: color emoji not showing up at all in Chrome, only partially in Firefox, installed fonts-noto-color-emoji manually, but color emojis are still not showing up in Chrome or VS Code. Color emojis work in Mousepad, XFCE's terminal emulator.

I'm on the latest Xubuntu (XFCE) 18.04.1, fresh install.

The output of sudo apt rdepends fonts-noto-color-emoji is like this:

fonts-noto-color-emoji
Reverse Depends:
  Recommends: ubuntu-desktop
  Recommends: lubuntu-gtk-desktop
  Recommends: lubuntu-desktop
  Recommends: ubuntustudio-desktop
  Recommends: ubuntu-mate-desktop
  Recommends: ubuntu-mate-core
  Recommends: ubuntu-budgie-desktop
  Recommends: lubuntu-gtk-desktop
  Recommends: lubuntu-desktop
  Recommends: gnome
  Recommends: gajim
  Recommends: dino-im
|Recommends: corebird

How can I get color emojis working in Chrome/Chromium?

Edit: Apparently, the emoji is loaded only if the web page asks for "Noto Color Emoji" font explicitly, like on this page. Where I want it to work however is in for example where the noto font is not explicitly asked, and also dev tools, console, omni bar.

I was going to comment buuuut I don't have enough reputation 😢 (hey look, here's an emoji to check if it is working or not!)

This solution worked for me "partially", it did fix the emojis in Discord and in the Terminal, but in Firefox it was still a mix of "some of them works, some of them doesn't", I also found this but that didn't fix the issue in Firefox... 😭

So here's what I did to fix:

  1. Install fonts-noto-color-emoji (sudo apt-get install fonts-noto-color-emoji)

    • This will make emojis work in the terminal & Mousepad & probably other apps too!

That's it, if you REALLY need emojis working on Firefox (emojis are wonky in Ubuntu too, you ain't losing anything by using Xubuntu), you can do this

  1. Go to ~/.config/fontconfig/conf.d/99-emoji.conf (you will probably need to create the folders!) and add this:

    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE fontconfig SYSTEM "fonts.dtd">
    <fontconfig>
      <match>
        <test name="family"><string>sans-serif</string></test>
        <edit name="family" mode="append" binding="strong">
          <string>Bitstream Vera Serif</string>
          <string>Noto Color Emoji</string>
        </edit>
      </match>
    
      <!-- Add emoji generic family -->
      <alias binding="strong">
        <family>emoji</family>
        <default><family>Noto Color Emoji</family></default>
      </alias>
    
      <!-- Aliases for the other emoji fonts -->
      <alias binding="strong">
        <family>Apple Color Emoji</family>
        <prefer><family>Noto Color Emoji</family></prefer>
      </alias>
      <alias binding="strong">
        <family>Segoe UI Emoji</family>
        <prefer><family>Noto Color Emoji</family></prefer>
      </alias>
      <alias binding="strong">
        <family>Emoji One</family>
        <prefer><family>Noto Color Emoji</family></prefer>
      </alias>
    </fontconfig>
    
  2. fc-cache -fv

Now restart the apps and... that's it! Emojis will work in Chrome and Firefox! Have fun! 🎉

(If Firefox emojis are still borked, you can try changing the default Firefox font to Noto Color Emoji)

Keep in mind: Numbers in Firefox will have serifs

Keep in mind²: Apps installed via the Ubuntu store (or snap) won't have emojis working! I'm not sure why this happens... if someone knows how to fix this, let me know!

Firefox @ getemoji.com: ff in getemoji

Chromium @ getemoji.com: chromium in getemoji

Firefox @ Google Search: ff in google search

Discord Canary (Electron): discord canary with emojis

Terminal (Xfce): emojis in xfce terminal

🥰🥰🥰

Your Answer

Sign up or log in

Sign up using Google
Sign up using Facebook
Sign up using Email and Password

Post as a guest

Name
Email

Required, but never shown

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged xubuntu google-chrome fonts xfce emoji or ask your own question.


About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK