1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
use std::io::Result;

use opentype::truetype::Tag;
use typeface::Tape;

use crate::formats::opentype::cache::Cache;

/// Tables.
pub type Tables = Vec<Tag>;

pub(crate) fn read<T: Tape>(cache: &mut Cache<T>) -> Result<Tables> {
    Ok(cache
        .backend
        .offset_table
        .records
        .iter()
        .map(|record| record.tag)
        .collect())
}