2022-01-13 17:35:03 +01:00
(* * Adding text *)
2021-12-21 15:00:58 +01:00
2024-03-04 16:16:14 +01:00
(* * Colours *)
type colour =
2021-12-21 15:00:58 +01:00
Grey of float
| RGB of float * float * float
| CYMK of float * float * float * float
2024-03-04 16:16:14 +01:00
(* * Build a colour operation for filling with the given colour. *)
val colour_op : colour -> Pdfops . t
2021-12-21 15:00:58 +01:00
2024-03-04 16:16:14 +01:00
(* * Build a colour operation for filing with the given colour *)
val colour_op_stroke : colour -> Pdfops . t
2021-12-21 15:00:58 +01:00
(* * Justification of multiline text *)
type justification =
| LeftJustify
| CentreJustify
| RightJustify
2022-09-12 18:05:20 +02:00
(* * Call [add_texts linewidth outline fast fontname font bates batespad colour
2021-12-21 15:00:58 +01:00
position linespacing fontsize underneath text pages orientation
relative_to_cropbox midline_adjust topline filename pdf ] . For details see cpdfmanual . pdf * )
val addtexts :
float -> (* linewidth *)
bool -> (* outline *)
bool -> (* fast *)
string -> (* fontname *)
2022-10-19 17:32:56 +02:00
Cpdfembed . cpdffont -> (* font *)
2021-12-21 15:00:58 +01:00
int -> (* bates number *)
int option -> (* bates padding width *)
2024-03-04 16:16:14 +01:00
colour -> (* colour *)
2021-12-21 15:00:58 +01:00
Cpdfposition . position -> (* position *)
float -> (* linespacing *)
float -> (* fontsize *)
bool -> (* underneath *)
string -> (* text *)
int list -> (* page range *)
bool -> (* relative to cropbox? *)
float -> (* opacity *)
justification -> (* justification *)
bool -> (* midline adjust? *)
bool -> (* topline adjust? *)
string -> (* filename *)
float option -> (* extract_text_font_size *)
string -> (* shift *)
? raw : bool -> (* raw *)
Pdf . t -> (* pdf *)
Pdf . t
2023-07-27 14:21:15 +02:00
(* * Add a rectangle to the given pages. [addrectangle fast ( w, h ) colour outline linewidth opacity position relative_to_cropbox underneath range pdf]. *)
val addrectangle :
bool ->
float * float ->
2024-03-04 16:16:14 +01:00
colour ->
2023-07-27 14:21:15 +02:00
bool ->
float ->
float ->
Cpdfposition . position ->
bool -> bool -> int list -> Pdf . t -> Pdf . t
(* * / * *)
2023-05-01 17:19:09 +02:00
val replace_pairs :
Pdf . t ->
int ->
float option ->
string ->
int ->
int option -> int -> Pdfpage . t -> ( string * ( unit -> string ) ) list
val process_text :
Cpdfstrftime . t -> string -> ( string * ( unit -> string ) ) list -> string