Yup. Followed the guide and got the Abbreviation plugin added in (just playing around with http://docs.ckeditor.com/#!/guide/plugin_sdk_sample_1).
In CMSPlugins object in plugin.js
// Insert Abbr
pluginAbbr: function (editor) {
editor.addCommand('abbrDialog', new CKEDITOR.dialogCommand('abbrDialog'));
editor.ui.addButton('Abbr', {
label: 'Insert Abbreviation',
command: 'abbrDialog',
toolbar: 'insert',
icon: editor.config.CMSPluginUrl + "images/Abbr.png"
});
CKEDITOR.dialog.add('abbrDialog', function (editor) {
return {
title: 'Abbreviation Properties',
minWidth: 400,
minHeight: 200,
contents: [
{
id: 'tab-basic',
label: 'Basic Settings',
elements: [
{
type: 'text',
id: 'abbr',
label: 'Abbreviation',
validate: CKEDITOR.dialog.validate.notEmpty("Abbreviation field cannot be empty")
},
{
type: 'text',
id: 'title',
label: 'Explanation',
validate: CKEDITOR.dialog.validate.notEmpty("Explanation field cannot be empty")
}
]
},
{
id: 'tab-adv',
label: 'Advanced Settings',
elements: [
{
type: 'text',
id: 'id',
label: 'Id'
}
]
}
],
onOk: function () {
var dialog = this;
var abbr = editor.document.createElement('abbr');
abbr.setAttribute('title', dialog.getValueOf('tab-basic', 'title'));
abbr.setText(dialog.getValueOf('tab-basic', 'abbr'));
var id = dialog.getValueOf('tab-adv', 'id');
if (id)
abbr.setAttribute('id', id);
editor.insertElement(abbr);
}
};
});
},
Then in afterInit() add in a call to your pluginAbbr();
this.pluginAbbr(a);
Then add the plugin into config.js toolbar configuration (see 'Abbr'):
config.toolbar_Full = config.toolbar_Default =
[
['Source', '-'],
['Cut', 'Copy', 'Paste', 'PasteText', 'PasteFromWord', 'SpellChecker', 'Scayt', '-'],
['Undo', 'Redo', 'Find', 'Replace', 'RemoveFormat', '-'],
['Bold', 'Italic', 'Underline', 'Strike', 'Subscript', 'Superscript', '-'],
['NumberedList', 'BulletedList', 'Outdent', 'Indent', 'Blockquote', 'CreateDiv', '-'],
['JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock', '-'],
['InsertLink', 'Unlink', 'Anchor', '-'],
['InsertImageOrMedia', 'QuicklyInsertImage', 'Table', 'HorizontalRule', 'SpecialChar', '-'],
['InsertForms', 'InsertPolls', 'InsertRating', 'InsertYouTubeVideo', 'InsertWidget', '-'],
['Styles', 'Format', 'Font', 'FontSize'],
['TextColor', 'BGColor', '-'],
['InsertMacro', '-'],
['Maximize', 'ShowBlocks'],
['Abbr']
];
Haven't played with UI Personalization yet but will try that next.
MK