diff options
author | Nico Weber <thakis@chromium.org> | 2015-08-04 13:00:21 -0700 |
---|---|---|
committer | Nico Weber <thakis@chromium.org> | 2015-08-04 13:00:21 -0700 |
commit | 9d8ec5a6e37e8d1d4d4edca9040de234e2d4728f (patch) | |
tree | c97037f398d714665aefccb6eb54d0969ad7030c /public/fpdf_progressive.h | |
parent | 780cee82236d1b3b0f9b01a22424e4b8ec9a6f12 (diff) | |
download | pdfium-9d8ec5a6e37e8d1d4d4edca9040de234e2d4728f.tar.xz |
XFA: clang-format all pdfium code.
No behavior change.
Generated by:
find . -name '*.cpp' -o -name '*.h' | \
grep -E -v 'third_party|thirdparties|lpng_v163|tiff_v403' | \
xargs ../../buildtools/mac/clang-format -i
Then manually merged https://codereview.chromium.org/1269223002/
See thread "tabs vs spaces" on pdfium@googlegroups.com for discussion.
BUG=none
Diffstat (limited to 'public/fpdf_progressive.h')
-rw-r--r-- | public/fpdf_progressive.h | 131 |
1 files changed, 78 insertions, 53 deletions
diff --git a/public/fpdf_progressive.h b/public/fpdf_progressive.h index d1bbc401d9..1150349393 100644 --- a/public/fpdf_progressive.h +++ b/public/fpdf_progressive.h @@ -9,89 +9,114 @@ #include "fpdfview.h" -//Flags for progressive process status. -#define FPDF_RENDER_READER 0 -#define FPDF_RENDER_TOBECOUNTINUED 1 -#define FPDF_RENDER_DONE 2 -#define FPDF_RENDER_FAILED 3 - +// Flags for progressive process status. +#define FPDF_RENDER_READER 0 +#define FPDF_RENDER_TOBECOUNTINUED 1 +#define FPDF_RENDER_DONE 2 +#define FPDF_RENDER_FAILED 3 #ifdef __cplusplus extern "C" { #endif +// IFPDF_RENDERINFO interface. +typedef struct _IFSDK_PAUSE { + /** + * Version number of the interface. Currently must be 1. + **/ + int version; -//IFPDF_RENDERINFO interface. -typedef struct _IFSDK_PAUSE -{ - /** - * Version number of the interface. Currently must be 1. - **/ - int version; - - /* - * Method: NeedToPauseNow - * Check if we need to pause a progressive process now. - * Interface Version: - * 1 - * Implementation Required: - * yes - * Parameters: - * pThis - Pointer to the interface structure itself - * Return Value: - * Non-zero for pause now, 0 for continue. - * - */ - FPDF_BOOL (*NeedToPauseNow) (struct _IFSDK_PAUSE* pThis); + /* + * Method: NeedToPauseNow + * Check if we need to pause a progressive process now. + * Interface Version: + * 1 + * Implementation Required: + * yes + * Parameters: + * pThis - Pointer to the interface structure itself + * Return Value: + * Non-zero for pause now, 0 for continue. + * + */ + FPDF_BOOL (*NeedToPauseNow)(struct _IFSDK_PAUSE* pThis); - //A user defined data pointer, used by user's application. Can be NULL. - void* user; + // A user defined data pointer, used by user's application. Can be NULL. + void* user; } IFSDK_PAUSE; // Function: FPDF_RenderPageBitmap_Start -// Start to render page contents to a device independent bitmap progressively. +// Start to render page contents to a device independent bitmap +// progressively. // Parameters: -// 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. -// start_x - Left pixel position of the display area in the bitmap coordinate. -// start_y - Top pixel position of the display area in the bitmap coordinate. +// 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. +// start_x - Left pixel position of the display area in the +// bitmap coordinate. +// start_y - Top pixel position of the display area in the bitmap +// coordinate. // size_x - Horizontal size (in pixels) for displaying the page. // size_y - Vertical size (in pixels) for displaying the page. -// rotate - Page orientation: 0 (normal), 1 (rotated 90 degrees clockwise), -// 2 (rotated 180 degrees), 3 (rotated 90 degrees counter-clockwise). -// flags - 0 for normal display, or combination of flags defined above. -// pause - The IFSDK_PAUSE interface.A callback mechanism allowing the page rendering process +// rotate - Page orientation: 0 (normal), 1 (rotated 90 degrees +// clockwise), +// 2 (rotated 180 degrees), 3 (rotated 90 degrees +// counter-clockwise). +// flags - 0 for normal display, or combination of flags +// defined above. +// pause - The IFSDK_PAUSE interface.A callback mechanism +// allowing the page rendering process // Return value: -// Rendering Status. See flags for progressive process status for the details. +// Rendering Status. See flags for progressive process status for the +// details. // Notes: -// The method cannot not support to render page which the document consists of dynamic XFA fields. +// The method cannot not support to render page which the document +// consists of dynamic XFA fields. // -DLLEXPORT int STDCALL FPDF_RenderPageBitmap_Start(FPDF_BITMAP bitmap, FPDF_PAGE page, int start_x, int start_y, int size_x, - int size_y, int rotate, int flags,IFSDK_PAUSE * pause); +DLLEXPORT int STDCALL FPDF_RenderPageBitmap_Start(FPDF_BITMAP bitmap, + FPDF_PAGE page, + int start_x, + int start_y, + int size_x, + int size_y, + int rotate, + int flags, + IFSDK_PAUSE* pause); // Function: FPDF_RenderPage_Continue // Continue rendering a PDF page. // Parameters: -// page - Handle to the page. Returned by FPDF_LoadPage function. -// pause - The IFSDK_PAUSE interface.A callback mechanism allowing the page rendering process -// to be paused before it's finished. This can be NULL if you don't want to pause. +// page - Handle to the page. Returned by FPDF_LoadPage +// function. +// pause - The IFSDK_PAUSE interface.A callback mechanism +// allowing the page rendering process +// to be paused before it's finished. This can be NULL +// if you don't want to pause. // Return value: -// The rendering status. See flags for progressive process status for the details. +// The rendering status. See flags for progressive process status for +// the details. // Notes: -// The method cannot not support to render page which the document consists of dynamic XFA fields. +// The method cannot not support to render page which the document +// consists of dynamic XFA fields. // -DLLEXPORT int STDCALL FPDF_RenderPage_Continue(FPDF_PAGE page,IFSDK_PAUSE * pause); +DLLEXPORT int STDCALL FPDF_RenderPage_Continue(FPDF_PAGE page, + IFSDK_PAUSE* pause); // Function: FPDF_RenderPage_Close -// Release the resource allocate during page rendering. Need to be called after finishing rendering or +// Release the resource allocate during page rendering. Need to be +// called after finishing rendering or // cancel the rendering. // Parameters: -// page - Handle to the page. Returned by FPDF_LoadPage function. +// page - Handle to the page. Returned by FPDF_LoadPage +// function. // Return value: // NULL // Notes: -// The method cannot not support to render page which the document consists of dynamic XFA fields. +// The method cannot not support to render page which the document +// consists of dynamic XFA fields. // DLLEXPORT void STDCALL FPDF_RenderPage_Close(FPDF_PAGE page); |