Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chinese Font is render weird with FontWidget #26752

Closed
a396901990 opened this issue Jan 18, 2019 · 6 comments
Closed

Chinese Font is render weird with FontWidget #26752

a396901990 opened this issue Jan 18, 2019 · 6 comments
Labels
a: typography Text rendering, possibly libtxt engine flutter/engine repository. See also e: labels.

Comments

@a396901990
Copy link

a396901990 commented Jan 18, 2019

Steps to Reproduce

screen shot 2019-01-18 at 7 51 45 pm
screen shot 2019-01-18 at 7 54 46 pm
screen shot 2019-01-18 at 7 55 12 pm

code:

child: Text(
            team.destination,
            style: Theme.of(context).textTheme.title,
            overflow: TextOverflow.fade,
            softWrap: false,
            maxLines: 1,
          ),

// title style is redefined in custom theme using FontWeight.w500:
title: base.title.copyWith(
      fontSize: 18.0,
      fontWeight: FontWeight.w500,
      color: TColors.kTextPrimary,
    )

Flutter doctor

Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel master, v1.1.10-pre.117, on Mac OS X 10.14.1 18B75, locale en-CN)
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.2)
[!] iOS toolchain - develop for iOS devices (Xcode 10.1)
    ✗ libimobiledevice and ideviceinstaller are not installed. To install with Brew, run:
        brew update
        brew install --HEAD usbmuxd
        brew link usbmuxd
        brew install --HEAD libimobiledevice
        brew install ideviceinstaller
[✓] Android Studio (version 3.0)
[✓] VS Code (version 1.30.1)
[✓] Connected device (2 available)
@a396901990 a396901990 changed the title Chinese Font is render wired with FontWidget in Chinese Chinese Font is render wired with FontWidget Jan 18, 2019
@zoechi zoechi changed the title Chinese Font is render wired with FontWidget Chinese Font is render weird with FontWidget Jan 18, 2019
@zoechi
Copy link
Contributor

zoechi commented Jan 18, 2019

To investigate we would need a minimal runnable reproduction
as a single file so that we can just copy your code into lib/main.dart of a new project and run to reproduce.

@zoechi zoechi added engine flutter/engine repository. See also e: labels. a: typography Text rendering, possibly libtxt labels Jan 18, 2019
@zoechi zoechi added this to the Goals milestone Jan 18, 2019
@kangwang1988
Copy link
Contributor

kangwang1988 commented Jan 18, 2019

@a396901990
Try set a fontFamily for MaterialApp, e.g., "PingFang SC"(>=iOS9) or "STHeiti SC"(<iOS9).
I think it would resolve your issue.

@kangwang1988
Copy link
Contributor

Close #26752 as duple of #25726

@a396901990
Copy link
Author

Close #26752 as duple of #25726

Thanks @kangwang1988, set PingFang SC working for me.

@kangwang1988
Copy link
Contributor

@a396901990
Remember to set fontfamily for iOS9+ and below iOS8 seperately.
PingFang SC doesn't exist in iOS8.

flar pushed a commit that referenced this issue Jun 18, 2021
* 7e449ce Roll Skia from fab6ede2ec1d to 33da72d168d7 (24 revisions) (flutter/engine#26790)

* 9d2ab41 Fix windows keyboard: Extended key, delegate order (flutter/engine#26757)

* e3f4f2b Roll Dart SDK from 2084c5eeef79 to 914b1c6d1c88 (4 revisions) (flutter/engine#26792)

* 4754a23 Roll Skia from 33da72d168d7 to 491282486e34 (1 revision) (flutter/engine#26793)

* 6a7f1a9 Roll Skia from 491282486e34 to b2cb817d23d0 (4 revisions) (flutter/engine#26795)

* 42d391d Fix a leak of the resource EGL context on Android (flutter/engine#26789)

* 4f89b26 Roll Dart SDK from 914b1c6d1c88 to 369366069b83 (1 revision) (flutter/engine#26799)

* 6e9444b Roll Skia from b2cb817d23d0 to e8502cc73c5d (5 revisions) (flutter/engine#26801)

* 86dacc0 Revert "Support scrolling in iOS accessibility (#26671)" (flutter/engine#26803)

* 0cbaa80 Disable Skia reduceOpsTaskSplitting option (flutter/engine#26568)

* b9761b2 Roll Skia from e8502cc73c5d to 8e814b3be082 (6 revisions) (flutter/engine#26805)

* e274d31 Remove autoninja calls from the analyze script. (flutter/engine#26752)

* 399917c Revert "Remove autoninja calls from the analyze script. (#26752)" (flutter/engine#26812)

* b9616ca Roll Dart SDK from 369366069b83 to 0796dd6c7bcf (1 revision) (flutter/engine#26807)
@github-actions
Copy link

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a: typography Text rendering, possibly libtxt engine flutter/engine repository. See also e: labels.
Projects
None yet
Development

No branches or pull requests

3 participants