From ca2f5f16218d816ec31295a9de0204335907babb Mon Sep 17 00:00:00 2001 From: John Whitington Date: Tue, 4 Oct 2022 18:55:06 +0100 Subject: [PATCH] more --- cpdffont.ml | 2 +- cpdftruetype.ml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cpdffont.ml b/cpdffont.ml index 20959ef..d980975 100644 --- a/cpdffont.ml +++ b/cpdffont.ml @@ -201,7 +201,7 @@ let extract_fontfile pagenumber fontname pdf = match Pdf.lookup_direct pdf "/Font" resources with | None -> failwith "extract_fontfile: font not found" | Some fonts -> - let fontobj = Pdf.lookup_fail "no /Fonts" pdf fontname fonts in + let fontobj = Pdf.lookup_fail ("no font " ^ fontname) pdf fontname fonts in let font = Pdftext.read_font pdf fontobj in match font with | Pdftext.CIDKeyedFont (_, {Pdftext.cid_fontdescriptor = {Pdftext.fontfile = Some fontfile}}, _) diff --git a/cpdftruetype.ml b/cpdftruetype.ml index bb072b4..96b274e 100644 --- a/cpdftruetype.ml +++ b/cpdftruetype.ml @@ -299,9 +299,9 @@ let remove_unneeded_tables major minor tables indexToLocFormat subset encoding c Array.iter (fun (tag, _, _, _) -> if !dbg then Printf.printf "Writing %s table\n" (string_of_tag tag); - if string_of_tag tag = "loca" then + (*if string_of_tag tag = "loca" then write_loca_table subset cmap indexToLocFormat bs loca - else + else*) match findtag tag with | (og_off, Some len) -> let b = mk_b (i32toi og_off) in