Skip to content

Instantly share code, notes, and snippets.

View geniuszxy's full-sized avatar
🍋
Focusing

Shingo geniuszxy

🍋
Focusing
View GitHub Profile
@geniuszxy
geniuszxy / CGFontToFontData.m
Created October 24, 2020 04:36 — forked from Bokugene/CGFontToFontData.m
Read Table Data from a CGFont, then wrap them into a OTF/TTF font.
typedef struct FontHeader {
int32_t fVersion;
uint16_t fNumTables;
uint16_t fSearchRange;
uint16_t fEntrySelector;
uint16_t fRangeShift;
}FontHeader;
typedef struct TableEntry {
uint32_t fTag;