Skip to content

Inconsistency of material fonts with canvaskit renderer (beta channel) #74605

@vmorilla

Description

@vmorilla

Steps to Reproduce

The following simple material app shows different fonts when using the canvaskit rendered for the web:

import 'package:flutter/material.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
        title: 'Flutter Demo',
        home: Scaffold(
            appBar: AppBar(title: Text("B flat is written B\u{266D}"))));
  }
}

The result shown when using the html renderer is this:
html

And this is result obtained with the canvaskit (please, mind the incorrect displaying of the unicode character for the music flat symbol):
canvaskit

I cannot see any relevant information in logs. Here's the log with the html renderer:
[+14611 ms] Waiting for connection from debug service on Chrome... (completed in 15,2s)
[   +1 ms] Synced 28.6MB.
[        ] <- accept
[        ] Caching compiled dill
[  +74 ms] Using Google Chrome 88.0.4324.96 

[+2122 ms] [CHROME]:2021-01-24 20:20:49.669 Google Chrome[19218:1452973] Error loading
/Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin:
dlopen(/Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin, 262): no suitable image found.  Did find:
[   +1 ms] [CHROME]:    /Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin: code signature in
(/Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin) not valid for use in process using Library Validation:
mapping process and mapped file (non-platform) have different Team IDs
[        ] [CHROME]:    /Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin: stat() failed with errno=9
[ +155 ms] [CHROME]:
[        ] [CHROME]:DevTools listening on ws://127.0.0.1:61741/devtools/browser/193568cc-e91c-4ab7-99e7-d886ee2a903d
[ +745 ms] DwdsInjector: Received request for entrypoint at http://localhost:61471/main_module.bootstrap.js
[   +9 ms] MetadataProvider: Loading debug metadata...
[  +14 ms] MetadataProvider: Loaded debug metadata
[  +16 ms] DwdsInjector: Injected debugging metadata for entrypoint at http://localhost:61471/main_module.bootstrap.js
[+1957 ms] DevHandler: Debug service listening on ws://127.0.0.1:61856/3DF5K40oYb8=/ws

[   +9 ms] Debug service listening on ws://127.0.0.1:61856/3DF5K40oYb8=/ws
[        ] Running with unsound null safety
[        ] For more information see https://dart.dev/null-safety/unsound-null-safety
[   +1 ms] Warning: Flutter's support for web development is not stable yet and hasn't
[        ] been thoroughly tested in production environments.
[        ] For more information see https://flutter.dev/web
[        ] 🔥  To hot restart changes while running, press "r" or "R".
[   +1 ms] For a more detailed help message, press "h". To quit, press "q".

And here's the one with CanvasKit:

[+13855 ms] Waiting for connection from debug service on Chrome... (completed in 14,4s)
[        ] Synced 28.6MB.
[        ] <- accept
[        ] Caching compiled dill
[  +86 ms] Using Google Chrome 88.0.4324.96 

[+2234 ms] [CHROME]:2021-01-24 20:23:53.787 Google Chrome[19729:1460290] Error loading
/Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin:
dlopen(/Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin, 262): no suitable image found.  Did find:
[   +1 ms] [CHROME]:    /Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin: code signature in
(/Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin) not valid for use in process using Library Validation:
mapping process and mapped file (non-platform) have different Team IDs
[        ] [CHROME]:    /Library/CoreMediaIO/Plug-Ins/DAL/XpressionPlugin.plugin/Contents/MacOS/XpressionPlugin: stat() failed with errno=9
[ +132 ms] [CHROME]:
[        ] [CHROME]:DevTools listening on ws://127.0.0.1:63920/devtools/browser/0583e713-116d-4d8d-8277-d761d5ed2d31
[ +740 ms] DwdsInjector: Received request for entrypoint at http://localhost:63629/main_module.bootstrap.js
[   +4 ms] MetadataProvider: Loading debug metadata...
[  +11 ms] MetadataProvider: Loaded debug metadata
[   +8 ms] DwdsInjector: Injected debugging metadata for entrypoint at http://localhost:63629/main_module.bootstrap.js
[+1835 ms] DevHandler: Debug service listening on ws://127.0.0.1:63957/PwCpGv0J53U=/ws

[   +8 ms] Debug service listening on ws://127.0.0.1:63957/PwCpGv0J53U=/ws
[        ] Running with unsound null safety
[        ] For more information see https://dart.dev/null-safety/unsound-null-safety
[   +2 ms] Warning: Flutter's support for web development is not stable yet and hasn't
[        ] been thoroughly tested in production environments.
[        ] For more information see https://flutter.dev/web
[        ] 🔥  To hot restart changes while running, press "r" or "R".
[   +1 ms] For a more detailed help message, press "h". To quit, press "q".

The output of flutter analyze follows:

Analyzing font_test...                                                  
No issues found! (ran in 2.4s)

And the output of flutter doctor -v:

[✓] Flutter (Channel beta, 1.25.0-8.3.pre, on macOS 11.1 20C69 darwin-x64, locale es-ES)
    • Flutter version 1.25.0-8.3.pre at /Users/vmorilla/devel/flutter
    • Framework revision 5d36f2e7f5 (10 days ago), 2021-01-14 15:57:49 -0800
    • Engine revision 7a8f8ca02c
    • Dart version 2.12.0 (build 2.12.0-133.7.beta)

[✓] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
    • Android SDK at /Users/vmorilla/Library/Android/sdk
    • Platform android-29, build-tools 29.0.2
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b01)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 12.3, Build version 12C33
    • CocoaPods version 1.10.0

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 3.4)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin version 183.6270
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b01)

[✓] VS Code (version 1.52.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.18.1

[✓] Connected device (1 available)
    • Chrome (web) • chrome • web-javascript • Google Chrome 88.0.4324.96
    ! Error: IPadi is not connected. Xcode will continue when IPadi is connected. (code -13)

• No issues found!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions