Foxit PDF SDK

Public Member Functions | Static Public Attributes | List of all members
FSDK.OFDRenderer Class Reference

## Public Member Functions
| constructor ()
| Constructor.
| constructor (bitmap)
| Constructor, with a bitmap object. More...
| IsEmpty ()
| Check whether current object is empty or not. More...
| Release ()
| Release current OFD renderer object. More...
| SetColorMode (color_mode)
| Set the color mode. More...
| SetContentFlag (content_flag)
| Set the content flag. More...
| StartRender (page, matrix)
| Start to render an OFD page. More...

## Static Public Attributes
static | e_ColorModeMapping
| Map a color value to the color range defined by a background color and a foreground color.
static | e_ColorModeMappingGray
| Map gray/white/black color value to background/foreground; for other colors, no change.
static | e_ColorModeNormal
| Enumeration for rendering color mode. More...
static | e_ContentFlagAllContent
| Enumeration for OFD rendering content flags. More...
static | e_ContentFlagAnnot
| If set, annotations will be rendered.(Excluding highlight annotation and stamp)
static | e_ContentFlagHighLightAnnots
| If set, highlight annotations will be rendered.
static | e_ContentFlagPage
| If set, page content will be rendered.
static | e_ContentFlagStampAnnots
| If set, stamp annotations will be rendered.

## Detailed Description

This class is used to render an OFD page to a bitmap. Please ensure FSDK.Library.InitializeOFDEngine has been called successfully before using this class.

See also
  FSDK.Library

## Member Function Documentation

## ◆ constructor()

FSDK.OFDRenderer.constructor | ( | bitmap |  | ) |

Constructor, with a bitmap object.

Parameters

  [in] | bitmap | A bitmap object. It should not be an empty bitmap.

## ◆ IsEmpty()

FSDK.OFDRenderer.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.

## ◆ Release()

FSDK.OFDRenderer.Release | ( |  | ) |

Release current OFD renderer object.

Please call this function before FSDK.Library.ReleaseOFDEngine to release current OFD renderer object.

Returns
  None.

## ◆ SetColorMode()

FSDK.OFDRenderer.SetColorMode | ( | color_mode |  | ) |

Set the color mode.

Parameters

  [in] | color_mode | Color mode. Please refer to values starting from FSDK.OFDRenderer.e_ColorModeNormal and this should be one of these values. The default value is FSDK.OFDRenderer.e_ColorModeNormal.

Returns
  None.

## ◆ SetContentFlag()

FSDK.OFDRenderer.SetContentFlag | ( | content_flag |  | ) |

Set the content flag.

Parameters

  [in] | content_flag | Content flag. Please refer to values starting from FSDK.OFDRenderer.e_ContentFlagAllContent and this can be one or a combination of these values. The default value is FSDK.OFDRenderer.e_ContentFlagAllContent.

Returns
  None.

## ◆ StartRender()

FSDK.OFDRenderer.StartRender | ( | page | ,
|  | matrix |
| ) |  |

Start to render an OFD page.

This function is used to start to render an OFD page.

Parameters

  [in] | page | An OFD page object. It should not be an empty object.
  [in] | matrix | A matrix for rendering the page, which is usually returned by function FSDK.OFDPage.GetDisplayMatrix.

Returns
  A progressive object. Please check the rate of current progress by function FSDK.Progressive.GetRateOfProgress. If the rate is not 100 yet, call function FSDK.Progressive.Continue to continue the progress until the progress is finished.

## Member Data Documentation

## ◆ e_ColorModeNormal

FSDK.OFDRenderer.e_ColorModeNormal
| static

Enumeration for rendering color mode.

Values of this enumeration should be used alone.Normal color mode.

## ◆ e_ContentFlagAllContent

FSDK.OFDRenderer.e_ContentFlagAllContent
| static

Enumeration for OFD rendering content flags.

Values of this enumeration can be used alone or in combination.If set, all content will be rendered. This value should be used alone.