mirror of
https://github.com/johnwhitington/cpdf-source.git
synced 2025-02-16 11:50:54 +01:00
Scaffolding for loadttf
This commit is contained in:
parent
88c6a12de6
commit
4482e11916
@ -1790,7 +1790,7 @@ let setfont f =
|
|||||||
begin match Pdftext.standard_font_of_name ("/" ^ f) with
|
begin match Pdftext.standard_font_of_name ("/" ^ f) with
|
||||||
| Some x -> StandardFont x
|
| Some x -> StandardFont x
|
||||||
| None ->
|
| None ->
|
||||||
if f <> "" && hd (explode f) <> '/' then error "Custom font names must begin with /";
|
if f <> "" && hd (explode f) <> '/' then error "Font not found";
|
||||||
OtherFont (convert f)
|
OtherFont (convert f)
|
||||||
end;
|
end;
|
||||||
args.fontname <-
|
args.fontname <-
|
||||||
|
@ -11,6 +11,8 @@ let setfontsize = ref (fun _ -> Printf.printf "BAD ******\n%!"; ())
|
|||||||
|
|
||||||
let ttfs = null_hash ()
|
let ttfs = null_hash ()
|
||||||
|
|
||||||
|
let loadttf name filename = ()
|
||||||
|
|
||||||
let fontpack_initialised = ref false
|
let fontpack_initialised = ref false
|
||||||
|
|
||||||
let drawops = ref [("_MAIN", [])]
|
let drawops = ref [("_MAIN", [])]
|
||||||
|
@ -5,6 +5,7 @@ val setfontname : (string -> unit) ref
|
|||||||
val setfontsize : (float -> unit) ref
|
val setfontsize : (float -> unit) ref
|
||||||
val setdrawing : (unit -> unit) ref
|
val setdrawing : (unit -> unit) ref
|
||||||
val ttfs : (string, (string * Cpdfembed.cpdffont)) Hashtbl.t
|
val ttfs : (string, (string * Cpdfembed.cpdffont)) Hashtbl.t
|
||||||
|
val loadttf : string -> string -> unit
|
||||||
val fontpack_initialised : bool ref
|
val fontpack_initialised : bool ref
|
||||||
val drawops : (string * Cpdfdraw.drawops list) list ref
|
val drawops : (string * Cpdfdraw.drawops list) list ref
|
||||||
val addop : Cpdfdraw.drawops -> unit
|
val addop : Cpdfdraw.drawops -> unit
|
||||||
|
Loading…
x
Reference in New Issue
Block a user