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

use opentype::truetype::Tag;

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

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

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