resize To Fit Text
open fun resizeToFitText(@NonNull freeTextAnnotation: FreeTextAnnotation, @NonNull document: PdfDocument, @NonNull widthScaleMode: FreeTextAnnotationUtils.ScaleMode, @NonNull heightScaleMode: FreeTextAnnotationUtils.ScaleMode)
Resizes the given free text annotation so the text fits inside its bounds.
Parameters
free Text Annotation
Free text annotation to resize.
document
Document to use for acquiring the page size.
width Scale Mode
Scale mode to use when determining the width.
height Scale Mode
Scale mode to use when determining the height.