|
1 | 1 | from fontbakery.callable import check
|
2 |
| -from fontbakery.status import FAIL, PASS |
| 2 | +from fontbakery.status import WARN, PASS |
3 | 3 | from fontbakery.message import Message
|
4 | 4 | # used to inform get_module_profile whether and how to create a profile
|
5 | 5 | from fontbakery.fonts_profile import profile_factory # NOQA pylint: disable=unused-import
|
|
9 | 9 | rationale = """
|
10 | 10 | Microsoft Office 2013 and below products expect fonts to have a digital signature declared in a DSIG table in order to implement OpenType features. The EOL date for Microsoft Office 2013 products is 4/11/2023. This issue does not impact Microsoft Office 2016 and above products.
|
11 | 11 |
|
12 |
| - This checks verifies that this signature is available in the font. |
| 12 | + As we approach the EOL date, it is now considered better to completely remove the table. |
13 | 13 |
|
14 |
| - A fake signature is enough to address this issue. If needed, a dummy table can be added to the font with the `gftools fix-dsig` script available at https://github.com/googlefonts/gftools |
| 14 | + But if you still want your font to support OpenType features on Office 2013, then you may find it handy to add a fake signature on a dummy DSIG table by running one of the helper scripts provided at https://github.com/googlefonts/gftools |
15 | 15 |
|
16 | 16 | Reference: https://github.com/googlefonts/fontbakery/issues/1845
|
17 | 17 | """,
|
18 |
| - proposal = 'legacy:check/045' |
| 18 | + proposal = ['legacy:check/045', |
| 19 | + 'https://github.com/googlefonts/fontbakery/issues/3398'] |
19 | 20 | )
|
20 | 21 | def com_google_fonts_check_dsig(ttFont):
|
21 | 22 | """Does the font have a DSIG table?"""
|
22 |
| - if "DSIG" in ttFont: |
23 |
| - yield PASS, "Digital Signature (DSIG) exists." |
| 23 | + if "DSIG" not in ttFont: |
| 24 | + yield PASS, "ok" |
24 | 25 | else:
|
25 |
| - yield FAIL,\ |
26 |
| - Message("lacks-signature", |
27 |
| - "This font lacks a digital signature (DSIG table)." |
28 |
| - " Some applications may require one (even if only a" |
29 |
| - " dummy placeholder) in order to work properly. You" |
30 |
| - " can add a DSIG table by running the" |
31 |
| - " `gftools fix-dsig` script.") |
| 26 | + yield WARN,\ |
| 27 | + Message("found-DSIG", |
| 28 | + "This font has a digital signature (DSIG table) which" |
| 29 | + " is only required - even if only a dummy placeholder" |
| 30 | + " - on old programs like MS Office 2013 in order to" |
| 31 | + " work properly.\n" |
| 32 | + "The current recommendation is to completely" |
| 33 | + " remove the DSIG table.") |
0 commit comments