Skip to content

Emojis render no color on macOS Desktop #100964

Open

Description

@letungcntt

On desktop, sometimes emojis render no color. I can check it, with macOS or windows. On windows, the problem is more serious

Screen.Recording.2022-03-29.at.18.08.38.mov
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel beta, 2.12.0-4.1.pre, on macOS 12.3 21E230 darwin-x64, locale en-VN)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[✓] Xcode - develop for iOS and macOS (Xcode 13.2)
[✓] Chrome - develop for the web
[✓] Android Studio (version 4.2)
[✓] VS Code (version 1.65.2)
[✓] Connected device (2 available)
[✓] HTTP Host Availability

• No issues found!

Activity

  1. changed the title [-]Emoji render no color[/-] [+]Emojis render no color[/+] on Mar 29, 2022
  2. daadu commented on Mar 29, 2022

    @daadu
    Contributor

    I guess, these are rendered based on Font.

  3. letungcntt commented on Mar 29, 2022

    @letungcntt
    Author

    I hope it's the answer. but sometimes emojis render right, sometimes render wrong.

    Untitled.mov
  4. letungcntt commented on Mar 29, 2022

    @letungcntt
    Author

    On Windows, emojis can't render flags color:
    image

  5. daadu commented on Mar 29, 2022

    @daadu
    Contributor

    Try using https://github.com/googlefonts/noto-emoji/tree/main/fonts -as font for colored emoji.

  6. letungcntt commented on Mar 30, 2022

    @letungcntt
    Author

    @daadu Thanks for the answer, I have pulled and added this font https://github.com/googlefonts/noto-emoji/tree/main/fonts.
    By macOS, the problem doesn't fix. By Windows, most emojis had rendered color. However, emojis in Flags, can't render color.

    Windows:

    Screen.Recording.2022-03-30.at.09.30.00.mov

    MacOS:

    Screen.Recording.2022-03-30.at.09.31.54.mov
  7. daadu commented on Mar 30, 2022

    @daadu
    Contributor

    Did you tired windows compatible version?

  8. letungcntt commented on Mar 30, 2022

    @letungcntt
    Author

    yeah. I had used NotoColorEmoji_WindowsCompatible.ttf on windows. Normally, emojis cant render color but after I added NotoColorEmoji_WindowsCompatible.ttf most of the emojis rendered color, except emojis in tag flags

  9. maheshj01 commented on Mar 30, 2022

    @maheshj01
    Member

    Hi @letungcntt, Thanks for filing the issue. I verified on mac on the latest stable channel and I am unable to reproduce the issue. But on the latest beta and the master channel the issue is reproduced ❤ emoji is rendered black on macos Desktop and renders fine on the web.

    Stable

    Screen.Recording.2022-03-30.at.12.39.03.PM_Trim.mp4

    beta / master

    Screen.Recording.2022-03-30.at.12.51.22.PM_Trim.mp4

    Labeling this issue as a regression.

    flutter doctor -v (mac)
    [✓] Flutter (Channel stable, 2.10.4, on macOS 12.3 21E230 darwin-arm, locale en-GB)
        • Flutter version 2.10.4 at /Users/mahesh/Documents/flutter
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision c860cba910 (3 days ago), 2022-03-25 00:23:12 -0500
        • Engine revision 57d3bac3dd
        • Dart version 2.16.2
        • DevTools version 2.9.2
    
    [✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
        • Android SDK at /Users/mahesh/Library/Android/sdk
        • Platform android-31, build-tools 31.0.0
        • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
        • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
        • All Android licenses accepted.
    
    [✓] Xcode - develop for iOS and macOS (Xcode 13.2.1)
        • Xcode at /Applications/Xcode.app/Contents/Developer
        • CocoaPods version 1.10.2
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] Android Studio (version 4.2)
        • Android Studio at /Applications/Android Studio.app/Contents
        • Flutter plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/9212-flutter
        • Dart plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/6351-dart
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    
    [✓] IntelliJ IDEA Community Edition (version 2021.2.1)
        • IntelliJ at /Applications/IntelliJ IDEA CE.app
        • Flutter plugin version 61.2.4
        • Dart plugin version 212.5080.8
    
    [✓] VS Code (version 1.65.2)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.37.20220301
    
    [✓] Connected device (4 available)
        • Redmi K20 Pro (mobile) • 192.168.1.2:55555                    • android-arm64  • Android 11 (API 30)
        • iPhone 12 Pro (mobile) • 535317A4-921C-488F-B234-C2CC6D4AE5A1 • ios            •
          com.apple.CoreSimulator.SimRuntime.iOS-14-5 (simulator)
        • macOS (desktop)        • macos                                • darwin-arm64   • macOS 12.3 21E230 darwin-arm
        • Chrome (web)           • chrome                               • web-javascript • Google Chrome 99.0.4844.83
    
    [✓] HTTP Host Availability
        • All required HTTP hosts are available
    
    • No issues found!
    
    [✓] Flutter (Channel beta, 2.12.0-4.1.pre, on macOS 12.3 21E230 darwin-arm, locale en-IN)
        • Flutter version 2.12.0-4.1.pre at /Users/mahesh/Documents/flutter_beta
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision 680962aa75 (13 days ago), 2022-03-16 13:46:03 -0700
        • Engine revision e9f57b5d0f
        • Dart version 2.17.0 (build 2.17.0-182.1.beta)
        • DevTools version 2.11.1
    
    [✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
        • Android SDK at /Users/mahesh/Library/Android/sdk
        • Platform android-31, build-tools 31.0.0
        • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
        • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
        • All Android licenses accepted.
    
    [!] Xcode - develop for iOS and macOS (Xcode 13.2.1)
        • Xcode at /Applications/Xcode.app/Contents/Developer
        ! CocoaPods 1.10.2 out of date (1.11.0 is recommended).
            CocoaPods is used to retrieve the iOS and macOS platform side's plugin code that responds to your
            plugin usage on the Dart side.
            Without CocoaPods, plugins will not work on iOS or macOS.
            For more info, see https://flutter.dev/platform-plugins
          To upgrade see https://guides.cocoapods.org/using/getting-started.html#installation for
          instructions.
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] Android Studio (version 4.2)
        • Android Studio at /Applications/Android Studio.app/Contents
        • Flutter plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/9212-flutter
        • Dart plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/6351-dart
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    
    [✓] IntelliJ IDEA Community Edition (version 2021.2.1)
        • IntelliJ at /Applications/IntelliJ IDEA CE.app
        • Flutter plugin version 61.2.4
        • Dart plugin version 212.5080.8
    
    [✓] VS Code (version 1.65.2)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.37.20220301
    
    [✓] Connected device (2 available)
        • macOS (desktop) • macos  • darwin-arm64   • macOS 12.3 21E230 darwin-arm
        • Chrome (web)    • chrome • web-javascript • Google Chrome 99.0.4844.84
    
    [✓] HTTP Host Availability
        • All required HTTP hosts are available
    
    ! Doctor found issues in 1 category.
    [✓] Flutter (Channel master, 2.13.0-0.0.pre.277, on macOS 12.3 21E230 darwin-arm, locale en-GB)
        • Flutter version 2.13.0-0.0.pre.277 at /Users/mahesh/Documents/flutter_master
        • Upstream repository https://github.com/flutter/flutter.git
        • Framework revision 13d2381109 (6 hours ago), 2022-03-27 21:00:08 -0400
        • Engine revision 559e259c54
        • Dart version 2.17.0 (build 2.17.0-246.0.dev)
        • DevTools version 2.11.4
    
    [✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
        • Android SDK at /Users/mahesh/Library/Android/sdk
        • Platform android-31, build-tools 31.0.0
        • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
        • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
        • All Android licenses accepted.
    
    [!] Xcode - develop for iOS and macOS (Xcode 13.2.1)
        • Xcode at /Applications/Xcode.app/Contents/Developer
        ! CocoaPods 1.10.2 out of date (1.11.0 is recommended).
            CocoaPods is used to retrieve the iOS and macOS platform side's plugin code that responds to your plugin
            usage on the Dart side.
            Without CocoaPods, plugins will not work on iOS or macOS.
            For more info, see https://flutter.dev/platform-plugins
          To upgrade see https://guides.cocoapods.org/using/getting-started.html#installation for instructions.
    
    [✓] Chrome - develop for the web
        • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
    
    [✓] Android Studio (version 4.2)
        • Android Studio at /Applications/Android Studio.app/Contents
        • Flutter plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/9212-flutter
        • Dart plugin can be installed from:
          🔨 https://plugins.jetbrains.com/plugin/6351-dart
        • Java version OpenJDK Runtime Environment (build 11.0.8+10-b944.6916264)
    
    [✓] IntelliJ IDEA Community Edition (version 2021.2.1)
        • IntelliJ at /Applications/IntelliJ IDEA CE.app
        • Flutter plugin version 61.2.4
        • Dart plugin version 212.5080.8
    
    [✓] VS Code (version 1.65.2)
        • VS Code at /Applications/Visual Studio Code.app/Contents
        • Flutter extension version 3.37.20220301
    
    [✓] Connected device (4 available)
        • Redmi K20 Pro (mobile) • 192.168.1.2:55555                    • android-arm64  • Android 11 (API 30)
        • iPhone 12 Pro (mobile) • 535317A4-921C-488F-B234-C2CC6D4AE5A1 • ios            •
          com.apple.CoreSimulator.SimRuntime.iOS-14-5 (simulator)
        • macOS (desktop)        • macos                                • darwin-arm64   • macOS 12.3 21E230 darwin-arm
        • Chrome (web)           • chrome                               • web-javascript • Google Chrome 99.0.4844.83
    
    [✓] HTTP Host Availability
        • All required HTTP hosts are available
    
    ! Doctor found issues in 1 category.
    
  10. added
    frameworkflutter/packages/flutter repository. See also f: labels.
    platform-macosBuilding on or for macOS specifically
    c: renderingUI glitches reported at the engine/skia or impeller rendering level
    and removed
    in triagePresently being triaged by the triage team
    on Mar 30, 2022
  11. 21 remaining items

  12. knopp commented on Mar 6, 2023

    @knopp
    Member

    A note to whomever will look into it deeper: Esp. from the skia team.

    Apple's emoji picker produces many unqualified by UCD two codepoints sequences, where standard says 'FE0F' is mandated, and Apple's picker produces single emoji codepoint. Examples:

    invalid sequence |⏸| 23F8. Should be 23F8 FE0F. Omitted!
    invalid sequence |⏹| 23F9. Should be 23F9 FE0F. Omitted!
    invalid sequence |⏺| 23FA. Should be 23FA FE0F. Omitted!
    invalid sequence |⏭| 23ED. Should be 23ED FE0F. Omitted!
    invalid sequence |⏮| 23EE. Should be 23EE FE0F. Omitted!
    

    (also recently macOS/iOS picker allows user to produce incompatible two-person ZWJ sequences, but that's not relevant here). Cc: skia bugtracker

    This is not quite my experience. For example for the "stop" the emoji picker can provide both ⏹️ (which as the FE0F selector) and ⏹ which doesn't. But for fast forward (⏩) it does omit the selector.

  13. EddieMataEwy commented on Aug 6, 2023

    @EddieMataEwy

    For people on Windows, setting familyFontFallback didn't work for me.
    What worked was setting app theme familyfont (you can also only set it for specific elements) to "Segoe UI Emoji". Normal text will still be rendered natively but emojis will now be rendered correctly.
    Flutter falls back to "Segoe UI Variant" for anything that is not an emoji I believe.

  14. gnprice commented on Jan 9, 2024

    @gnprice
    Member

    A previous thread on the same issue is #49627. A comment there (#49627 (comment)) by @JoshJuncker has a nice demonstration of how the order of emoji in a paragraph affects the issue:
    image

    (I think #100964 (comment) above explains why the order makes a difference.)

    That comment also reports that the issue is found on Android, in addition to the other platforms already mentioned in this thread.

  15. MichalNemec commented on Dec 10, 2024

    @MichalNemec

    macOS 14.6.1 (23G93)
    flutter

    Flutter 3.24.4 • channel stable • https://github.com/flutter/flutter.git
    Framework • revision 603104015d (7 weeks ago) • 2024-10-24 08:01:25 -0700
    Engine • revision db49896cf2
    Tools • Dart 3.5.4 • DevTools 2.37.3
    

    by using

    ThemeData(
        brightness: brightness,
        fontFamilyFallback: ['Apple Color Emoji'],
        useMaterial3: true,
      )

    in TextFormField i see black "red" heart.
    in Text i see black "red" heart.
    codeUnits are [9829, 65039]
    image

    image

    If i use fontFamily: 'Apple Color Emoji' then it works, but everything has super word spacing.
    It seems like fontFamilyFallback does not work at all? Tahoma works. So i guess there is a problem in .AppleSystemUIFont and Inter font downloaded manually.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work lista: desktopRunning on desktopa: typographyText rendering, possibly libtxtc: regressionIt was better in the past than it is nowc: renderingUI glitches reported at the engine/skia or impeller rendering levelcustomer: todofound in release: 2.12Found to occur in 2.12found in release: 2.13Found to occur in 2.13frameworkflutter/packages/flutter repository. See also f: labels.has reproducible stepsThe issue has been confirmed reproducible and is ready to work onplatform-androidAndroid applications specificallyplatform-iosiOS applications specificallyplatform-macosBuilding on or for macOS specificallyplatform-windowsBuilding on or for Windows specificallyteam-engineOwned by Engine teamtriaged-engineTriaged by Engine team

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions