Uses of Class
com.itextpdf.forms.fields.PdfFormField
-
Uses of PdfFormField in com.itextpdf.forms
Modifier and TypeFieldDescriptionprotected Map<String,
PdfFormField> PdfAcroForm.fields
A map of field names and their associatedform field
objects.Modifier and TypeMethodDescriptionCreates an in-memory copy of aPdfFormField
.Gets aform field
by its name.Modifier and TypeMethodDescriptionPdfAcroForm.getFieldsForFlattening()
Gets a collection ofform field
s, prepared for flattening usingPdfAcroForm.partialFormFlattening(java.lang.String)
method.PdfAcroForm.getFormFields()
Gets theform field
s as aMap
.Modifier and TypeMethodDescriptionvoid
PdfAcroForm.addField
(PdfFormField field) This method adds the field to the last page in the document.void
PdfAcroForm.addField
(PdfFormField field, PdfPage page) This method adds the field to a specific page.void
PdfAcroForm.addFieldAppearanceToPage
(PdfFormField field, PdfPage page) This method merges field with its annotation and place it on the given page.void
PdfAcroForm.replaceField
(String name, PdfFormField field) Replaces thePdfFormField
of a certain name with anotherPdfFormField
. -
Uses of PdfFormField in com.itextpdf.forms.fields
Modifier and TypeClassDescriptionclass
An interactive control on the screen that raises events and/or can retain data.class
An AcroForm field type representing any type of choice field.class
An AcroForm field containing signature data.class
An AcroForm field containing textual data.Modifier and TypeMethodDescriptionPdfFormField.addKid
(PdfFormField kid) Adds a new kid to theKids
array property from aPdfFormField
.PdfFormField.addKid
(PdfWidgetAnnotation kid) Adds a new kid to theKids
array property from aPdfWidgetAnnotation
.static PdfFormField
PdfFormField.createEmptyField
(PdfDocument doc) Creates an empty form field without a predefined set of layout or behavior.static PdfFormField
PdfFormField.createEmptyField
(PdfDocument doc, PdfAConformanceLevel pdfAConformanceLevel) Creates an empty form field without a predefined set of layout or behavior.static PdfFormField
PdfFormField.createRadioButton
(PdfDocument doc, Rectangle rect, PdfButtonFormField radioGroup, String value) Creates a genericPdfFormField
that is added to a radio group.static PdfFormField
PdfFormField.createRadioButton
(PdfDocument doc, Rectangle rect, PdfButtonFormField radioGroup, String value, PdfAConformanceLevel pdfAConformanceLevel) Creates a genericPdfFormField
that is added to a radio group.static PdfFormField
PdfFormField.makeFormField
(PdfObject pdfObject, PdfDocument document) Creates a (subtype of)PdfFormField
object.Inserts the value into thePdfDictionary
of this field and associates it with the specified key.Removes the specified key from thePdfDictionary
of this field.Sets the action on allwidgets
of this form field.PdfFormField.setAdditionalAction
(PdfName key, PdfAction action) Sets an additional action for the form field.PdfFormField.setAlternativeName
(String name) Changes the alternate name of the field to the specified value.PdfFormField.setAppearance
(PdfName appearanceType, String appearanceState, PdfStream appearanceStream) Sets an appearance for (the widgets related to) the form field.PdfFormField.setBackgroundColor
(Color backgroundColor) Basic setter for thebackgroundColor
property.PdfFormField.setBorderColor
(Color color) Sets the Border Color.PdfFormField.setBorderStyle
(PdfDictionary style) Sets the border style for the field.PdfFormField.setBorderWidth
(float borderWidth) Sets the border width for the field.PdfFormField.setCheckType
(int checkType) Changes the type of graphical marker used to mark a checkbox as 'on'.Sets the text color.PdfFormField.setDefaultStyle
(PdfString defaultStyleString) Sets a default style string, as described in "Rich Text Strings" section of Pdf spec.PdfFormField.setDefaultValue
(PdfObject value) Sets the default fallback value for the form field.PdfFormField.setFieldFlag
(int flag) Adds a flag, or combination of flags, for the form field.PdfFormField.setFieldFlag
(int flag, boolean value) Adds or removes a flag, or combination of flags, for the form field.PdfFormField.setFieldFlags
(int flags) Sets a flag, or combination of flags, for the form field.PdfFormField.setFieldName
(String name) Changes the name of the field to the specified value.Basic setter for thefont
property.PdfFormField.setFontAndSize
(PdfFont font, float fontSize) Combined setter for thefont
andfontSize
properties.PdfFormField.setFontSize
(float fontSize) Basic setter for thefontSize
property.PdfFormField.setFontSize
(int fontSize) Basic setter for thefontSize
property.PdfFormField.setFontSizeAutoScale()
Sets zero font size which will be interpreted as auto-size according to ISO 32000-1, 12.7.3.3.PdfFormField.setJustification
(int justification) Sets a code specifying the form of quadding (justification) to be used in displaying the text: 0 Left-justified 1 Centered 2 Right-justifiedPdfFormField.setMappingName
(String name) Changes the mapping name of the field to the specified value.PdfFormField.setNoExport
(boolean noExport) Sets the NoExport flag, specifying whether or not exporting is forbidden.PdfFormField.setOptions
(PdfArray options) Sets options for the form field.PdfFormField.setPage
(int pageNum) Specifies on which page the form field's widget must be shown.PdfFormField.setParent
(PdfFormField parent) Sets a parentPdfFormField
for the current object.PdfFormField.setReadOnly
(boolean readOnly) Sets the ReadOnly flag, specifying whether or not the field can be changed.PdfFormField.setRequired
(boolean required) Sets the Required flag, specifying whether or not the field must be filled in.PdfFormField.setRichText
(PdfObject richText) Sets a rich text string, as described in "Rich Text Strings" section of Pdf spec.PdfFormField.setRotation
(int degRotation) Basic setter for thedegRotation
property.Sets a value to the field and generating field appearance if needed.Sets a value to the field and generates field appearance if needed.Set text field value with given font and sizeSets the field value and the display string.PdfFormField.setVisibility
(int visibility) Set the visibility flags of the form field annotation Options are: HIDDEN, HIDDEN_BUT_PRINTABLE, VISIBLE, VISIBLE_BUT_DOES_NOT_PRINTModifier and TypeMethodDescriptionPdfFormField.addKid
(PdfFormField kid) Adds a new kid to theKids
array property from aPdfFormField
.PdfFormField.setParent
(PdfFormField parent) Sets a parentPdfFormField
for the current object.