Fix source + docs for v2.7.2

This commit is contained in:
John Whitington 2024-10-23 15:26:14 +01:00
parent 1be567759f
commit af11ff5bdd
8 changed files with 19 additions and 14 deletions

15
Changes
View File

@ -1,10 +1,4 @@
2.7.2 (to come)
Fixes:
o Removed setting of Producer field in AGPL version
* Removed long-deprecated -control
* More compact -print-struct-tree
2.7.2 (October 2024)
New features:
@ -13,7 +7,7 @@ New features:
* Create PDF/UA files from scratch with -create-pdf-ua-[1|2]
* Create structure information for files with -draw
* Draw can now make paragraphs with -para, -paras
* Add structure information to -typeset, add -subformat
* Add structure information to -typeset
* -typeset can make PDF/UA documents
* -jpeg, -png and friends can make PDF/UA documents
* Merge PDF/UA-1 and PDF/UA-2 files, preserving standards compliance
@ -22,10 +16,13 @@ o -redact removes whole pages
Extended features:
o Rectangle may be specified as x y x' y' rather than x y w h
o Rectangles may be specified as x y x' y' rather than x y w h
Fixes:
o Removed setting of Producer field in AGPL version
* Removed long-deprecated -control
* More compact -print-struct-tree
o -image-resolution-json was listing all images
* = Supported by a grant from NLnet

2
META
View File

@ -1,6 +1,6 @@
name="cpdf"
description="PDF commmand line tools"
version="2.7.1"
version="2.7.2"
requires="camlpdf"
archive(byte)="cpdf.cma"
archive(native)="cpdf.cmxa"

View File

@ -47,7 +47,7 @@ To build
--------
If downloading from Github, obtain the correct source. This means choosing the
tag for a particular version, such as "v2.7". The head of the master branch
tag for a particular version, such as "v2.7.2". The head of the master branch
is unstable.
1. Type `make` to make the cpdf executable and the library

View File

@ -1,6 +1,6 @@
opam-version: "2.0"
name: "cpdf"
version: "2.7.1"
version: "2.7.2"
maintainer: "contact@coherentgraphics.co.uk"
license: "AGPL-3.0-or-later"
build: [[make]]

View File

@ -64,11 +64,13 @@ type drawops =
| EndEltInfo of string
| AutoTag of bool
(** When this is set, any untagged material is tagged as an artifact. *)
val do_add_artifacts : bool ref
(** Set the role map. *)
val rolemap : string ref
(** Calling [draw fast underneath filename bates batespad range pdf drawops] draws on
(** Calling [draw struct_tree fast underneath filename bates batespad range pdf drawops] draws on
top of all the pages in the range. *)
val draw : struct_tree:bool ->
fast:bool ->

View File

@ -33,4 +33,5 @@ val validate_pagespec : string -> bool
x-y ranges etc. *)
val string_of_pagespec : Pdf.t -> int list -> string
(** Invert a range, given the maximum page number and the range. *)
val invert_range : int -> int list -> int list

View File

@ -23,7 +23,9 @@ val font_widths : string -> Pdftext.font -> float -> float array
(** Calculate the widths of a string given a font width table, and list of char codes *)
val width_of_string : float array -> char list -> float
(** [typeset lmargin rmargin tmargin bmargin papersize pdf contents] builds a list of pages of typset content. *)
(** [typeset process_struct_tree lmargin rmargin tmargin bmargin papersize pdf contents] builds a
list of pages of typset content. *)
val typeset : process_struct_tree:bool -> float -> float -> float -> float -> Pdfpaper.t -> Pdf.t -> t -> Pdfpage.t list * (string * int) list list
(** Add artifact markers to any un-marked part of the content stream. *)
val add_artifacts : Pdfops.t list -> Pdfops.t list

View File

@ -4,6 +4,7 @@ type subformat =
| PDFUA1
| PDFUA2
(** Parse PDF/UA-1 and PDF/UA-2 to the subformat type. *)
val subformat_of_string : string -> subformat
(** Print matterhorn test results ("" = all tests) *)
@ -30,6 +31,8 @@ val extract_struct_tree : Pdf.t -> Cpdfyojson.Safe.t
(** Reapply an edited JSON structure tree to its PDF. *)
val replace_struct_tree : Pdf.t -> Cpdfyojson.Safe.t -> unit
(* Make a blank PDF/UA-1 PDF given a title, paper size, and number of pages. *)
val create_pdfua1 : string -> Pdfpaper.t -> int -> Pdf.t
(* Make a blank PDF/UA-2 PDF given a title, paper size, and number of pages. *)
val create_pdfua2 : string -> Pdfpaper.t -> int -> Pdf.t