OpusScript functions supported in HTML5 Export

 

OpusScript is based on JavaScript familiar to most web developers. Therefore all the syntax and basic features of OpusScript will be usable in your HTML5 publication. Furthermore, any JavaScript can be placed in a script object and will be executed even though it will only work when published and uploaded not when previewed. This allows you to create and run your own custom JavaScript, php or mySQL functions and extend your HTML5 publication in any way you would extend standard HTML web material.

 

Summary of Functionality Not Supported in HTML5 Export

Any functionality not supported via the standard Actions dialog will not be supported in script either. Here is a quick overview of the functionality which is not supported in HTML5 export.

 

 

Reference of Supported Features

 

Function Name:

Category:

Description:

 

Date

A list of all the Date functions

 

Math

A list of all the Math functions

Backward

MultiFrames

Go back one frame

Continue

Slideshow

Continue a Slideshow

Enable

Graphical Objects

Enable or disable this object

ExitPublication

Global

Exit the publication, via an Exit page (if any)

Fade

Graphical Objects

Fade an object by an amount

FindChild

Basic Objects

Finds the child of this object with a particular name

FindDescendent

Basic Objects

Finds the descendent of this object with a particular name

format

Global String

Format a number as a string

Forward

MultiFrames

Go forward one frame

GetChild

Basic Objects

Gets a child of this object by index

GetFirstChild

Basic Objects

Gets the first child of this object

GetHeight

Graphical Objects

Get the height of the object

GetMousePosition

Pages

Get the x and y coordinates of the current mouse position

GetName

Basic Objects

Gets the name of the object

GetNextChild

Basic Objects

Gets the child of this object that follows another

GetNumberChildren

Basic Objects

Gets the number of children of this object

GetParent

Basic Objects

Gets the parent of this object

GetPosition

Graphical Objects

Get the x and y coordinate of the objects position

GetSlide

Slideshow

Get the slide currently visible

GetSlideCount

Slideshow

Count the number of slides in a slideshow

GetState

Buttons

Returns the current state of a push button

GetType

Global

Get the object’s Object Type e.g. button, image etc.

GetUniqueObjectID

Basic Objects

Gets a string that is unique to this object

GetWidth

Graphical Objects

Get the width of the object

GetXPosition

Graphical Objects

Get the x coordinate of the objects position

GetYPosition

Graphical Objects

Get the y coordinate of the objects position

GotoBackwardPage

Global

Go to the previous page in the publication

GotoBookmark

Pages

Go to a specific Bookmark

GotoForwardPage

Global

Go to the next page in the publication

GotoNextPage

Global

Go to the next page in the page history

GotoNextRandomPage

Global

Go to a random page within the chapter without repeating

GotoPreviousPage

Global

Go to the previous page in the page history

GotoRandomPage

Global

Go to a random page within the chapter

GotoSlide

Slideshow

Go to a specific slide

Hide

Graphical Objects

Hide this object

integer

Global String

Convert a value to an integer

IsEnabled

Graphical Objects

Test if this object is enabled

IsObjectIntersecting

Graphical Objects

Test if this object is intersecting another

IsPlaying

Slideshow

Check if a specified Slideshow is playing

IsShowing

Graphical Objects

Test if this object is showing

LaunchURL

Global

Open a URL

length

Global String

Get the length of a string

length

String

The length of the string

Move

Graphical Objects

Move the object by its x and y coordinates

MoveX

Graphical Objects

Move the object by its x coordinate

MoveY

Graphical Objects

Move the object by its y coordinate

Navigate

Browser

Set a URL for the browser

number

Global String

Convert a value to a number

Pause

Slideshow

Pause a Slideshow

Play

Slideshow

Play a Slideshow

Play

Video

Play a specified video

random

Global String

Get a random integer

Rotate

Graphical Objects

Rotate an object by a specified angle

Scale

Graphical Objects

Scale an object horizontally and vertically by a percentage

ScaleH

Graphical Objects

Scale an object horizontally by a percentage

ScaleV

Graphical Objects

Scale an object vertically by a percentage

SetBookmark

Pages

Bookmark the current page

SetPosition

Graphical Objects

Set aspects of the objects position

SetPosition

Sound

Set the current position in seconds for a sound file

SetPositionX

Graphical Objects

Set the x coordinate of the objects position

SetPositionY

Graphical Objects

Set the y coordinate of the objects position

SetRotation

Graphical Objects

Set an objects rotation to a specified angle

SetScale

Graphical Objects

Set the horizontal and vertical scale of an object to a percentage

SetScaleH

Graphical Objects

Set the horizontal scale of an object to a percentage

SetScaleV

Graphical Objects

Set the vertical scale of an object to a percentage

SetState

Buttons

Sets the current state of a push button

SetTransparency

Graphical Objects

Set the objects transparency

Show

Graphical Objects

Show this object

Stop

Slideshow

Stop a Slideshow

StopAnimation

Graphical Objects

Stop an animation

string

Global String

Convert a value to a string

ToEnd

MultiFrames

Go to last frame in the MultiFrame

ToFrame

MultiFrames

Go to a given frame in the MultiFrame

tolower

Global String

Get a lower case version of a string

ToStart

MultiFrames

Go to first frame in the MultiFrame

toupper

Global String

Get an upper case version of a string

TriggerComponentEvent

Event Objects

Activate a Custom Trigger for a specified object.