{"version":3,"sources":["webpack:///./node_modules/lib-font/src/opentype/tables/simple/other/vmtx.js"],"names":["vmtx","constructor","dict","dataview","tables","p","super","numOfLongVerMetrics","vhea","numGlyphs","maxp","metricsStart","currentPosition","this","Array","map","_","LongVerMetric","uint16","int16","tsbStart","h","b","advanceHeight","topSideBearing"],"mappings":"2FAAA,8DAYA,MAAMA,UAAa,IACjBC,YAAYC,EAAMC,EAAUC,GAC1B,MACEC,EADaC,MAAMJ,EAAMC,GACdE,EACPE,EAAsBH,EAAOI,KAAKD,oBAClCE,EAAYL,EAAOM,KAAKD,UACxBE,EAAeN,EAAEO,gBAKvB,GAJA,YAAKC,KAAM,YAAY,KACrBR,EAAEO,gBAAkBD,EACb,IAAI,IAAIG,MAAMP,IAAsBQ,KAAIC,GAAK,IAAIC,EAAcZ,EAAEa,OAAQb,EAAEc,YAEhFZ,EAAsBE,EAAW,CACnC,MAAMW,EAAWT,EAAqC,EAAtBJ,EAChC,YAAKM,KAAM,mBAAmB,KAC5BR,EAAEO,gBAAkBQ,EACb,IAAI,IAAIN,MAAML,EAAYF,IAAsBQ,KAAIC,GAAKX,EAAEc,UAEtE,CACF,EAEF,MAAMF,EAEJhB,YAAYoB,EAAGC,GACbT,KAAKU,cAAgBF,EACrBR,KAAKW,eAAiBF,CACxB,E","file":"js/37-69495c7b64b2cc97daac.chunk.js","sourcesContent":["import { SimpleTable } from \"../../simple-table.js\";\nimport lazy from \"../../../../lazy.js\";\n\n/**\n * The OpenType `vmtx` table.\n *\n * See https://docs.microsoft.com/en-us/typography/opentype/spec/vmtx\n *\n * The overall structure of the vertical metrics table consists of two arrays:\n * a vMetrics array, followed by an array of top side bearings.\n *\n */\nclass vmtx extends SimpleTable {\n constructor(dict, dataview, tables) {\n const _super = super(dict, dataview),\n p = _super.p;\n const numOfLongVerMetrics = tables.vhea.numOfLongVerMetrics;\n const numGlyphs = tables.maxp.numGlyphs;\n const metricsStart = p.currentPosition;\n lazy(this, `vMetrics`, () => {\n p.currentPosition = metricsStart;\n return [...new Array(numOfLongVerMetrics)].map(_ => new LongVerMetric(p.uint16, p.int16));\n });\n if (numOfLongVerMetrics < numGlyphs) {\n const tsbStart = metricsStart + numOfLongVerMetrics * 4;\n lazy(this, `topSideBearings`, () => {\n p.currentPosition = tsbStart;\n return [...new Array(numGlyphs - numOfLongVerMetrics)].map(_ => p.int16);\n });\n }\n }\n}\nclass LongVerMetric {\n // https://learn.microsoft.com/en-us/typography/opentype/spec/vmtx#vertical-metrics-table-format\n constructor(h, b) {\n this.advanceHeight = h;\n this.topSideBearing = b;\n }\n}\nexport { vmtx };"],"sourceRoot":""}