cpdf-source/cpdfspot.ml
John Whitington 0e9f35ab69 more
2021-12-19 13:26:15 +00:00

18 lines
370 B
OCaml

open Pdfutil
let print_spot_colour n s =
Printf.printf "%i %s\n" n s
let list_spot_colours pdf =
Pdf.objiter
(fun _ obj ->
match obj with
Pdf.Array (Pdf.Name "/Separation"::x::_) ->
begin match Pdf.direct pdf x with
Pdf.Name col -> Printf.printf "%s\n" col
| _ -> ()
end
| _ -> ())
pdf