function Internal::isEnabled

Checks if this plugin should be enabled based on the editor configuration.

The editor's settingsĀ can be retrieved via $editor->getSettings().

Parameters

\Drupal\editor\Entity\Editor $editor: A configured text editor object.

Return value

bool

Overrides CKEditorPluginContextualInterface::isEnabled

File

core/modules/ckeditor/src/Plugin/CKEditorPlugin/Internal.php, line 84

Class

Internal
Defines the "internal" plugin (i.e. core plugins part of our CKEditor build).

Namespace

Drupal\ckeditor\Plugin\CKEditorPlugin

Code

public function isEnabled(Editor $editor) {
  // This plugin represents the core CKEditor plugins. They're always enabled:
  // its configuration is always necessary.
  return TRUE;
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.