summaryrefslogtreecommitdiff
path: root/public/fpdf_formfill.h
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2015-08-14 19:24:08 -0700
committerLei Zhang <thestig@chromium.org>2015-08-14 19:24:08 -0700
commitbdf72c353af5b8a34ef5efdeddfff36d2089a158 (patch)
tree34258c3019152b41bbfd8f3332683dbc25c0c9da /public/fpdf_formfill.h
parent88f0bafb4163d297b51055124d4d35b769905216 (diff)
downloadpdfium-bdf72c353af5b8a34ef5efdeddfff36d2089a158.tar.xz
Merge to XFA: Add new public APIs to find the z-order for links and widgets.
- Implement FPDFLink_GetLinkZOrderAtPoint(). - Implement FPDFPage_FormFieldZOrderAtPoint(). - Mark FPDPage_HasFormFieldAtPoint() as deprecated. - Modify CPDF_LinkList and CPDF_InterForm to support new APIs. - Clean up dead code in CPDF_LinkList and CPDF_InterForm. BUG=chromium:515837 R=jun_fang@foxitsoftware.com, tsepez@chromium.org Review URL: https://codereview.chromium.org/1278053004 . (cherry picked from commit 24fbf134d43a7ec4226de3db601f0a617bbe428b) Review URL: https://codereview.chromium.org/1295893005 .
Diffstat (limited to 'public/fpdf_formfill.h')
-rw-r--r--public/fpdf_formfill.h45
1 files changed, 36 insertions, 9 deletions
diff --git a/public/fpdf_formfill.h b/public/fpdf_formfill.h
index 73fe491435..7be678cd47 100644
--- a/public/fpdf_formfill.h
+++ b/public/fpdf_formfill.h
@@ -1311,17 +1311,26 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_ForceToKillFocus(FPDF_FORMHANDLE hHandle);
#define FPDF_FORMFIELD_XFA 7 // text field type.
/**
- * Function: FPDPage_HasFormFieldAtPoint
- * Check the form filed position by point.
+ * Function: FPDFPage_HasFormFieldAtPoint
+ * Get the form field type by point.
* Parameters:
- * hHandle - Handle to the form fill module. Returned by
- *FPDFDOC_InitFormFillEnvironment.
- * page - Handle to the page. Returned by FPDF_LoadPage
- *function.
- * page_x - X position in PDF "user space".
- * page_y - Y position in PDF "user space".
+ * hHandle - Handle to the form fill module. Returned by
+ * FPDFDOC_InitFormFillEnvironment().
+ * page - Handle to the page. Returned by FPDF_LoadPage().
+ * page_x - X position in PDF "user space".
+ * page_y - Y position in PDF "user space".
* Return Value:
- * Return the type of the formfiled; -1 indicates no fields.
+ * Return the type of the form field; -1 indicates no field.
+ * See field types above.
+ **/
+DLLEXPORT int STDCALL FPDFPage_HasFormFieldAtPoint(FPDF_FORMHANDLE hHandle,
+ FPDF_PAGE page,
+ double page_x,
+ double page_y);
+
+/**
+ * Function: FPDPage_HasFormFieldAtPoint
+ * DEPRECATED. Please use FPDFPage_HasFormFieldAtPoint.
**/
DLLEXPORT int STDCALL FPDPage_HasFormFieldAtPoint(FPDF_FORMHANDLE hHandle,
FPDF_PAGE page,
@@ -1329,6 +1338,24 @@ DLLEXPORT int STDCALL FPDPage_HasFormFieldAtPoint(FPDF_FORMHANDLE hHandle,
double page_y);
/**
+ * Function: FPDFPage_FormFieldZOrderAtPoint
+ * Get the form field z-order by point.
+ * Parameters:
+ * hHandle - Handle to the form fill module. Returned by
+ * FPDFDOC_InitFormFillEnvironment().
+ * page - Handle to the page. Returned by FPDF_LoadPage().
+ * page_x - X position in PDF "user space".
+ * page_y - Y position in PDF "user space".
+ * Return Value:
+ * Return the z-order of the form field; -1 indicates no field.
+ * Higher numbers are closer to the front.
+ **/
+DLLEXPORT int STDCALL FPDFPage_FormFieldZOrderAtPoint(FPDF_FORMHANDLE hHandle,
+ FPDF_PAGE page,
+ double page_x,
+ double page_y);
+
+/**
* Function: FPDF_SetFormFieldHighlightColor
* Set the highlight color of specified or all the form fields in the
*document.