FoxitPDFSDKforWeb  v10.0.0
Foxit PDF SDK for Web

It's a module that contains some utility classes which encapsulates common operations such as Unit object processor. More...

Classes

class  Color
 Class for processing color-related algorithms such as conversions. More...
 

Functions

function getRanges (intervals)
 Get the number range. More...
 
function getUnitByName (unitName)
 Get the unit object by the unit name. More...
 
function setThemeColor (colorInfo)
 Set custom theme color. More...
 

Detailed Description

It's a module that contains some utility classes which encapsulates common operations such as Unit object processor.

Function Documentation

◆ getRanges()

function getRanges (   intervals)

Get the number range.

Parameters
intervalsArray<[number,number]|number> -
function example(){
var getRanges = PDFViewCtrl.shared.getRanges;
getRanges([0,2],4,5) // [0, 1, 2, 4, 5]
}
Returns
number[] -
Since
8.2.0

◆ getUnitByName()

function getUnitByName (   unitName)

Get the unit object by the unit name.

Since
8.0.0
function example(){
var getUnitByName = PDFViewCtrl.shared.getUnitByName;
var unit = getUnitByName('inch')
}
Parameters
unitNamestring
Returns
Unit -

◆ setThemeColor()

function setThemeColor (   colorInfo)

Set custom theme color.

Parameters
colorInfoObject[] - The color objects array.
colorInfo[].domHTMLElement|string - The target DOM element. The default value is document.body.
colorInfo[].colorsObject - The color object.
Since
9.2.0
dom: document.body,
colors: {
background: '#000000',
}
}])

Foxit Software Corporation Logo
@2024 Foxit Software Incorporated. All rights reserved.