build_emoji: Remove `code_point_to_file_name_map()`.

We have symlinked the old emoji farm to the old emoji farm and hence
we don't use the images from the `NotoColorEmoji.ttf` file. This
function was used to generate a map from codepoint to filename by
parsing the ttx file passed to it. We no longer need this map.
This commit is contained in:
Harshit Bansal 2017-09-22 18:20:36 +00:00 committed by Tim Abbott
parent e295bed20f
commit 6ebacba425
1 changed files with 0 additions and 15 deletions

View File

@ -136,21 +136,6 @@ def bw_font(name, code_point):
'out/unicode/{}.png'.format(code_point), 'PNG'
)
def code_point_to_file_name_map(ttx):
# type: (str) -> Dict[int, Union[Text, bytes]]
"""Given the NotoColorEmoji.ttx file, parse it to generate a map from
codepoint to filename (a la glyph0****.png)
"""
result = {} # type: Dict[int, Union[Text, bytes]]
xml = ET.parse(ttx)
cmap = xml.find("*cmap_format_12")
assert cmap is not None
for elem in cmap:
code_point = int(elem.attrib["code"], 16)
fname = elem.attrib["name"]
result[code_point] = fname
return result
def main():
# type: () -> None