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

Using double text decoration stikethrough on some devices #27392

Closed
229106948 opened this issue Feb 1, 2019 · 9 comments
Closed

Using double text decoration stikethrough on some devices #27392

229106948 opened this issue Feb 1, 2019 · 9 comments
Labels
a: internationalization Supporting other languages or locales. (aka i18n) a: typography Text rendering, possibly libtxt engine flutter/engine repository. See also e: labels. P2 Important issues not at the top of the work list

Comments

@229106948
Copy link

229106948 commented Feb 1, 2019

I use Text for example:

new Text(
                                miaoSha.price,
                                style: new TextStyle(
                                    color: new Color(0xff999999),
                                    decoration: TextDecoration.lineThrough,                                  
                                    decorationStyle: TextDecorationStyle.solid,
                                    fontSize: 14),
                              ),

but the line is double in my phone, other's phone is single.

@Kartik1607
Copy link
Contributor

Kartik1607 commented Feb 1, 2019

Which phone are you using? Can you post a screenshot?

@229106948
Copy link
Author

229106948 commented Feb 2, 2019

Which phone are you using? Can you post a screenshot?

oppo and htc also has the problem,xiaomi is normal.
image

@229106948
Copy link
Author

Which phone are you using? Can you post a screenshot?

oppo and htc also has the problem,xiaomi is normal.

xiaomi:
image

@229106948
Copy link
Author

Which phone are you using? Can you post a screenshot?

I discover the text is not support chinese mix english

@GaryQian GaryQian added engine flutter/engine repository. See also e: labels. a: internationalization Supporting other languages or locales. (aka i18n) a: typography Text rendering, possibly libtxt labels Feb 6, 2019
@GaryQian
Copy link
Contributor

GaryQian commented Feb 6, 2019

It looks like the span of text is broken into two runs: the ¥ and the 8.9

Since these two are rendered separately by different fonts, the alignment of their strikethrough height is off.

Whether this problem appears or not depends on the implementation of the fonts on each device.

One solution is to use your own font that supports all of the glyphs and symbols.

There is also a bug here where the strikethough (as well as other decorations) are drawn across the entire width of the span even if they were broken up into multiple runs.

@GaryQian
Copy link
Contributor

GaryQian commented Feb 6, 2019

This is related to #24337 where the background is drawn over multiple runs.

@zoechi zoechi added this to the Goals milestone Feb 12, 2019
@jmagman jmagman added this to Awaiting triage in Mobile - text review Feb 28, 2020
@GaryQian GaryQian moved this from Awaiting triage to Engineer reviewed in Mobile - text review Apr 23, 2020
@GaryQian GaryQian changed the title Text bug Using double text decoration stikethrough on some devices Apr 23, 2020
@kf6gpe kf6gpe added the P2 Important issues not at the top of the work list label May 29, 2020
@Hixie Hixie removed this from the None. milestone Aug 17, 2020
@darshankawar
Copy link
Member

darshankawar commented Dec 2, 2020

@229106948
Is this still a valid issue using latest Flutter version or has this been resolved ?

@darshankawar darshankawar added the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Dec 2, 2020
@pedromassangocode
Copy link

Without additional information, we are unfortunately not sure how to resolve this issue.
We are therefore reluctantly going to close this bug for now.
Please don't hesitate to comment on the bug if you have any more information for us; we will reopen it right away!
Thanks for your contribution.

Could everyone who still has this problem please file a new issue with the exact description of what happens, logs, and the output of flutter doctor -v.
All system setups can be slightly different, so it's always better to open new issues and reference related issues.

@pedromassangocode pedromassangocode removed the waiting for customer response The Flutter team cannot make further progress on this issue until the original reporter responds label Dec 23, 2020
@github-actions
Copy link

github-actions bot commented Aug 8, 2021

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 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
a: internationalization Supporting other languages or locales. (aka i18n) a: typography Text rendering, possibly libtxt engine flutter/engine repository. See also e: labels. P2 Important issues not at the top of the work list
Projects
Mobile - text review
  
Engineer reviewed
Development

No branches or pull requests

8 participants