moonbitlang/pdflite/font/afm does not have a README file

    PdfBytes

    type PdfBytes = Bytes

    PDF byte strings and byte streams.

    This is an alias for MoonBit Bytes because PDF strings and streams are byte sequences, not Unicode text. Use String only after an explicit PDF text decoding step.

    PdfError

    Error variants raised by pdflite parsing, writing, filtering, text, and encryption APIs.

    The variants intentionally stay specific enough for tests and callers to distinguish malformed input classes, while most public APIs expose them through the ordinary raise PdfError flow.

    PdfAfmData

    pub(all) struct PdfAfmData {
    headers : Array[(Bytes, Bytes)]
    char_metrics : Array[(Int, Int)]
    kerns : Array[(Int, Int, Int)]
    char_name_widths : Array[(Bytes, Int)]
    } derive(Eq, ToJson,
    Debug
    )

    Parsed Adobe Font Metrics data used by standard-font helpers.

    Headers preserve raw key/value bytes. Character metrics store character codes and widths, kerns store pair adjustments, and char_name_widths preserves name-based widths for encodings that refer to glyph names.

    PdfAfmData::equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfAfmData::equal(PdfAfmData, PdfAfmData) -> Bool

    PdfAfmData::not_equal

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfAfmData::not_equal(x : PdfAfmData, y : PdfAfmData) -> Bool

    PdfAfmData::to_json

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfAfmData::to_json(PdfAfmData) -> Json

    PdfAfmData::to_repr

    #deprecated("implicit trait-method promotion is being removed; call via the trait")
    fn PdfAfmData::to_repr(PdfAfmData) ->
    Repr

    pdf_afm_parse_int

    fn pdf_afm_parse_int(token : BytesView) -> Int raise
    PdfError

    Parse a signed AFM integer token.

    pdf_afm_view_equals

    fn pdf_afm_view_equals(left : BytesView, right : BytesView) -> Bool

    Return whether two byte views contain the same bytes.

    pdf_read_afm

    fn pdf_read_afm(data : BytesView) -> PdfAfmData raise
    PdfError

    Parses Adobe Font Metrics data from bytes.

    The parser extracts top-level headers, character widths, name-width pairs, and kerning pairs. Raises PdfError::AfmExpected or PdfError::NumberExpected for malformed metric sections.