Foxit PDF SDK

Public Member Functions | List of all members
com.foxit.sdk.addon.xfa.XFAPage Class Reference
Inheritance diagram for com.foxit.sdk.addon.xfa.XFAPage:

## Public Member Functions
| XFAPage (XFAPage other)
| Constructor, with another XFA page object. More...
synchronized void | delete ()
| Clean up related C++ resources immediately. More...
Matrix2D | getDisplayMatrix (int left, int top, int width, int height, int rotate) throws com.foxit.sdk.PDFException
| Get the display matrix, from PDF coordinate system to targeted device coordinate system. More...
XFAWidget | getFirstWidget () throws com.foxit.sdk.PDFException
| Get the first XFA widget in current tab order. More...
float | getHeight () throws com.foxit.sdk.PDFException
| Get the height of the XFA page. More...
int | getIndex () throws com.foxit.sdk.PDFException
| Get index of the XFA page. More...
XFAWidget | getLastWidget () throws com.foxit.sdk.PDFException
| Get the last XFA widget in current tab order. More...
XFAWidget | getNextWidget (XFAWidget widget) throws com.foxit.sdk.PDFException
| Get the next XFA widget of a specified XFA widget in current tab order. More...
XFAWidget | getPrevWidget (XFAWidget widget) throws com.foxit.sdk.PDFException
| Get the previous XFA widget of a specified XFA widget in current tab order. More...
XFAWidget | getWidget (int widget_index) throws com.foxit.sdk.PDFException
| Get XFA widget by index. More...
XFAWidget | getWidgetAtDevicePoint (Matrix2D matrix, PointF device_point, float tolerance) throws com.foxit.sdk.PDFException
| Get the XFA widget at a specified point, in device coordinate system. More...
XFAWidget | getWidgetByFullName (String full_name) throws com.foxit.sdk.PDFException
| Get the XFA widget which matches the specified full name in current XFA page. More...
int | getWidgetCount () throws com.foxit.sdk.PDFException
| Get the count of XFA widget. More...
float | getWidth () throws com.foxit.sdk.PDFException
| Get the width. More...
boolean | isEmpty ()
| Check whether current object is empty or not. More...

## Detailed Description

Class XFAPage represents the XFA page which is retrieved from XFA document object.
To render an XFA page, please use function common.Renderer.startRenderXFAPage .

See also
  com.foxit.sdk.common.Renderer

## Constructor & Destructor Documentation

## ◆ XFAPage()

com.foxit.sdk.addon.xfa.XFAPage.XFAPage | ( | XFAPage | other | ) |

Constructor, with another XFA page object.

Parameters

  [in] | other | Another XFA page object.

## Member Function Documentation

## ◆ delete()

synchronized void com.foxit.sdk.addon.xfa.XFAPage.delete | ( |  | ) |

Clean up related C++ resources immediately.

Returns
  None.

Note
  Once this function is called, current object cannot be used anymore.

Reimplemented from com.foxit.sdk.common.Base.

## ◆ getDisplayMatrix()

Matrix2D com.foxit.sdk.addon.xfa.XFAPage.getDisplayMatrix | ( | int | left,
|  | int | top,
|  | int | width,
|  | int | height,
|  | int | rotate
| ) |  | throws com.foxit.sdk.PDFException

Get the display matrix, from PDF coordinate system to targeted device coordinate system.

Parameters

  [in] | left | Left position of the transformation area in device coordinate system, commonly in pixels.
  [in] | top | Top position of the transformation area in device coordinate system, commonly in pixels.
  [in] | width | Width of the transformation area in device coordinate system, commonly in pixels.
  [in] | height | Height of the transformation area in device coordinate system, commonly in pixels.
  [in] | rotate | Rotation value. Please refer to values starting from com.foxit.sdk.common.Constants.e_Rotation0 and this should be one of these values.

Returns
  A Matrix object that receives the display matrix used for current XFA page. If there is any error, a Matrix with all value 0 will be returned.

## ◆ getFirstWidget()

XFAWidget com.foxit.sdk.addon.xfa.XFAPage.getFirstWidget | ( |  | ) | throws com.foxit.sdk.PDFException

Get the first XFA widget in current tab order.

Returns
  The first XFA widget. If the return value of function XFAWidget.isEmpty for the returned XFA widget object is true, that means there is no XFA widget.

## ◆ getHeight()

float com.foxit.sdk.addon.xfa.XFAPage.getHeight | ( |  | ) | throws com.foxit.sdk.PDFException

Get the height of the XFA page.

Returns
  A float value that receives the height of current XFA page.

## ◆ getIndex()

int com.foxit.sdk.addon.xfa.XFAPage.getIndex | ( |  | ) | throws com.foxit.sdk.PDFException

Get index of the XFA page.

Returns
  The index of XFA page.

## ◆ getLastWidget()

XFAWidget com.foxit.sdk.addon.xfa.XFAPage.getLastWidget | ( |  | ) | throws com.foxit.sdk.PDFException

Get the last XFA widget in current tab order.

Returns
  The last XFA widget. If the return value of function XFAWidget.isEmpty for the returned XFA widget object is true, that means there is no XFA widget.

## ◆ getNextWidget()

XFAWidget com.foxit.sdk.addon.xfa.XFAPage.getNextWidget | ( | XFAWidget | widget | ) | throws com.foxit.sdk.PDFException

Get the next XFA widget of a specified XFA widget in current tab order.

Parameters

  [in] | widget | A valid specified XFA widget.

Returns
  The next XFA widget. If the return value of function XFAWidget.isEmpty for the returned XFA widget object is true, that means the specified XFA widget is the last XFA widget in current tab order.

## ◆ getPrevWidget()

XFAWidget com.foxit.sdk.addon.xfa.XFAPage.getPrevWidget | ( | XFAWidget | widget | ) | throws com.foxit.sdk.PDFException

Get the previous XFA widget of a specified XFA widget in current tab order.

Parameters

  [in] | widget | A valid specified XFA widget.

Returns
  The previous XFA widget. If the return value of function XFAWidget.isEmpty for the returned XFA widget object is true, that means the specified XFA widget is the previous XFA widget in current tab order.

## ◆ getWidget()

XFAWidget com.foxit.sdk.addon.xfa.XFAPage.getWidget | ( | int | widget_index | ) | throws com.foxit.sdk.PDFException

Get XFA widget by index.

Parameters

  [in] | widget_index | The XFA widget index. Valid range: from 0 to (count-1). count is returned by function XFAPage.getWidgetCount .

Returns
  The XFA widget.

## ◆ getWidgetAtDevicePoint()

XFAWidget com.foxit.sdk.addon.xfa.XFAPage.getWidgetAtDevicePoint | ( | Matrix2D | matrix,
|  | PointF | device_point,
|  | float | tolerance
| ) |  | throws com.foxit.sdk.PDFException

Get the XFA widget at a specified point, in device coordinate system.

Parameters

  [in] | matrix | The transformation matrix. Usually this is returned by function XFAPage.getDisplayMatrix .
  [in] | device_point | A point in device coordinate system.
  [in] | tolerance | Tolerance value. Valid range: 0.0f to 30.0f.

Returns
  An XFA Widget object.

## ◆ getWidgetByFullName()

XFAWidget com.foxit.sdk.addon.xfa.XFAPage.getWidgetByFullName | ( | String | full_name | ) | throws com.foxit.sdk.PDFException

Get the XFA widget which matches the specified full name in current XFA page.

Parameters

  [in] | full_name | An XFA widget's full name. It should not be an empty string. XFA widget's full name can be retrieved by function XFAWidget.getName with type com.foxit.sdk.addon.xfa.XFAWidget.e_WidgetNameTypeFullName in previous process.

Returns
  An XFA Widget object.

## ◆ getWidgetCount()

int com.foxit.sdk.addon.xfa.XFAPage.getWidgetCount | ( |  | ) | throws com.foxit.sdk.PDFException

Get the count of XFA widget.

Returns
  The count of XFA widget.

## ◆ getWidth()

float com.foxit.sdk.addon.xfa.XFAPage.getWidth | ( |  | ) | throws com.foxit.sdk.PDFException

Get the width.

Returns
  A float value that receives the width of current XFA page.

## ◆ isEmpty()

boolean com.foxit.sdk.addon.xfa.XFAPage.isEmpty | ( |  | ) |

Check whether current object is empty or not.

When the current object is empty, that means current object is useless.

Returns
  true means current object is empty, while false means not.