API Docs for:
Show:

InkPaper Class

InkPaper

Constructor

InkPaper

(
  • element
  • [options]
  • [callback]
)

Parameters:

  • element Element
  • [options] Object optional
  • [callback] Function optional

    callback function

    • data Object

      The recognition result

    • err Object

      The err to the callback

Methods

_down

(
  • x
  • y
  • [t]
)
private

Parameters:

  • x Number

    X coordinate

  • y Number

    Y coordinate

  • [t] Date optional

    timeStamp

_move

(
  • x
  • y
  • [t]
)
private

Parameters:

  • x Number

    X coordinate

  • y Number

    Y coordinate

  • [t] Date optional

    timeStamp

_move

(
  • x
  • y
  • [t]
)
private

Parameters:

  • x Number

    X coordinate

  • y Number

    Y coordinate

  • [t] Date optional

    timeStamp

canRedo

() Boolean

Return true if you can redo

Returns:

Boolean:

canUndo

() Boolean

Return true if you can undo

Returns:

Boolean:

getAnalyzerParameters

() AnalyzerParameter

Get analyzer recognition parameters

Returns:

AnalyzerParameter:

analyzerParameters

getApplicationKey

() String

Get the application key

Returns:

String:

getAvailableLanguages

(
  • [inputMode]
)

Get available languages

Parameters:

  • [inputMode] String optional

    input mode

getComponents

() Array

Get the default components

Returns:

Array:

components

getHmacKey

() String

Get the HMAC key

Returns:

String:

getInkGrabber

() InkGrabber

Get the ink capturer

Returns:

getMathParameters

() MathParameter

Get math recognition parameters

Returns:

MathParameter:

mathParameters

getMusicParameters

() MusicParameter

Get music recognition parameters

Returns:

MusicParameter:

musicParameters

getPenParameters

() PenParameters

Get pen parameters

Returns:

PenParameters:

penParameters

getShapeParameters

() ShapeParameter

Get shape recognition parameters

Returns:

ShapeParameter:

shapeParameters

getTextParameters

() TextParameter

Get text recognition parameters

Returns:

TextParameter:

textParameters

getTimeout

() Number

Get the recognition timeout

Returns:

Number:

getType

() 'TEXT' | 'MATH' | 'SHAPE' | 'MUSIC' | 'ANALYZER'

Get recognition type

Returns:

'TEXT' | 'MATH' | 'SHAPE' | 'MUSIC' | 'ANALYZER':

type

recognize

() Promise

Recognize

Returns:

Promise:

setAnalyzerParameters

(
  • analyzerParameters
)

Set analyzer recognition parameters

Parameters:

setApplicationKey

(
  • applicationKey
)

Set the application key

Parameters:

  • applicationKey String

setChangeCallback

(
  • callback
)

Set the change callback

Parameters:

  • callback Function

    callback function

    • data Object

      The inkPaper state

setComponents

(
  • components
)

Set the default components

Parameters:

  • components Array

setHeight

(
  • height
)

Set the height

Parameters:

  • height Number

setHmacKey

(
  • hmacKey
)

Set the HMAC key

Parameters:

  • hmacKey String

setMathParameters

(
  • mathParameters
)

Set math recognition parameters

Parameters:

setMusicParameters

(
  • musicParameters
)

Set music recognition parameters

Parameters:

setPenParameters

(
  • penParameters
)

Set pen parameters

Parameters:

setPrecision

(
  • precision
)

Set the recognition precision

Parameters:

  • precision Number

setResultCallback

(
  • callback
)

Set the recognition result callback

Parameters:

  • callback Function

    callback function

    • data Object

      The recognition result

setShapeParameters

(
  • shapeParameters
)

Set shape recognition parameters

Parameters:

setTextParameters

(
  • textParameters
)

Set text recognition parameters

Parameters:

setTimeout

(
  • timeout
)

Set the recognition timeout

Parameters:

  • timeout Number

setType

(
  • type
)

Set recognition type

Parameters:

  • type 'TEXT' | 'MATH' | 'SHAPE' | 'MUSIC' | 'ANALYZER'

setTypeset

(
  • typeset
)

Enable / disable typeset

Parameters:

  • typeset Boolean

setWidth

(
  • width
)

Set the width

Parameters:

  • width Number