public function ScaytCKEditorButton::getButtons in CKEditor SpellCheckAsYouType (SCAYT) 8
NOTE: The keys of the returned array corresponds to the CKEditor button names. They are the first argument of the editor.ui.addButton() or editor.ui.addRichCombo() functions in the plugin.js file.
Overrides CKEditorPluginButtonsInterface::getButtons
File
- src/
Plugin/ CKEditorPlugin/ ScaytCKEditorButton.php, line 103
Class
- ScaytCKEditorButton
- Defines the "scayt" plugin.
Namespace
Drupal\ckeditor_scayt\Plugin\CKEditorPluginCode
public function getButtons() {
// Make sure that the path to the image matches the file structure of
// the CKEditor plugin you are implementing.
$version = $this
->getCkEditorVersion();
$path = drupal_get_path('module', 'ckeditor_scayt') . '/dist/scayt/' . $version;
return [
'Scayt' => [
'label' => $this
->t('SCAYT spellchecker'),
'image' => $path . '/icons/scayt.png',
],
];
}