tinymce.EditorOptions

TinyMCE Editor Options API.

Summary

Methods

Name Summary Defined by

get()

Get the value of a registered option.

EditorOptions

isRegistered()

Check if an option has been registered.

EditorOptions

isSet()

Checks to see if a value has been set for the specified option.

EditorOptions

register()

Register a new option that can be used within TinyMCE.

EditorOptions

set()

Set the value for a registered option.

EditorOptions

unset()

Clear the set value for the specified option and revert back to the default value.

EditorOptions

Methods

get()

get(name: String): Object

Get the value of a registered option.

Parameters

  • name (String) - Name of a registered option.

Return value

  • Object - An option value, the registered default if not set, or undefined if not registered.


isRegistered()

isRegistered(name: String): Boolean

Check if an option has been registered.

Parameters

  • name (String) - Name of the option.

Return value

  • Boolean - True if the option has already been registered, otherwise false.


isSet()

isSet(name: String): Boolean

Checks to see if a value has been set for the specified option.

Parameters

  • name (String) - Name of the option.

Return value

  • Boolean - True if the option has a value set, otherwise false.


register()

register(name: String, spec: OptionSpec)

Register a new option that can be used within TinyMCE.

Parameters

  • name (String) - Name of the option.

  • spec (OptionSpec) - An option spec describing how to validate the option with other optional metadata.


set()

set(name: String): Boolean

Set the value for a registered option.

Parameters

  • name (String) - Name of a registered option.

Return value

  • Boolean - True if the option value was successfully set, otherwise false.


unset()

unset(name: String): Boolean

Clear the set value for the specified option and revert back to the default value.

Parameters

  • name (String) - Name of a registered option.

Return value

  • Boolean - True if the option value was successfully reset, otherwise false.