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

Line spacing/vertical metrics approach discussion thread #2

Closed
chrissimpkins opened this issue Mar 26, 2016 · 22 comments
Closed

Line spacing/vertical metrics approach discussion thread #2

chrissimpkins opened this issue Mar 26, 2016 · 22 comments

Comments

@chrissimpkins
Copy link
Member

@davelab6 @kenlunde

Be interested in your expertise & thoughts about the approach that we are using to set and modify the line spacing/internal leading in fonts with this tool. Vertical metrics modifications have been a common request among developers who use the Hack typeface because few text editors aimed at developers currently support line spacing adjustments. We are restricted to modification of the font files in order to broadly support tighter and looser line spacing. While highly subjective, the issue matters to developers because some like to fit as much code into a view as humanly possible (the small font size, tightly line spaced crowd) and others want improved legibility that comes with additional whitespace between lines.

I based our vertical metrics modifications approach on Karsten Lücke's approach defined here.

The details of the OpenType table metrics changes are in the project README file here and the calculations are performed in the modify_linegap_percent() function defined in this module.

@kenlunde
Copy link

The approach that I took for Version 1.003 and beyond of Source Han Sans and Noto Sans CJK involved 1) setting OS/2.sTypoAscender (880) and OS/2.sTypoDescender (-120) so that their sum equals the UPM (1000), which also represents the CJK em-box in which the glyphs for ideographs, kana, hangul, and other full-width symbols are optically centered; 2) setting both OS/2.sTypoLineGap and hhea.LineGap to 0 (zero); and 3) setting OS/2.usWinAscent/hhea.Ascender and OS/2.usWinDescent/hhea.Descender in a harmonized way that a) involves factoring out glyphs that are unusually tall and are used only in vertical writing, such as U+3031 and U+3032, along with the vertical forms of U+2E3A, U+2E3B, and U+302A through U+302D; and b) using the highest values across all weights for this purpose. This is described in the Source Han Sans ReadMe (the PDF will download if clicked) file (see the 'OS/2' Table Overrides section on page 15). Anyway, this gave us the best results.

@chrissimpkins
Copy link
Member Author

@kenlunde Thank you very much Ken. I really appreciate this feedback. How does your team perform cross platform testing of the rendering of these vertical metrics? Is this all manual across a number of different text rendering applications/environments in Windows, OS X, and Linux or are there available tools to examine this?

The use of zero height for the OS/2.sTypoLineGap and hhea.LineGap seems to be a common approach as well based upon inspection of a number of typefaces (I noticed this in Source Code Pro and a number of other professionally designed faces). Is there a benefit to this over the use of a value in the OS/2.sTypoLineGap field on one of the OS's? For those who want to override the intended line space design in a typeface, do you feel that it is better to modify the leading in the OS/2.usWinAscent/hhea.Ascender and OS/2.usWinDescent/hhea.Descender fields and leave the OS/2.sTypoLineGap at 0? Aside from clipping issues, are there any other potential side effects that might happen with this? The multiple properties and different platform/application specific approaches eliminate any semblance of clarity with this issue.

@chrissimpkins
Copy link
Member Author

For my future reference, the description of the OS/2 table mods in Source Han Sans is on page 15 of the pdf linked by @kenlunde in #2 (comment)

@chrissimpkins
Copy link
Member Author

As an aside, it also seems that the use of OS/2.sTypoLineGap = 0 is recommended for web fonts. (#1)

@chrissimpkins chrissimpkins changed the title Line spacing metrics approach discussion / debate thread Line spacing/vertical metrics approach discussion thread Mar 27, 2016
@chrissimpkins
Copy link
Member Author

@typesupply @benkiel

Tal and Ben, do you happen to have any insight/thoughts about the most optimal cross-platform approach to OpenType vertical metrics on the desktop and web? We are developing an open source OT vertical metric reporting + post-build modification tool. I'd be interested in your experience, current approach, and thoughts about our (yet very early and open to modification) approach here.

See the top post for the impetus.

@davelab6
Copy link

https://github.com/googlefonts/gf-docs/blob/master/VerticalMetricsRecommendations.md is the original research by Raph Levien on this from about 5 years ago; basically the conclusion is that each of the 3 sets of ascent/decent values should be the same, the ymax and ymin of the family, and both linegaps should be zero.

FontBakery has a reporting method and a autofixing method that is very similar to the code you have here.

@chrissimpkins
Copy link
Member Author

@davelab6

This article was extremely helpful Dave. It looks like the web font approach differs from that on the desktop/print side. Is there a reason why this approach is not broadly used in many typefaces out there that are designed for the screen? I took a look through a large number of system fonts on OS X, and a variety of non-system fonts used in coding. Many/most use either the approach that I started with here or one like @kenlunde described above with TypoAscender and TypoDescender set to the UPM size, spacing added to the hhea Asc/Desc and OS/2 winAsc/winDesc values (without a consistent pattern, some add more space above and some equal space above and below) and both OS/2.linegap and hhea.linegap values set to zero. Some notable examples use a TypoDescender to TypoAscender height that is less than the UPM size oddly enough (namely Times New Roman, Georgia, and Courier New system font builds on OS X 10.11.4). Unfortunately, this is all anecdotal and it would be nice to have a more systematic review of how these changes look in commonly used editors across Windows, OS X, and at least one commonly used Linux distro, similar to the treatment on the web browser side.

Here are some of the salient points (for me) that I pulled out of the document that you linked. I am adding them here for my future reference.

For creating fonts: definitely make sure usWinAscent and usWinDescent values include the bounding box of all glyphs in the font, as anything falling outside will be clipped. Do make sure that usWinAscent values matches hhea Ascender and sTypoAscender (same for Descent). Do use zero values for hhea LineGap and sTypoLineGap (in general, we’ll want any excess budget to be reserved for additional accents, and also it’s quite difficult to make line gaps consistent).

Add to the vertical space budget. Note that the ascent and descent values will almost always need to increase, otherwise there will be clipping. In this case, do add equally to ascent and descent. This way, baseline positioning won’t be affected in the case that line-height is set.

These cross-platform x browser images are very helpful: http://levien.com/webfonts/vmtx/

As is this summary of the findings: https://github.com/googlefonts/gf-docs/blob/master/VerticalMetricsRecommendations.md#detailed-analysis-of-browser-testing

I'm sure that this tool duplicates functionality that has been previously developed. This was built primarily as a tool to support simple vertical metrics modifications in our fonts (and other fonts used in situations where the default line spacing cannot be adjusted programmatically on the renderer side) as we have a number of issue reports open with requests for wider and narrower line spacing. This is simply the toothpick from the Swiss army knife that is Font Bakery and I am quite certain that I would receive some blowback if I asked our users to do the following in order to modify line spacing ;)

dependencies

@benkiel
Copy link

benkiel commented Mar 28, 2016

What I do for web fonts is different than for print fonts.

For web fonts, what @davelab6 pointed to is what I do. You want line heights to be consistent between browsers, this does that.

For print/desktop fonts, your concerns are different. I do pretty much what @kenlunde described. The hhea and win values take care of clipping in Word, and the Typo values give you the desired vertical metrics in design applications. How you handle the Typo values depends on the font's design, and will likely not align with an actual height of a character in the font. You're picking values that are rational for the design, not mathematical.

@chrissimpkins
Copy link
Member Author

@benkiel Thank you very much for this feedback Ben. I really appreciate it.

Can you clarify what you mean in this comment?

How you handle the Typo values depends on the font's design, and will likely not align with an actual height of a character in the font

What aspect of design do you use to define this relationship?

Do you have recommendations for how one might safely place control of these metrics in the user's hands? The goal here is in part to settle on an acceptable strategy for these definitions, but also to permit those who we will assume know nothing about these issues to modify these values in a way that the typeface appears satisfactory without significantly compromising the design. I understand that this is, perhaps, unacceptable from a design purist standpoint but I would like to try to develop a strategy that empowers users to make the typeface more usable/functional for themselves in situations where editors do not permit line spacing adjustments. This situation is not unusual in the current era of source code editors. Fortunately, the ASCII set comprises the vast majority of glyph use there so we are not dealing with a great deal of outlier points. This will without doubt significantly impact glyph sets that rely on vertical relationships across lines (e.g. the block element glyphs and box drawing glyphs) and potentially glyphs that extend far above or below the confines of the Ascender and Descender if the spacing is tightened. The tool comes packaged with this warning :)

I wonder to what degree the conventions in browsers, design applications, and Word that we've discussed so far apply to commonly used source code editors. If knowledge of this is out there, I haven't been able to dig it up to date.

@chrissimpkins
Copy link
Member Author

Is there a simple way to identify the ymax and ymin in the OpenType tables? Is this value captured during builds in a field? If so, I can safeguard against clipping by restricting the spacing reduction to the point where black meets black.

@kenlunde
Copy link

There are head.yMin and head.yMax in the 'head' table.

@chrissimpkins
Copy link
Member Author

@kenlunde 👍 thank you!

@kenlunde
Copy link

To add to the discussion with regard to the sTypoAscender and sTypoDescender values in the 'OS/2' table, while I cannot speak with any authority to non-CJK fonts, at least for CJK fonts I feel somewhat strongly that these values 1) add up to equal the UPM and 2) correspond to the top and bottom of the ideographic em-box in which CJK glyphs are optically centered. For the other vertical metrics values, I see little or no disagreement.

@benkiel
Copy link

benkiel commented Mar 28, 2016

Agree with @kenlunde about the Typo values. They should sum to the UPM, they should not clip key characters (i.e., don't allow them to be less than the cap height or higher than the lowercase g) and they should be rational (sTypoDescender should be less than sTypoAscender). For latin fonts there isn't the issue of centering the way CJK has. sTypoLinegap will be the result of adding the absolute values of the hhea ascender & descender values, minus the UPM. If this number is exceptionally large —i.e., way over 120% of the UPM, then you may want to force it to be less. This will cause clipping on the exceptionally large glyphs, but is reasonable not to have a huge linegap. For fonts on a 1000 UPM, I start to edit if the sTypoLinegap is greater than 325 (depending on the design, script typefaces will tend to have a larger line gaps than other designs).

@chrissimpkins
Copy link
Member Author

@kenlunde Noted. Thank you very much Ken. It seems that you and @benkiel are in agreement about this approach for screen/print use. Do you use the same approach with CJK web fonts?

@benkiel Thanks for the clarification. I was under the impression that you were setting s.TypoLinegap to 0 but it sounds as though you are using a strategy that is similar to what I started with here. These upper and lower limits are very helpful too. Thanks for all of this information!

@davelab6
Copy link

davelab6 commented Mar 28, 2016 via email

@chrissimpkins
Copy link
Member Author

@davelab6 Thanks Dave! I forgot about that article. I definitely agree with Rainer's sentiments re: vertical metrics:

Whoa. And now, for a coffee break. Or some ice cream. Or both.

I will take a good look through all of the metrics suggestions in that article and here in this thread again this evening. Thanks for all of the input!

@kenlunde
Copy link

@chrissimpkins: Someone else at Adobe can correct me if I am wrong, but we prefer to have uniform vertical metrics for web and desktop use. Our fonts started off using desktop vertical metrics, because that was the primary use case. Now that fonts are much more easily used on the web, it is now a very strong use case, and in some ways, stronger than desktop use. It doesn't make sense to have separate fonts for desktop and web use, especially if the fonts have a large footprint (CJK).

@davelab6
Copy link

davelab6 commented Mar 28, 2016 via email

@kenlunde
Copy link

Going one step further, one phenomenon that I have observed is that fonts that include vertical metrics that are meant to work for web use generally work well for desktop use, but not vice-versa.

@chrissimpkins
Copy link
Member Author

@davelab6 @kenlunde Thank you very much Dave and Ken. Still tossing around how to handle the defaults here. I think that I am going to simply support manual modifications of these values for those who would like to script changes to meet the metrics that they would like.

@chrissimpkins
Copy link
Member Author

Based upon the conversation and multiple approaches described/discussed here:

As of v0.6.0, I am deferring to and maintaining the original font metrics design for vertical metrics changes with the percent command. The "Google Fonts", "Adobe Fonts", and original default approach are all supported now. The tool analyzes the approach used in the font before the modifications are performed and automates the changes to a user defined %UPM line spacing value. This addresses issue #6 and supports all of the different approaches that you are using based upon the conversation here.

I will add support for manual modification of the individual metrics values from the command line in a future version.

nooriro added a commit to nooriro/nooriro.github.io that referenced this issue Apr 4, 2023
Inconsistent line height on Chrome/Firefox for Android
is due to wrong vertical metrics
of the Charter font files from the link below:
https://practicaltypography.com/charter.html

The font files have positive descender values but those values
should be NEGATIVE. (See References [1], [2] and others.)
- `descender`      field in `hhea` table
- `sTypoDescender` field in `OS/2` table

Table   Field Name      Field Value         Should Be
-----   -------------   -----------------   ---------
head    unitsPerEm      1000
hhea    ascender        980
        descender       236                 -236
        lineGap         0
OS/2    sTypoAscender   760
        sTypoDescender  240                 -240
        sTypoLineGap    216
        usWinAscent     980
        usWinDescent    236
        fsSelection     00000000 01000000

So I've made a program which fixes those values (and checksums)
in Charter otf/ttf file to resolve the line height issue.

References:
[1] https://glyphsapp.com/learn/vertical-metrics
    via https://stackoverflow.com/questions/2854028/mac-vs-windows-browser-font-height-rendering-issue
[2] https://googlefonts.github.io/gf-guide/metrics.html
    via googlefonts/googlefonts.github.io#45
    and source-foundry/font-line#2
[3] 1. https://learn.microsoft.com/en-us/typography/opentype/spec/otff
    2. https://learn.microsoft.com/en-us/typography/opentype/spec/head
    3. https://learn.microsoft.com/en-us/typography/opentype/spec/hhea
    4. https://learn.microsoft.com/en-us/typography/opentype/spec/os2

Terminal output of program:

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Regular.otf
sfntVersion: 4F54544F  numTables: 000B
 - tableTag: 43464620 (CFF )  checksum: EA4DC1AF  offset: 00000BB8  length: 000082A3
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 00009734  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: E82FF7B3  offset: 000091F0  length: 00000542
 - tableTag: 4F532F32 (OS/2)  checksum: 8B297EE1  offset: 00000120  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 0000088C  length: 0000030C
 - tableTag: 68656164 (head)  checksum: 1B64CC47  offset: 000000BC  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 07DC05FC  offset: 000000F4  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: ED592734  offset: 00008E5C  length: 00000394
 - tableTag: 6D617870 (maxp)  checksum: 00E55000  offset: 00000118  length: 00000006
 - tableTag: 6E616D65 (name)  checksum: 619A5B30  offset: 00000180  length: 0000070B
 - tableTag: 706F7374 (post)  checksum: FF6E003A  offset: 00000B98  length: 00000020
offset 000000FA: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 00000166: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 00000070: checksum for 'hhea' table: 07DC05FC --> 07DD0424 (modified)
offset 00000040: checksum for 'OS/2' table: 8B297EE1 --> 8B2A7D01 (modified)
offset 00000060: checksum for 'head' table: 1B64CC47 --> 1B64CC47 (not modified)
offset 000000C4: 'checksumAdjustment' field in 'head' table: 14F57F8B --> 14F186FB (modified)

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Italic.otf
sfntVersion: 4F54544F  numTables: 000B
 - tableTag: 43464620 (CFF )  checksum: 5340C605  offset: 00000BD8  length: 000084CE
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 000099B4  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: F28802D2  offset: 0000943C  length: 00000578
 - tableTag: 4F532F32 (OS/2)  checksum: 8C2D7E6C  offset: 00000120  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 000008AC  length: 0000030C
 - tableTag: 68656164 (head)  checksum: 1B13CC53  offset: 000000BC  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 06C709A1  offset: 000000F4  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: E26B1300  offset: 000090A8  length: 00000394
 - tableTag: 6D617870 (maxp)  checksum: 00E55000  offset: 00000118  length: 00000006
 - tableTag: 6E616D65 (name)  checksum: 8CCC2E70  offset: 00000180  length: 0000072C
 - tableTag: 706F7374 (post)  checksum: FF79003A  offset: 00000BB8  length: 00000020
offset 000000FA: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 00000166: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 00000070: checksum for 'hhea' table: 06C709A1 --> 06C807C9 (modified)
offset 00000040: checksum for 'OS/2' table: 8C2D7E6C --> 8C2E7C8C (modified)
offset 00000060: checksum for 'head' table: 1B13CC53 --> 1B13CC53 (not modified)
offset 000000C4: 'checksumAdjustment' field in 'head' table: EE85D217 --> EE81D987 (modified)

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Bold.otf
sfntVersion: 4F54544F  numTables: 000B
 - tableTag: 43464620 (CFF )  checksum: D5E91E98  offset: 00000BC0  length: 00008365
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 00009984  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: 1CF31346  offset: 000092BC  length: 000006C8
 - tableTag: 4F532F32 (OS/2)  checksum: 8D5981F5  offset: 00000120  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 00000894  length: 0000030C
 - tableTag: 68656164 (head)  checksum: 1BA6CC3D  offset: 000000BC  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 081D0634  offset: 000000F4  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: FF6324F0  offset: 00008F28  length: 00000394
 - tableTag: 6D617870 (maxp)  checksum: 00E55000  offset: 00000118  length: 00000006
 - tableTag: 6E616D65 (name)  checksum: 3D47C34B  offset: 00000180  length: 00000714
 - tableTag: 706F7374 (post)  checksum: FF950054  offset: 00000BA0  length: 00000020
offset 000000FA: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 00000166: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 00000070: checksum for 'hhea' table: 081D0634 --> 081E045C (modified)
offset 00000040: checksum for 'OS/2' table: 8D5981F5 --> 8D5A8015 (modified)
offset 00000060: checksum for 'head' table: 1BA6CC3D --> 1BA6CC3D (not modified)
offset 000000C4: 'checksumAdjustment' field in 'head' table: F315B5DC --> F311BD4C (modified)

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Bold-Italic.otf
sfntVersion: 4F54544F  numTables: 000B
 - tableTag: 43464620 (CFF )  checksum: FAC135F0  offset: 00000C10  length: 000085AA
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 00009C5C  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: 145323A8  offset: 00009550  length: 0000070C
 - tableTag: 4F532F32 (OS/2)  checksum: 8D5E81C9  offset: 00000120  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 000008E4  length: 0000030C
 - tableTag: 68656164 (head)  checksum: 1B7DCC40  offset: 000000BC  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 07300A0A  offset: 000000F4  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: FA0F1322  offset: 000091BC  length: 00000394
 - tableTag: 6D617870 (maxp)  checksum: 00E55000  offset: 00000118  length: 00000006
 - tableTag: 6E616D65 (name)  checksum: 41042CB9  offset: 00000180  length: 00000762
 - tableTag: 706F7374 (post)  checksum: FFA00054  offset: 00000BF0  length: 00000020
offset 000000FA: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 00000166: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 00000070: checksum for 'hhea' table: 07300A0A --> 07310832 (modified)
offset 00000040: checksum for 'OS/2' table: 8D5E81C9 --> 8D5F7FE9 (modified)
offset 00000060: checksum for 'head' table: 1B7DCC40 --> 1B7DCC40 (not modified)
offset 000000C4: 'checksumAdjustment' field in 'head' table: BFE0A407 --> BFDCAB77 (modified)

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Regular.ttf
sfntVersion: 00010000  numTables: 0010
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 000088EC  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: E82FF7B3  offset: 0000010C  length: 00000542
 - tableTag: 4F532F32 (OS/2)  checksum: 8B297EE1  offset: 00000650  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 000006B0  length: 0000030C
 - tableTag: 63767420 (cvt )  checksum: 04D710EF  offset: 000079E0  length: 0000004A
 - tableTag: 6670676D (fpgm)  checksum: 622EFD7C  offset: 00007A2C  length: 00000E0C
 - tableTag: 67617370 (gasp)  checksum: 00000010  offset: 000079D8  length: 00000008
 - tableTag: 676C7966 (glyf)  checksum: 6CB82482  offset: 000009BC  length: 000060F0
 - tableTag: 68656164 (head)  checksum: 1B68CC48  offset: 00006AAC  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 07DC05FC  offset: 00006AE4  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: ED592734  offset: 00006B08  length: 00000394
 - tableTag: 6C6F6361 (loca)  checksum: FFCC1806  offset: 00006E9C  length: 000001CC
 - tableTag: 6D617870 (maxp)  checksum: 019E0E83  offset: 00007068  length: 00000020
 - tableTag: 6E616D65 (name)  checksum: E53144D9  offset: 00007088  length: 00000762
 - tableTag: 706F7374 (post)  checksum: 373135EF  offset: 000077EC  length: 000001EC
 - tableTag: 70726570 (prep)  checksum: D4BDD644  offset: 00008838  length: 000000B2
offset 00006AEA: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 00000696: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 000000A0: checksum for 'hhea' table: 07DC05FC --> 07DD0424 (modified)
offset 00000030: checksum for 'OS/2' table: 8B297EE1 --> 8B2A7D01 (modified)
offset 00000090: checksum for 'head' table: 1B68CC48 --> 1B68CC48 (not modified)
offset 00006AB4: 'checksumAdjustment' field in 'head' table: 3DCC5A00 --> 3DC86170 (modified)

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Italic.ttf
sfntVersion: 00010000  numTables: 0010
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 00009084  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: F28802D2  offset: 0000010C  length: 00000578
 - tableTag: 4F532F32 (OS/2)  checksum: 8C2D7E6C  offset: 00000684  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 000006E4  length: 0000030C
 - tableTag: 63767420 (cvt )  checksum: 04CF10D9  offset: 00008178  length: 0000004A
 - tableTag: 6670676D (fpgm)  checksum: 622EFD7C  offset: 000081C4  length: 00000E0C
 - tableTag: 67617370 (gasp)  checksum: 00000010  offset: 00008170  length: 00000008
 - tableTag: 676C7966 (glyf)  checksum: ADA4911C  offset: 000009F0  length: 00006846
 - tableTag: 68656164 (head)  checksum: 1B17CC54  offset: 00007238  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 06C709A1  offset: 00007270  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: E26B1300  offset: 00007294  length: 00000394
 - tableTag: 6C6F6361 (loca)  checksum: CD3CE745  offset: 00007628  length: 000001CC
 - tableTag: 6D617870 (maxp)  checksum: 019E0E87  offset: 000077F4  length: 00000020
 - tableTag: 6E616D65 (name)  checksum: E8A738C7  offset: 00007814  length: 0000076E
 - tableTag: 706F7374 (post)  checksum: 373C35EF  offset: 00007F84  length: 000001EC
 - tableTag: 70726570 (prep)  checksum: AABDD644  offset: 00008FD0  length: 000000B2
offset 00007276: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 000006CA: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 000000A0: checksum for 'hhea' table: 06C709A1 --> 06C807C9 (modified)
offset 00000030: checksum for 'OS/2' table: 8C2D7E6C --> 8C2E7C8C (modified)
offset 00000090: checksum for 'head' table: 1B17CC54 --> 1B17CC54 (not modified)
offset 00007240: 'checksumAdjustment' field in 'head' table: 700FA33C --> 700BAAAC (modified)

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Bold.ttf
sfntVersion: 00010000  numTables: 0010
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 00008A2C  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: 1CF31346  offset: 0000010C  length: 000006C8
 - tableTag: 4F532F32 (OS/2)  checksum: 8D5981F5  offset: 000007D4  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 00000834  length: 0000030C
 - tableTag: 63767420 (cvt )  checksum: 051E1134  offset: 00007B20  length: 0000004A
 - tableTag: 6670676D (fpgm)  checksum: 622EFD7C  offset: 00007B6C  length: 00000E0C
 - tableTag: 67617370 (gasp)  checksum: 00000010  offset: 00007B18  length: 00000008
 - tableTag: 676C7966 (glyf)  checksum: 72F17DAD  offset: 00000B40  length: 000060B6
 - tableTag: 68656164 (head)  checksum: 1BAACC3E  offset: 00006BF8  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 081D0634  offset: 00006C30  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: FF6324F0  offset: 00006C54  length: 00000394
 - tableTag: 6C6F6361 (loca)  checksum: FEA216EB  offset: 00006FE8  length: 000001CC
 - tableTag: 6D617870 (maxp)  checksum: 019E0E83  offset: 000071B4  length: 00000020
 - tableTag: 6E616D65 (name)  checksum: C22FA494  offset: 000071D4  length: 00000756
 - tableTag: 706F7374 (post)  checksum: 37583609  offset: 0000792C  length: 000001EC
 - tableTag: 70726570 (prep)  checksum: D4BDD644  offset: 00008978  length: 000000B2
offset 00006C36: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 0000081A: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 000000A0: checksum for 'hhea' table: 081D0634 --> 081E045C (modified)
offset 00000030: checksum for 'OS/2' table: 8D5981F5 --> 8D5A8015 (modified)
offset 00000090: checksum for 'head' table: 1BAACC3E --> 1BAACC3E (not modified)
offset 00006C00: 'checksumAdjustment' field in 'head' table: E5D49B76 --> E5D0A2E6 (modified)

nooriro@xps:/mnt/c/Users/nooriro/CLionProjects/untitled6/cmake-build-release-wsl$ ./untitled6 Charter-Bold-Italic.ttf
sfntVersion: 00010000  numTables: 0010
 - tableTag: 44534947 (DSIG)  checksum: 00000001  offset: 00009268  length: 00000008
 - tableTag: 47504F53 (GPOS)  checksum: 145323A8  offset: 0000010C  length: 0000070C
 - tableTag: 4F532F32 (OS/2)  checksum: 8D5E81C9  offset: 00000818  length: 00000060
 - tableTag: 636D6170 (cmap)  checksum: 52F054E4  offset: 00000878  length: 0000030C
 - tableTag: 63767420 (cvt )  checksum: 051A1127  offset: 0000835C  length: 0000004A
 - tableTag: 6670676D (fpgm)  checksum: 622EFD7C  offset: 000083A8  length: 00000E0C
 - tableTag: 67617370 (gasp)  checksum: 00000010  offset: 00008354  length: 00000008
 - tableTag: 676C7966 (glyf)  checksum: D1D1DDF2  offset: 00000B84  length: 00006864
 - tableTag: 68656164 (head)  checksum: 1B81CC40  offset: 000073E8  length: 00000036
 - tableTag: 68686561 (hhea)  checksum: 07300A0A  offset: 00007420  length: 00000024
 - tableTag: 686D7478 (hmtx)  checksum: FA0F1322  offset: 00007444  length: 00000394
 - tableTag: 6C6F6361 (loca)  checksum: C41ADE38  offset: 000077D8  length: 000001CC
 - tableTag: 6D617870 (maxp)  checksum: 019E0E86  offset: 000079A4  length: 00000020
 - tableTag: 6E616D65 (name)  checksum: 75795E75  offset: 000079C4  length: 000007A4
 - tableTag: 706F7374 (post)  checksum: 37633609  offset: 00008168  length: 000001EC
 - tableTag: 70726570 (prep)  checksum: AABDD644  offset: 000091B4  length: 000000B2
offset 00007426: 'descender'      field in 'hhea' table: 00EC (236) --> FF14 (-236) (modified)
offset 0000085E: 'sTypoDescender' field in 'OS/2' table: 00F0 (240) --> FF10 (-240) (modified)
offset 000000A0: checksum for 'hhea' table: 07300A0A --> 07310832 (modified)
offset 00000030: checksum for 'OS/2' table: 8D5E81C9 --> 8D5F7FE9 (modified)
offset 00000090: checksum for 'head' table: 1B81CC40 --> 1B81CC40 (not modified)
offset 000073F0: 'checksumAdjustment' field in 'head' table: A88A6A10 --> A8867180 (modified)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

4 participants