Skip to content

Commit bccb423

Browse files
author
Indrek Altpere
committed
Use the new helpers in the BinaryStream itself
1 parent 26576c9 commit bccb423

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

src/FontLib/BinaryStream.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,18 @@ public function r($type) {
342342
if ($type[0] == self::char) {
343343
return $this->read($type[1]);
344344
}
345+
if ($type[0] == self::uint16) {
346+
return $this->readUInt16Many($type[1]);
347+
}
348+
if ($type[0] == self::int16) {
349+
return $this->readInt16Many($type[1]);
350+
}
351+
if ($type[0] == self::uint8) {
352+
return $this->readUInt8Many($type[1]);
353+
}
354+
if ($type[0] == self::int8) {
355+
return $this->readInt8Many($type[1]);
356+
}
345357

346358
$ret = array();
347359
for ($i = 0; $i < $type[1]; $i++) {

0 commit comments

Comments
 (0)