This is a migrated thread and some comments may be shown as answers.

Dynamically adding custom tool to editor

0 Answers 222 Views
Editor
This is a migrated thread and some comments may be shown as answers.
David
Top achievements
Rank 1
David asked on 30 Aug 2012, 04:18 AM
Hi,

Is it possible to dynamically add a custom tool to an existing Kendo UI Editor on the page?

e.g. something similar to:
var myEditor = jQuery("#myEditor").data("kendoEditor");
var registerTool = myEditor.EditorUtils.registerTool, Tool = myEditor.Tool;
registerTool("custom2", new Tool({ name: "custom2", tooltip: "Insert a horizontal rule2", exec: function (e) { .. action here.. ); } }) );

Essentially, we have the Kendo Editor within a user control, but need to change the set of tools available depending on the page that the user control is used upon; hence needing to dynamically add tools to an existing editor.

Thanks
David.

No answers yet. Maybe you can help?

Tags
Editor
Asked by
David
Top achievements
Rank 1
Share this question
or