Bug 229179 - Some font doesn't render with font-variant-ligatures: none;
Summary: Some font doesn't render with font-variant-ligatures: none;
Status: RESOLVED DUPLICATE of bug 6274
Alias: None
Product: WebKit
Classification: Unclassified
Component: Text (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-08-16 23:02 PDT by Xidorn Quan
Modified: 2021-08-19 23:30 PDT (History)
2 users (show)

See Also:


Attachments
font with problem (47.88 KB, font/ttf)
2021-08-16 23:02 PDT, Xidorn Quan
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Xidorn Quan 2021-08-16 23:02:18 PDT
Created attachment 435665 [details]
font with problem

Steps to reproduce:
1. download the attached font file
2. create an HTML with the following code in the same directory and open it
<!DOCTYPE html>
<html>
<style>
  @font-face {
    font-family: "A";
    src: url(GilSBI30.woff);
  }
  p {
    font: 90px/1 A;
    font-variant-ligatures: none;
  }
</style>
<p><span>Hello world</span></p>
<p>Hello world</p>


Expected result:
It should render the text properly

Actual result:
The text is not rendered


It seems that the font has a bad font metrics with CoreText. In Safari 14, the first line wouldn't display even without `font-variant-ligatures: none;`, but this issue is fixed in the Technology Preview.
Comment 1 Radar WebKit Bug Importer 2021-08-17 09:59:34 PDT
<rdar://problem/82034235>
Comment 2 Myles C. Maxfield 2021-08-18 20:48:11 PDT
paintInfo.rect.intersects(snappedIntRect(overflowRect)) is returning false in LegacyInlineFlowBox::paint()
Comment 3 Myles C. Maxfield 2021-08-18 20:50:45 PDT
The LegacyRootInlineBox has 0 height
Comment 4 Myles C. Maxfield 2021-08-18 20:58:41 PDT
CTFontGetAscent() and CTFontGetDescent() are returning 0. This is a bug in Core Text.
Comment 5 Myles C. Maxfield 2021-08-19 23:30:32 PDT
The font has a broken 'hhea' table, it has zero values for ascender, descender, and lineGap.
Comment 6 Myles C. Maxfield 2021-08-19 23:30:54 PDT

*** This bug has been marked as a duplicate of bug 6274 ***