diff --git a/cpdftruetype.ml b/cpdftruetype.ml index e1abb42..8461cf0 100644 --- a/cpdftruetype.ml +++ b/cpdftruetype.ml @@ -55,7 +55,7 @@ let discard_bytes b n = for x = 1 to n do ignore (getval_31 b 8) done let pdf_unit unitsPerEm x = - int_of_float (float_of_int x *. 1000. /. float_of_int unitsPerEm) + int_of_float (float_of_int x *. 1000. /. float_of_int unitsPerEm +. 0.5) let string_of_tag t = Printf.sprintf "%c%c%c%c"