Skip to content

Commit 9e032d9

Browse files
author
Indrek Altpere
committed
Use the read-many helpers directly to avoid overhead
1 parent 18de7b3 commit 9e032d9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/FontLib/Table/Type/cmap.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,15 +64,15 @@ protected function _parse() {
6464
$segCount = $subtable["segCountX2"] / 2;
6565
$subtable["segCount"] = $segCount;
6666

67-
$endCode = $font->r(array(self::uint16, $segCount));
67+
$endCode = $font->readUInt16Many($segCount);
6868

6969
$font->readUInt16(); // reservedPad
7070

71-
$startCode = $font->r(array(self::uint16, $segCount));
72-
$idDelta = $font->r(array(self::int16, $segCount));
71+
$startCode = $font->readUInt16Many($segCount);
72+
$idDelta = $font->readInt16Many($segCount);
7373

7474
$ro_start = $font->pos();
75-
$idRangeOffset = $font->r(array(self::uint16, $segCount));
75+
$idRangeOffset = $font->readUInt16Many($segCount);
7676

7777
$glyphIndexArray = array();
7878
for ($i = 0; $i < $segCount; $i++) {

0 commit comments

Comments
 (0)