fpdf_form_r.h File Reference

Header file for PDF Form module of Foxit PDF SDK. More...

Go to the source code of this file.

Classes

struct  FSPDF_FORM
 Handle type to PDF form. More...
 
struct  FSPDF_FORMCONTROL
 Handle type to PDF form control (widget). More...
 
struct  FSPDF_CHOICEOPTION
 Structure for list box and combo box option only. More...
 

Macros

Macro Definitions for Form Field Types.
#define FSPDF_FORMFIELDTYPE_UNKNOWN   0
 Unknown type.
 
#define FSPDF_FORMFIELDTYPE_PUSHBUTTON   1
 Push button type.
 
#define FSPDF_FORMFIELDTYPE_CHECKBOX   2
 Check box type.
 
#define FSPDF_FORMFIELDTYPE_RADIOBUTTON   3
 Radio button type.
 
#define FSPDF_FORMFIELDTYPE_COMBOBOX   4
 Combo box type.
 
#define FSPDF_FORMFIELDTYPE_LISTBOX   5
 List box type.
 
#define FSPDF_FORMFIELDTYPE_TEXTFIELD   6
 single line or multi-line texts.
 
#define FSPDF_FORMFIELDTYPE_UNSPECIFIED   FSPDF_FORMFIELDTYPE_UNKNOWN
 Unspecified type.
 
Macro Definitions for Form Field Flags.
#define FSPDF_FORMFIELDFLAG_READONLY   0x001
 The field is read only and no editing is allowed.
 
#define FSPDF_FORMFIELDFLAG_REQUIRED   0x002
 The field will be exported by a submit-form action.
 
#define FSPDF_FORMFIELDFLAG_NOEXPORT   0x004
 The field must not be exported by a submit-form action.
 
Macro Definitions for Radio Button Field Flags.
#define FSPDF_FORMFIELDFLAG_BUTTON_NOTOGGLETOOF   0x100
 Unable to turn this radio button off. More...
 
#define FSPDF_FORMFIELDFLAG_BUTTON_RADIOSINUNISON   0x200
 Put radio buttons with same value in unison. More...
 
Macro Definitions for Text Field Flags.
#define FSPDF_FORMFIELDFLAG_TEXT_MULTILINE   0x100
 Multiple lines.
 
#define FSPDF_FORMFIELDFLAG_TEXT_PASSWORD   0x200
 This is a password field. Password should not be displayed or exported.
 
#define FSPDF_FORMFIELDFLAG_TEXT_DONOTSCROLL   0x400
 Never show scroll bar. More...
 
#define FSPDF_FORMFIELDFLAG_TEXT_COMB   0x800
 Use combs. More...
 
Macro Definitions for Combo Box Field Flags.
#define FSPDF_FORMFIELDFLAG_COMBO_EDIT   0x100
 Combo box style. More...
 
Macro Definitions for List Box Field Flags.
#define FSPDF_FORMFIELDFLAG_CHOICE_MULTISELECT   0x100
 If set, more than one items can be selected.
 

Functions

FS_RESULT FSPDF_Doc_HasForm (FSCRT_DOCUMENT document, FS_BOOL *hasForm)
 Check if the document has a Acro form. More...
 
FS_RESULT FSPDF_Form_Load (FSCRT_DOCUMENT pdfDoc, FSPDF_FORM *form)
 Retrieve a form handle for a specific document. More...
 
FS_RESULT FSPDF_Form_Release (FSPDF_FORM form)
 Release a PDF interactive form object. More...
 
FS_RESULT FSPDF_Form_GetDocument (FSPDF_FORM form, FSCRT_DOCUMENT *document)
 Retrieve a PDF document which owns the form. More...
 
FS_RESULT FSPDF_Form_CountFields (FSPDF_FORM form, const FSCRT_BSTR *filter, FS_INT32 *count)
 Get count of fields satisfying a name filter in a form. More...
 
FS_RESULT FSPDF_Form_GetField (FSPDF_FORM form, const FSCRT_BSTR *filter, FS_INT32 index, FSCRT_BSTR *fieldName, FS_INT32 *fieldType)
 Search and retrieve the name and type of a field satisfying a name filter in a form. More...
 
FS_RESULT FSPDF_Form_GetControlAtPos (FSPDF_FORM form, FSCRT_PAGE page, FS_FLOAT x, FS_FLOAT y, FS_FLOAT tolerance, FS_INT32 typeFilter, FSPDF_FORMCONTROL *formControl)
 Search for form control at a specific position in a form. More...
 
FS_RESULT FSPDF_Form_GetControlAtDevicePos (FSPDF_FORM form, FSCRT_PAGE page, const FSCRT_MATRIX *matrix, FS_INT32 x, FS_INT32 y, FS_FLOAT tolerance, FS_INT32 typeFilter, FSPDF_FORMCONTROL *formControl)
 Search for form control which locates at a specific device position in a form. More...
 
FS_RESULT FSPDF_Form_GetDefaultAppearance (FSPDF_FORM form, FSPDF_DEFAULTAPPEARANCE *defAppearance)
 Retrieve a default appearance of form. More...
 
FS_RESULT FSPDF_Form_GetAlignment (FSPDF_FORM form, FS_INT32 *alignment)
 Retrieve alignment property of a form. More...
 
FS_RESULT FSPDF_Form_NeedConstructAppearances (FSPDF_FORM form, FS_BOOL *needConstruct)
 Retrieve a boolean value whether or not to construct appearance property of a form. More...
 
FS_RESULT FSPDF_Form_ValidateFieldName (FSPDF_FORM form, const FSCRT_BSTR *newFieldName, FS_INT32 fieldType, FS_BOOL *validate)
 Check if a name is valid for specified type of field in a form. More...
 
FS_RESULT FSPDF_Form_GetFieldsInCalculationOrder (FSPDF_FORM form, FSCRT_BSTR *fieldNames, FS_DWORD *count)
 Get fields in a form in calculation order. More...
 
FS_RESULT FSPDF_FormField_CountActions (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FS_INT32 trigger, FS_INT32 *count)
 Retrieve count of actions associated with a field and a trigger type in a form. More...
 
FS_RESULT FSPDF_FormField_GetAction (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FS_INT32 trigger, FS_INT32 index, FSPDF_ACTIONDATA *actionData)
 Retrieve action associated with a field and a trigger type at a specified index in a form. More...
 
FS_RESULT FSPDF_ChoiceOption_Init (FSPDF_CHOICEOPTION *options)
 Helper function to initialize options. More...
 
FS_RESULT FSPDF_ChoiceOption_Clear (FSPDF_CHOICEOPTION *options)
 Helper function to clear options. More...
 
FS_RESULT FSPDF_FormField_GetAlignment (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FS_INT32 *alignment)
 Get alignment type of a field's text. More...
 
FS_RESULT FSPDF_FormField_GetFlags (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FS_DWORD *flags)
 Get flags specifying various characteristics of the field. More...
 
FS_RESULT FSPDF_FormField_GetType (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FS_INT32 *fieldType)
 Get field type. More...
 
FS_RESULT FSPDF_FormField_GetDefaultValue (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FSCRT_BSTR *value)
 Get default value of a field. More...
 
FS_RESULT FSPDF_FormField_GetValue (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FSCRT_BSTR *value)
 Get value of a field. More...
 
FS_RESULT FSPDF_FormField_CountControls (FSPDF_FORM form, FSCRT_PAGE page, const FSCRT_BSTR *fieldName, FS_INT32 *count)
 Get count of controls in a PDF page which belongs to specified fields. More...
 
FS_RESULT FSPDF_FormField_GetControl (FSPDF_FORM form, FSCRT_PAGE page, const FSCRT_BSTR *fieldName, FS_INT32 index, FSPDF_FORMCONTROL *formControl)
 Get a form control which belongs to the specified fields. More...
 
FS_RESULT FSPDF_FormField_GetControlIndex (FSPDF_FORM form, const FSPDF_FORMCONTROL formControl, FS_INT32 *index)
 Get index of the form control which belongs to the specified fields. More...
 
FS_RESULT FSPDF_FormField_GetDefaultAppearance (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FSPDF_DEFAULTAPPEARANCE *defAppearance)
 Get default appearance of specified fields. More...
 
FS_RESULT FSPDF_FormField_GetAlternateName (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FSCRT_BSTR *alternateName)
 Get alternate name to be used in place of actual field name. More...
 
FS_RESULT FSPDF_FormField_GetMappingName (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FSCRT_BSTR *mappingName)
 Get mapping name to be used when exporting interactive form field data from the document. More...
 
FS_RESULT FSPDF_FormField_GetMaxLen (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FS_INT32 *maxLen)
 Get maximum length of the field's text, in characters. More...
 
FS_RESULT FSPDF_FormField_GetOptions (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FSPDF_CHOICEOPTION *options, FS_INT32 *count)
 Get list box or combo box options. More...
 
FS_RESULT FSPDF_FormField_GetTopVisibleIndex (FSPDF_FORM form, const FSCRT_BSTR *fieldName, FS_INT32 *index)
 Get top index for scrollable list boxes. More...
 
FS_RESULT FSPDF_FormControl_GetWidgetAnnot (FSPDF_FORMCONTROL formControl, FSCRT_ANNOT *widgetAnnot)
 Get widget annotation from form control handle. More...
 
FS_RESULT FSPDF_FormControl_GetFieldName (FSPDF_FORMCONTROL formControl, FSCRT_BSTR *fieldName)
 Get field name from form control handle. More...
 
FS_RESULT FSPDF_FormControl_GetExportValue (FSPDF_FORMCONTROL formControl, FSCRT_BSTR *exportValue)
 Get option's export value. More...
 
FS_RESULT FSPDF_FormControl_IsChecked (FSPDF_FORMCONTROL formControl, FS_BOOL *checked)
 Get check box or radio button's state. More...
 
FS_RESULT FSPDF_FormControl_IsDefaultChecked (FSPDF_FORMCONTROL formControl, FS_BOOL *checked)
 Get check box or radio button's default state. More...
 
FS_RESULT FSPDF_RenderContext_StartFormControls (FSPDF_RENDERCONTEXT pdfRenderContext, FSCRT_RENDERER renderer, const FSPDF_FORMCONTROL *formControls, FS_INT32 count, FSCRT_PROGRESS *renderProgress)
 Start rendering a PDF form control in a renderer with a PDF rendering context. More...
 
FS_RESULT FSPDF_RenderContext_StartPageFormControls (FSPDF_RENDERCONTEXT pdfRenderContext, FSCRT_RENDERER renderer, FSCRT_PAGE page, FSCRT_PROGRESS *renderProgress)
 Start rendering a page's form controls in a renderer with a PDF rendering context. More...
 

Detailed Description

Header file for PDF Form module of Foxit PDF SDK.

Copyright (C) 2003-2016, Foxit Software Inc.. All Rights Reserved.

http://www.foxitsoftware.com

The following code is copyrighted and contains proprietary information and trade secrets of Foxit Software Inc.. You cannot distribute any part of Foxit PDF SDK to any third party or general public, unless there is a separate license agreement with Foxit Software Inc. which explicitly grants you such rights.

This header file defines PDF form supports.
It contains:

  • 1. Load PDF form and access form data.
  • 2. Get trigger actions of form field.
  • 3. Get properties of form field.
  • 4. Get form controls.
  • 5. Render form controls.
Note
If you want to purchase Foxit PDF SDK license and use ANY of the following functions, please request for enabling Form Add-on explicitly.

Foxit Corporation