Files
NapCatQQ/.pnpm-store/v3/files/0d/2fb77b7566a42752d2eaa3c2ae19477b41e7df06bf7705da3a7e745e63855d342dd95f2649c44fe3f0fa76245f8171a40bc3bc0079b7354efe8dcf3ac78afb
T
TanTan e311ca3275
Build NapCat Artifacts / Type Check & Test (push) Waiting to run
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

32 lines
703 B
Plaintext

/**
* @file gasp 表
* 对于需要hinting的字号需要这个表,否则会导致错误
* @author mengke01(kekee000@gmail.com)
* reference: https://developer.apple.com/fonts/TrueType-Reference-Manual/RM06/Chap6gasp.html
*/
import table from './table';
export default table.create(
'gasp',
[],
{
read(reader, ttf) {
const length = ttf.tables.gasp.length;
return reader.readBytes(this.offset, length);
},
write(writer, ttf) {
if (ttf.gasp) {
writer.writeBytes(ttf.gasp, ttf.gasp.length);
}
},
size(ttf) {
return ttf.gasp ? ttf.gasp.length : 0;
}
}
);