Class PlgEditorCodemirror

Description

CodeMirror Editor Plugin.

  • since: 1.6

Located in /plugins/editors/codemirror/codemirror.php (line 19)

JObject
   |
   --JEvent
      |
      --JPlugin
         |
         --PlgEditorCodemirror
Variable Summary
 mixed $_basePath
Method Summary
 string onDisplay (string $name, string $content, string $width, string $height, integer $col, integer $row, [boolean $buttons = true], [string $id = null], [string $asset = null], [object $author = null], [array $params = array()])
 string onGetContent (string $id)
 boolean onGetInsertMethod ()
 string onInit ()
 string onSave (string $id)
 string onSetContent (string $id, string $content)
 string _displayButtons (string $name, mixed $buttons, string $asset, object $author)
Variables
mixed $_basePath = 'media/editors/codemirror/' (line 24)

Base path for editor files

  • access: protected

Inherited Variables

Inherited from JPlugin

JPlugin::$autoloadLanguage
JPlugin::$params
JPlugin::$_name
JPlugin::$_type

Inherited from JEvent

JEvent::$_subject

Inherited from JObject

JObject::$_errors
Methods
onDisplay (line 120)

Display the editor area.

  • return: HTML Output
  • access: public
string onDisplay (string $name, string $content, string $width, string $height, integer $col, integer $row, [boolean $buttons = true], [string $id = null], [string $asset = null], [object $author = null], [array $params = array()])
  • string $name: The control name.
  • string $content: The contents of the text area.
  • string $width: The width of the text area (px or %).
  • string $height: The height of the text area (px or %).
  • integer $col: The number of columns for the textarea.
  • integer $row: The number of rows for the textarea.
  • boolean $buttons: True and the editor buttons will be displayed.
  • string $id: An optional ID for the textarea (note: since 1.6). If not supplied the name is used.
  • string $asset: Unused
  • object $author: Unused
  • array $params: Associative array of editor parameters.
onGetContent (line 61)

Get the editor content.

  • return: Javascript
  • access: public
string onGetContent (string $id)
  • string $id: The id of the editor field.
onGetInsertMethod (line 84)

Adds the editor specific insert method.

  • access: public
boolean onGetInsertMethod ()
onInit (line 31)

Initialises the Editor.

  • return: JavaScript Initialization string.
  • access: public
string onInit ()
onSave (line 49)

Copy editor content to form field.

  • return: Javascript
  • access: public
string onSave (string $id)
  • string $id: The id of the editor field.
onSetContent (line 74)

Set the editor content.

  • return: Javascript
  • access: public
string onSetContent (string $id, string $content)
  • string $id: The id of the editor field.
  • string $content: The content to set.
_displayButtons (line 337)

Displays the editor buttons.

  • return: HTML
  • access: protected
string _displayButtons (string $name, mixed $buttons, string $asset, object $author)
  • string $name: The editor name
  • mixed $buttons: [array with button objects | boolean true to display buttons]
  • string $asset: The object asset
  • object $author: The author.

Inherited Methods

Inherited From JPlugin

 JPlugin::__construct()
 JPlugin::loadLanguage()

Inherited From JEvent

 JEvent::__construct()
 JEvent::update()

Inherited From JObject

 JObject::__construct()
 JObject::def()
 JObject::get()
 JObject::getError()
 JObject::getErrors()
 JObject::getProperties()
 JObject::set()
 JObject::setError()
 JObject::setProperties()
 JObject::__toString()

Documentation generated on Tue, 19 Nov 2013 14:56:03 +0100 by phpDocumentor 1.4.3