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

Fix font fallback Safari 10 for iOS #402

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

dengjeffrey
Copy link

What this PR tries to accomplish

How it accomplishes them

Partially fixes #365, for the iOS portion.

  • Add Safari 10 to the fallback bug check.
  • Create a FontRuler for a mock font with the same styling and record the width as a lastResortWidth.
  • Since the fallback bug is present, the font will be considered loaded when the font width does not match any of the widths in lastResortWidth

Extend coverage of #352 for iOS devices running Safari 10.

  • Match on AppleWebKit version to determine if webkit version is equivalent to the one used in Safari 10

this.started_ = goog.now();
if (FontWatchRunner.hasWebKitFallbackBug()) {
this.lastResortWidths_[FontWatchRunner.LastResortFonts.MOCK_FONT] = this.getMockFontWidth_();
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

diff gets a bit confused here because you've removed an empty line after this.started_ = goog.now();

@dengjeffrey dengjeffrey force-pushed the fix/font-fallback-safari branch from 837fc3f to cb19ba4 Compare May 30, 2018 14:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Font families might not really loaded in WebKit based browsers in specific networks conditions
2 participants