litePDF C interface  2.0.5
Units

Since litePDF 1.2.0.0 the functions which used millimeters as their measure units can use also inches, or fractions of the millimeters and inches. The reason for the fraction is to not use architectural dependent types in the API, where the double type is. The unit value is rounded down to unsigned integers in the API. The default unit is set to millimeters (LITEPDF_UNIT_MM) for backward compatibility.

Call litePDF_GetUnit to determine which unit is currently used. To change the unit to be used call litePDF_SetUnit. For example, to create a page of size 8.5 inches x 11.0 inches, set the unit to LITEPDF_UNIT_10TH_INCH and then call the litePDF_AddPage with the width 85 and height 110 (10-times larger, because the current unit is 1/10th of an inch).

All functions use the unit set for the current context, except of the litePDF_DrawResource, which has an explicit argument for the unit value. That's for simplicity, to not need to change the units before the function is called and then set it back after the call.