Foxit PDF RDK

Public Member Functions | Public Attributes | Static Public Attributes | List of all members
RenditionAction Class Reference
Inheritance diagram for RenditionAction:

## Public Member Functions
| constructor (action)
| Constructor, with parent class object. More...
| GetJavaScript ()
| Get the JavaScript script to be executed. More...
| GetOperationType ()
| Get the operation type of current rendition action when being triggered. More...
| GetRendition (index)
| Get a rendition by index. More...
| GetRenditionCount ()
| Get the count of rendition objects. More...
| GetScreenAnnot ()
| Get the related screen annotation. More...
| InsertRendition (rendition, index)
| Insert a rendition to current rendition action, at the position specified by index. More...
| RemoveRendition (rendition)
| Remove a rendition object from current rendition action. More...
| SetJavaScript (script)
| Set the JavaScript script to be executed. More...
| SetOperationType (op_type)
| Set the operation type of current rendition action when being triggered. More...
| SetScreenAnnot (screen_annot)
| Set related screen annotation. More...
Public Member Functions inherited from Action
| constructor (document, action_dict)
| Constructor, with parameters. More...
| GetDict ()
| Get PDF dictionary of current object. More...
| GetDocument ()
| Get the PDF document, to which current action belongs. More...
| GetSubAction (index)
| Get a sub-action by index. More...
| GetSubActionCount ()
| Get the count of sub-actions. More...
| GetType ()
| Get action type. More...
| InsertSubAction (index, sub_action)
| Insert a new sub-action to the location specified by index. More...
| IsEmpty ()
| Check whether current object is empty or not. More...
| RemoveAllSubActions ()
| Remove all the sub-actions. More...
| RemoveSubAction (index)
| Remove a sub-action, specified by index. More...
| SetSubAction (index, sub_action)
| Set a sub-action by index. More...

## Public Attributes
| e_OpTypePause
| Pause any rendition being played in association with related screen annotation. If no rendition is being played, there is no effect.
| e_OpTypePlay
| Play rendition (which is specified in rendition action), associating it with related screen annotation. If a rendition is already associated with the annotation, resume that rendition if it is paused; otherwise, do nothing.
| e_OpTypeResume
| Resume any rendition being played in association with related screen annotation. If no rendition is being played or the rendition is not paused, there is no effect.

## Static Public Attributes
static | e_OpTypeAssociate
| Associate rendition to related screen annotation. More...
static | e_OpTypeNone
| Enumeration for operation type to perform when the rendition action is triggered. More...
static | e_OpTypeStop
| Stop any rendition being played in association with related screen annotation and remove the association. If no rendition is being played, there is no effect.
Static Public Attributes inherited from Action
static | e_NewWindowFlagFalse
| Enumeration for new window flag. More...
static | e_NewWindowFlagNone
| No "NewWindow" flag.
static | e_NewWindowFlagTrue
| "NewWindow" flag is true.
static | e_TypeGoto
| Action type: go-to action.
static | e_TypeGoTo3DView
| Action type: go-to-3D-view action.
static | e_TypeGoToE
| Action type: embedded go-to action.
static | e_TypeGoToR
| Action type: remote go-to action.
static | e_TypeHide
| Action type: hide action.
static | e_TypeImportData
| Action type: import-data action.
static | e_TypeJavaScript
| Action type: JavaScript action.
static | e_TypeLaunch
| Action type: launch action.
static | e_TypeMovie
| Action type: movie action.
static | e_TypeNamed
| Action type: named action.
static | e_TypeRendition
| Action type: rendition action.
static | e_TypeResetForm
| Action type: reset-form action.
static | e_TypeSetOCGState
| Action type: set-OCG-state action.
static | e_TypeSound
| Action type: sound action.
static | e_TypeSubmitForm
| Action type: submit-form action.
static | e_TypeThread
| Action type: thread action.
static | e_TypeTrans
| Action type: transition action.
static | e_TypeUnknown
| Enumeration for action type. More...
static | e_TypeURI
| Action type: uniform resource identifier (URI) action.

## Additional Inherited Members
Static Public Member Functions inherited from Action
static | Create (document, action_type)
| Create a new action, for specified action type. More...

## Detailed Description

Rendition action is to control the playing of multimedia content. (For more details, please refer to <PDF Reference 1.7> P668 "Rendition Actions") Class RenditionAction is derived from Action and offers functions to get/set rendition action data.

See also
  Action

## Member Function Documentation

## ◆ constructor()

RenditionAction.constructor | ( | action |  | ) |

Constructor, with parent class object.

Parameters

  [in] | action | Parent class object.

## ◆ GetJavaScript()

RenditionAction.GetJavaScript | ( |  | ) |

Get the JavaScript script to be executed.

As a useful rendition action, it should contain a JavaScript script to be executed or is specified an operation type to be performed when triggered. If both JavaScript script and operation type exist, application should execute JavaScript; if application is unable to execute JavaScript script, then perform as operation type defines. If no JavaScript script and operation type is invalid, that means the action is invalid.

Returns
  A JavaScript script.

## ◆ GetOperationType()

RenditionAction.GetOperationType | ( |  | ) |

Get the operation type of current rendition action when being triggered.

As a useful rendition action, it should contain a JavaScript script to be executed or is specified an operation type to be performed when triggered. If both JavaScript script and operation type exist, application should execute JavaScript; if application is unable to execute JavaScript script, then perform as operation type defines. If no JavaScript script and operation type is invalid, that means the action is invalid.

Returns
  Operation type. Please refer to values starting from RenditionAction.e_OpTypeNone and this would be one of these values.

## ◆ GetRendition()

RenditionAction.GetRendition | ( | index |  | ) |

Get a rendition by index.

Parameters

  [in] | index | Index of rendition object to be retrieved. Valid range: from 0 to (count-1). count is returned by function RenditionAction.GetRenditionCount.

Returns
  A rendition object.

## ◆ GetRenditionCount()

RenditionAction.GetRenditionCount | ( |  | ) |

Get the count of rendition objects.

Returns
  The count of rendition objects.

## ◆ GetScreenAnnot()

RenditionAction.GetScreenAnnot | ( |  | ) |

Get the related screen annotation.

Returns
  A screen annotation object.

## ◆ InsertRendition()

RenditionAction.InsertRendition | ( | rendition | ,
|  | index |
| ) |  |

Insert a rendition to current rendition action, at the position specified by index.

Rendition object is necessary for a rendition action when operation type is RenditionAction.e_OpTypeAssociate or RenditionAction.e_OpTypeAssociate.

Parameters

  [in] | rendition | A rendition object to be inserted.
  [in] | index | Index that specifies where to insert the rendition object. If index is below 0 or bigger than (count-1), the input rendition will be inserted to be the end. count is returned by function RenditionAction.GetRenditionCount.

Returns
  None.

## ◆ RemoveRendition()

RenditionAction.RemoveRendition | ( | rendition |  | ) |

Remove a rendition object from current rendition action.

Parameters

  [in] | rendition | A rendition object to be removed from current rendition action.

Returns
  None.

## ◆ SetJavaScript()

RenditionAction.SetJavaScript | ( | script |  | ) |

Set the JavaScript script to be executed.

As a useful rendition action, it should contain a JavaScript script to be executed or is specified an operation type to be performed when triggered. If both JavaScript script and operation type exist, application should execute JavaScript; if application is unable to execute JavaScript script, then perform as operation type defines. If no JavaScript script and operation type is invalid, that means the action is invalid.

Parameters

  [in] | script | A JavaScript script to be set.

Returns
  None.

## ◆ SetOperationType()

RenditionAction.SetOperationType | ( | op_type |  | ) |

Set the operation type of current rendition action when being triggered.

As a useful rendition action, it should contain a JavaScript script to be executed or is specified an operation type to be performed when triggered. If both JavaScript script and operation type exist, application should execute JavaScript; if application is unable to execute JavaScript script, then perform as operation type defines. If no JavaScript script and operation type is invalid, that means the action is invalid.

Parameters

  [in] | op_type | Operation type. Please refer to values starting from RenditionAction.e_OpTypeAssociate and this should be one of these values. If set value RenditionAction.e_OpTypeNone, that means no operation type is specified.

Returns
  None.

## ◆ SetScreenAnnot()

RenditionAction.SetScreenAnnot | ( | screen_annot |  | ) |

Set related screen annotation.

This property is necessary when operation type is set with valid value.

Parameters

  [in] | screen_annot | A screen annotation object to be set as related screen annotation.

Returns
  None.

## Member Data Documentation

## ◆ e_OpTypeAssociate

RenditionAction.e_OpTypeAssociate
| static

Associate rendition to related screen annotation.

If no rendition is associated with related screen annotation, play rendition (which is specified in rendition action), associating it with the annotation. If a rendition is already associated with related screen annotation, it is stopped, and the new rendition (which is specified in rendition action) is associated with the annotation.

## ◆ e_OpTypeNone

RenditionAction.e_OpTypeNone
| static

Enumeration for operation type to perform when the rendition action is triggered.

Values of this enumeration should be used alone.

No operation is specified.