Skip to content

[makeotf] will accept malformed MacRoman strings #1801

@frankrolf

Description

@frankrolf

In a test project, I specified the designer name of a font as ßłü.
RoboFont can generate fonts using the FDK, and can also write FDK artifacts when generating. In the resulting name table (presumably written by ufo2fdk) I get the following override:

table name {
    nameid 9 "\00DF\0142\00FC";
    nameid 9 1 "\A7\0142\9F";
} name;

Attentive readers will notice that the MacRoman string is invalid (containing a UTF-8 escape).
The problem is that makeotf generates the font without complaining.

Dumping the resulting font with ttx, we get

WARNING: Illegal XML character(s) found; replacing offending string "'ß\\x0142ü'" with '?'

    <namerecord nameID="9" platformID="1" platEncID="0" langID="0x0" unicode="True">
      ß?42ü
    </namerecord>

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions