package cpdf

  1. Overview
  2. Docs

Fonts

Listing fonts

val print_fonts : ?json:bool -> Pdf.t -> int list -> unit

Print font list to stdout

val list_fonts : Pdf.t -> int list -> (int * string * string * string * string) list

Return font list. Page number, name, subtype, basefont, encoding.

val json_fonts : Pdf.t -> int list -> Cpdfyojson.Safe.t

Return font list in JSON format

Miscellany

val embed_missing_fonts : string -> bool -> string -> string -> unit

Embed missing fonts

val copy_font : Pdf.t -> string -> int -> int list -> Pdf.t -> Pdf.t

Copy a font

val missing_fonts : ?l:(int * string * string * string * string) list ref -> Pdf.t -> int list -> unit

Report missing fonts

val missing_fonts_return : Pdf.t -> int list -> (int * string * string * string * string) list

Return missing fonts

val print_font_table : Pdf.t -> string -> int -> unit

Print a font table to Standard Output.

val extract_fontfile : int -> string -> string -> Pdf.t -> unit

Extract a font file to disk.

val remove_fonts : Pdf.t -> Pdf.t

Remove fonts from a document.

OCaml

Innovation. Community. Security.