API Docs for: 0.99.4
Show:

JXG Class

Module: JXG

Methods

debug

(
  • s
)

Defined in src/jxg.js:297

Add something to the debug log. If available a JavaScript debug console is used. Otherwise we're looking for a HTML div with id "debug". If this doesn't exist, too, the output is omitted.

Parameters:

  • s Object

    An arbitrary number of parameters.

See also:

debugInt

(
  • s
)

Defined in src/jxg.js:240

Add something to the debug log. If available a JavaScript debug console is used. Otherwise we're looking for a HTML div with id "debug". If this doesn't exist, too, the output is omitted.

Parameters:

  • s Object

    An arbitrary number of parameters.

See also:

debugLine

(
  • s
)

Defined in src/jxg.js:281

TODO

Parameters:

debugWST

(
  • s
)

Defined in src/jxg.js:261

Add something to the debug log. If available a JavaScript debug console is used. Otherwise we're looking for a HTML div with id "debug". If this doesn't exist, too, the output is omitted. This method adds a stack trace (if available).

Parameters:

  • s Object

    An arbitrary number of parameters.

See also:

deprecated

(
  • what
  • [replacement]
)

Defined in src/jxg.js:206

This method issues a warning to the developer that the given function is deprecated and, if available, offers an alternative to the deprecated function.

Parameters:

  • what String

    Describes the function that is deprecated

  • [replacement] String optional

    The replacement that should be used instead.

extend

(
  • object
  • extension
  • [onlyOwn=false]
  • [toLower=false]
)

Defined in src/jxg.js:72

Copy all properties of the extension object to object.

Parameters:

  • object Object
  • extension Object
  • [onlyOwn=false] Boolean optional

    Only consider properties that belong to extension itself, not any inherited properties.

  • [toLower=false] Boolean optional

    If true the keys are convert to lower case. This is needed for visProp, see JXG#copyAttributes

getRef

(
  • board
  • s
)
Object deprecated

Defined in src/jxg.js:180

Deprecated: Use {@link JXG.Board#select}

s may be a string containing the name or id of an element or even a reference to the element itself. This function returns a reference to the element. Search order: id, name.

Parameters:

  • board JXG.Board

    Reference to the board the element belongs to.

  • s String

    String or reference to a JSXGraph element.

Returns:

Object:

Reference to the object given in parameter object

getReference

() deprecated

Defined in src/jxg.js:195

Deprecated: Use {@link JXG.Board#select}.

This is just a shortcut to undefined.

registerElement

(
  • element
  • creator
)

Defined in src/jxg.js:129

This registers a new construction element to JSXGraph for the construction via the undefined interface.

Parameters:

  • element String

    The elements name. This is case-insensitive, existing elements with the same name will be overwritten.

  • creator Function

    A reference to a function taking three parameters: First the board, the element is to be created on, a parent element array, and an attributes object. See {@link JXG.createPoint} or any other JXG.create... function for an example.

shortcut

(
  • object
  • fun
)
Function

Defined in src/jxg.js:165

Creates a shortcut to a method, e.g. JXG.Board#createElement is a shortcut to JXG.Board#create. Sometimes the target is undefined by the time you want to define the shortcut so we need this little helper.

Parameters:

  • object Object

    The object the method we want to create a shortcut for belongs to.

  • fun String

    The method we want to create a shortcut for.

Returns:

Function:

A function that calls the given method.

warn

(
  • warning
)

Defined in src/jxg.js:224

Outputs a warning via console.warn(), if available. If console.warn() is unavailable this function will look for an HTML element with the id 'warning' and append the warning to this element's innerHTML.

Parameters:

  • warning String

    The warning text

Properties

boards

Object

Defined in src/jxg.js:103

Store a reference to every board in this central list. This will at some point replace JXG.JSXGraph.boards.

elements

Object

Defined in src/jxg.js:120

Associative array that keeps track of all constructable elements registered via undefined.

readers

Object

Defined in src/jxg.js:112

Store the available file readers in this structure.