Class Form_Api
- java.lang.Object
- 
- com.ironsoftware.ironpdf.internal.staticapi.Form_Api
 
- 
 public final class Form_Api extends Object The type Form api.
- 
- 
Constructor SummaryConstructors Constructor Description Form_Api()
 - 
Method SummaryAll Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static voidflattenPdfFrom(InternalPdfDocument internalPdfDocument)Flattens a document (make the fields non-editable).static voidflattenPdfFrom(InternalPdfDocument internalPdfDocument, List<Integer> pageIndexes)Flattens a document (make the fields non-editable).static List<FormField>getFields(InternalPdfDocument internalPdfDocument)Get a collection of the user-editable form fields within a PDF documentstatic StringrenameField(InternalPdfDocument internalPdfDocument, String currentFieldName, String newFieldName)Rename aFormFieldstatic voidsetFieldValue(InternalPdfDocument internalPdfDocument, int annotationIndex, String value)Set the value of aFormFieldstatic voidsetFormFieldIsReadOnly(InternalPdfDocument internalPdfDocument, int annotationIndex, boolean isReadOnly)Sets text field font.static voidsetTextFieldFont(InternalPdfDocument internalPdfDocument, String textFieldName, FontTypes font, int fontSize)Deprecated.This method is deprecated and no longer has any effect.
 
- 
- 
- 
Method Detail- 
getFieldspublic static List<FormField> getFields(InternalPdfDocument internalPdfDocument) Get a collection of the user-editable form fields within a PDF document- Parameters:
- internalPdfDocument- the internal pdf document
- Returns:
- the fields
 
 - 
renameFieldpublic static String renameField(InternalPdfDocument internalPdfDocument, String currentFieldName, String newFieldName) Rename aFormField- Parameters:
- internalPdfDocument- the internal pdf document
- currentFieldName- current fully qualified field name
- newFieldName- new partial field name Please use a fully qualified field name for CurrentFieldName, and a partial field name for NewFieldName
- Returns:
- newFieldName;
 
 - 
setFieldValuepublic static void setFieldValue(InternalPdfDocument internalPdfDocument, int annotationIndex, String value) Set the value of aFormField- Parameters:
- internalPdfDocument- the internal pdf document
- annotationIndex- fully qualified field annotationIndex
- value- new value
 
 - 
setTextFieldFontpublic static void setTextFieldFont(InternalPdfDocument internalPdfDocument, String textFieldName, FontTypes font, int fontSize) Deprecated.This method is deprecated and no longer has any effect. Sets text field font.- Parameters:
- internalPdfDocument- the internal pdf document
- textFieldName- the text field name
- font- the font
- fontSize- the font size
 
 - 
flattenPdfFrompublic static void flattenPdfFrom(InternalPdfDocument internalPdfDocument) Flattens a document (make the fields non-editable).- Parameters:
- internalPdfDocument- the internal pdf document
 
 - 
flattenPdfFrompublic static void flattenPdfFrom(InternalPdfDocument internalPdfDocument, List<Integer> pageIndexes) Flattens a document (make the fields non-editable).- Parameters:
- internalPdfDocument- the internal pdf document
- pageIndexes- page indexes to flatten (defaults to all pages)
 
 - 
setFormFieldIsReadOnlypublic static void setFormFieldIsReadOnly(InternalPdfDocument internalPdfDocument, int annotationIndex, boolean isReadOnly) Sets text field font.- Parameters:
- internalPdfDocument- the internal pdf document
- annotationIndex- the form field annotation Index
- isReadOnly- the read only value
 
 
- 
 
-