diff options
-rw-r--r-- | fpdfsdk/include/fpdf_dataavail.h | 2 | ||||
-rw-r--r-- | fpdfsdk/include/fpdfformfill.h | 48 | ||||
-rw-r--r-- | fpdfsdk/src/fpdfformfill.cpp | 4 | ||||
-rw-r--r-- | samples/pdfium_test.cc | 4 |
4 files changed, 29 insertions, 29 deletions
diff --git a/fpdfsdk/include/fpdf_dataavail.h b/fpdfsdk/include/fpdf_dataavail.h index fb061b9bfa..04f632affb 100644 --- a/fpdfsdk/include/fpdf_dataavail.h +++ b/fpdfsdk/include/fpdf_dataavail.h @@ -193,7 +193,7 @@ DLLEXPORT int STDCALL FPDFAvail_IsPageAvail(FPDF_AVAIL avail, int page_index, FX * This function call be called only after FPDFAvail_GetDocument if called. * The application should call this function whenever new data arrived, and process all the * generated download hints if any, until the function returns non-zero value. Then the -* application can perform page loading. Recommend to call FPDFDOC_InitFormFillEnviroument +* application can perform page loading. Recommend to call FPDFDOC_InitFormFillEnvironment * after the function returns non-zero value. */ DLLEXPORT int STDCALL FPDFAvail_IsFormAvail(FPDF_AVAIL avail, FX_DOWNLOADHINTS* hints); diff --git a/fpdfsdk/include/fpdfformfill.h b/fpdfsdk/include/fpdfformfill.h index bae07ce271..442b93fb0f 100644 --- a/fpdfsdk/include/fpdfformfill.h +++ b/fpdfsdk/include/fpdfformfill.h @@ -800,7 +800,7 @@ typedef struct _FPDF_FORMFILLINFO /** - * Function: FPDFDOC_InitFormFillEnviroument + * Function: FPDFDOC_InitFormFillEnvironment * Init form fill environment. * Comments: * This function should be called before any form fill operation. @@ -810,24 +810,24 @@ typedef struct _FPDF_FORMFILLINFO * Return Value: * Return handler to the form fill module. NULL means fails. **/ -DLLEXPORT FPDF_FORMHANDLE STDCALL FPDFDOC_InitFormFillEnviroument(FPDF_DOCUMENT document, FPDF_FORMFILLINFO* formInfo); +DLLEXPORT FPDF_FORMHANDLE STDCALL FPDFDOC_InitFormFillEnvironment(FPDF_DOCUMENT document, FPDF_FORMFILLINFO* formInfo); /** - * Function: FPDFDOC_ExitFormFillEnviroument + * Function: FPDFDOC_ExitFormFillEnvironment * Exit form fill environment. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * Return Value: * NULL. **/ -DLLEXPORT void STDCALL FPDFDOC_ExitFormFillEnviroument(FPDF_FORMHANDLE hHandle); +DLLEXPORT void STDCALL FPDFDOC_ExitFormFillEnvironment(FPDF_FORMHANDLE hHandle); /** * Function: FORM_OnAfterLoadPage * This method is required for implementing all the form related functions. Should be invoked after user - * successfully loaded a PDF page, and method FPDFDOC_InitFormFillEnviroument had been invoked. + * successfully loaded a PDF page, and method FPDFDOC_InitFormFillEnvironment had been invoked. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * Return Value: * NONE. **/ @@ -839,7 +839,7 @@ DLLEXPORT void STDCALL FORM_OnAfterLoadPage(FPDF_PAGE page, FPDF_FORMHANDLE hHan * close the PDF page. * Parameters: * page - Handle to the page. Returned by FPDF_LoadPage function. - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * Return Value: * NONE. **/ @@ -850,7 +850,7 @@ DLLEXPORT void STDCALL FORM_OnBeforeClosePage(FPDF_PAGE page, FPDF_FORMHANDLE hH * This method is required for performing Document-level JavaScript action. It should be invoked after the PDF document * had been loaded. * Parameters: -* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. +* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * Return Value: * NONE * Comments: @@ -864,7 +864,7 @@ DLLEXPORT void STDCALL FORM_DoDocumentJSAction(FPDF_FORMHANDLE hHandle); * Function: FORM_DoDocumentOpenAction * This method is required for performing open-action when the document is opened. * Parameters: -* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. +* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * Return Value: * NONE * Comments: @@ -883,7 +883,7 @@ DLLEXPORT void STDCALL FORM_DoDocumentOpenAction(FPDF_FORMHANDLE hHandle); * Function: FORM_DoDocumentAAction * This method is required for performing the document's additional-action. * Parameters: -* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. +* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * aaType - The type of the additional-actions which defined above. * Return Value: * NONE @@ -902,7 +902,7 @@ DLLEXPORT void STDCALL FORM_DoDocumentAAction(FPDF_FORMHANDLE hHandle, int aaTyp * This method is required for performing the page object's additional-action when opened or closed. * Parameters: * page - Handle to the page. Returned by FPDF_LoadPage function. -* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. +* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * aaType - The type of the page object's additional-actions which defined above. * Return Value: * NONE @@ -915,7 +915,7 @@ DLLEXPORT void STDCALL FORM_DoPageAAction(FPDF_PAGE page, FPDF_FORMHANDLE hHandl * Function: FORM_OnMouseMove * You can call this member function when the mouse cursor moves. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * page - Handle to the page. Returned by FPDF_LoadPage function. * modifier - Indicates whether various virtual keys are down. * page_x - Specifies the x-coordinate of the cursor in PDF user space. @@ -929,7 +929,7 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_OnMouseMove(FPDF_FORMHANDLE hHandle,FPDF_PAGE p * Function: FORM_OnLButtonDown * You can call this member function when the user presses the left mouse button. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * page - Handle to the page. Returned by FPDF_LoadPage function. * modifier - Indicates whether various virtual keys are down. * page_x - Specifies the x-coordinate of the cursor in PDF user space. @@ -943,7 +943,7 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_OnLButtonDown(FPDF_FORMHANDLE hHandle,FPDF_PAGE * Function: FORM_OnLButtonUp * You can call this member function when the user releases the left mouse button. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * page - Handle to the page. Returned by FPDF_LoadPage function. * modifier - Indicates whether various virtual keys are down. * page_x - Specifies the x-coordinate of the cursor in device. @@ -960,7 +960,7 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_OnRButtonUp(FPDF_FORMHANDLE hHandle, FPDF_PAGE * Function: FORM_OnKeyDown * You can call this member function when a nonsystem key is pressed. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * page - Handle to the page. Returned by FPDF_LoadPage function. * nKeyCode - Indicates whether various virtual keys are down. * modifier - Contains the scan code, key-transition code, previous key state, and context code. @@ -973,7 +973,7 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_OnKeyDown(FPDF_FORMHANDLE hHandle,FPDF_PAGE pag * Function: FORM_OnKeyUp * You can call this member function when a nonsystem key is released. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * page - Handle to the page. Returned by FPDF_LoadPage function. * nKeyCode - The virtual-key code of the given key. * modifier - Contains the scan code, key-transition code, previous key state, and context code. @@ -986,7 +986,7 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_OnKeyUp(FPDF_FORMHANDLE hHandle,FPDF_PAGE page, * Function: FORM_OnChar * You can call this member function when a keystroke translates to a nonsystem character. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * page - Handle to the page. Returned by FPDF_LoadPage function. * nChar - The character code value of the key. * modifier - Contains the scan code, key-transition code, previous key state, and context code. @@ -1000,7 +1000,7 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_OnChar(FPDF_FORMHANDLE hHandle,FPDF_PAGE page, * You can call this member function to force to kill the focus of the form field which got focus. * It would kill the focus on the form field, save the value of form field if it's changed by user. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * Return Value: * TRUE indicates success; otherwise false. **/ @@ -1019,7 +1019,7 @@ DLLEXPORT FPDF_BOOL STDCALL FORM_ForceToKillFocus(FPDF_FORMHANDLE hHandle); * Function: FPDPage_HasFormFieldAtPoint * Check the form filed position by point. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * 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". @@ -1032,7 +1032,7 @@ DLLEXPORT int STDCALL FPDPage_HasFormFieldAtPoint(FPDF_FORMHANDLE hHandle,FPDF_P * Function: FPDF_SetFormFieldHighlightColor * Set the highlight color of specified or all the form fields in the document. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * doc - Handle to the document. Returned by FPDF_LoadDocument function. * fieldType - A 32-bit integer indicating the type of a form field(defined above). * color - The highlight color of the form field.Constructed by 0xxxrrggbb. @@ -1049,7 +1049,7 @@ DLLEXPORT void STDCALL FPDF_SetFormFieldHighlightColor(FPDF_FORMHANDLE hHandle, * Function: FPDF_SetFormFieldHighlightAlpha * Set the transparency of the form field highlight color in the document. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * doc - Handle to the document. Returned by FPDF_LoadDocument function. * alpha - The transparency of the form field highlight color. between 0-255. * Return Value: @@ -1062,7 +1062,7 @@ DLLEXPORT void STDCALL FPDF_SetFormFieldHighlightAlpha(FPDF_FORMHANDLE hHandle, * Function: FPDF_RemoveFormFieldHighlight * Remove the form field highlight color in the document. * Parameters: - * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. + * hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * Return Value: * NONE. * Comments: @@ -1074,7 +1074,7 @@ DLLEXPORT void STDCALL FPDF_RemoveFormFieldHighlight(FPDF_FORMHANDLE hHandle); * Function: FPDF_FFLDraw * Render FormFeilds on a page to a device independent bitmap. * Parameters: -* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnviroument. +* hHandle - Handle to the form fill module. Returned by FPDFDOC_InitFormFillEnvironment. * bitmap - Handle to the device independent bitmap (as the output buffer). * Bitmap handle can be created by FPDFBitmap_Create function. * page - Handle to the page. Returned by FPDF_LoadPage function. diff --git a/fpdfsdk/src/fpdfformfill.cpp b/fpdfsdk/src/fpdfformfill.cpp index 41b1e36fd9..0fb32919e1 100644 --- a/fpdfsdk/src/fpdfformfill.cpp +++ b/fpdfsdk/src/fpdfformfill.cpp @@ -84,7 +84,7 @@ DLLEXPORT int STDCALL FPDPage_HasFormFieldAtPoint(FPDF_FORMHANDLE hHandle, FPDF_ return -1; } -DLLEXPORT FPDF_FORMHANDLE STDCALL FPDFDOC_InitFormFillEnviroument(FPDF_DOCUMENT document, FPDF_FORMFILLINFO* formInfo) +DLLEXPORT FPDF_FORMHANDLE STDCALL FPDFDOC_InitFormFillEnvironment(FPDF_DOCUMENT document, FPDF_FORMFILLINFO* formInfo) { if(!document || !formInfo || formInfo->version!=2) return NULL; @@ -109,7 +109,7 @@ DLLEXPORT FPDF_FORMHANDLE STDCALL FPDFDOC_InitFormFillEnviroument(FPDF_DOCUMENT return pEnv; } -DLLEXPORT void STDCALL FPDFDOC_ExitFormFillEnviroument(FPDF_FORMHANDLE hHandle) +DLLEXPORT void STDCALL FPDFDOC_ExitFormFillEnvironment(FPDF_FORMHANDLE hHandle) { if (!hHandle) return; diff --git a/samples/pdfium_test.cc b/samples/pdfium_test.cc index c5ac75e663..f50d4d16a2 100644 --- a/samples/pdfium_test.cc +++ b/samples/pdfium_test.cc @@ -289,7 +289,7 @@ void RenderPdf(const char* name, const char* pBuf, size_t len, (void) FPDF_GetDocPermissions(doc); (void) FPDFAvail_IsFormAvail(pdf_avail, &hints); - FPDF_FORMHANDLE form = FPDFDOC_InitFormFillEnviroument(doc, &form_callbacks); + FPDF_FORMHANDLE form = FPDFDOC_InitFormFillEnvironment(doc, &form_callbacks); FPDF_LoadXFA(doc); FPDF_SetFormFieldHighlightColor(form, 0, 0xFFE4DD); FPDF_SetFormFieldHighlightAlpha(form, 100); @@ -357,7 +357,7 @@ void RenderPdf(const char* name, const char* pBuf, size_t len, FORM_DoDocumentAAction(form, FPDFDOC_AACTION_WC); FPDF_CloseDocument(doc); - FPDFDOC_ExitFormFillEnviroument(form); + FPDFDOC_ExitFormFillEnvironment(form); FPDFAvail_Destroy(pdf_avail); printf("Loaded, parsed and rendered %zu pages.\n", rendered_pages); |