Global events are initiated by RichTextEditor whenever the event to which they refer occurs, regardless of the action that triggered the event.

The following is a list of available global application events, and in the order in which they occurs:

Event Description
function RichTextEditor_OnLoader(loader)
{
}
This event is invoked immediately after the loader of RichTextEditor is initialized. You can get configuration information from the loader, execute custom actions to change the configuration.

Example:

<script type='text/javascript'>
function RichTextEditor_OnLoader(loader)
{
	var config=loader._config;
	config.showrulers=true;
	config.showbottombar=false;
	config.skin="office2010blue";
}
</script>
function RichTextEditor_OnCoreLoad(loader)
{
}
This event is invoked immediately after the script library(jsml,core.js) of RichTextEditor is loaded.

Example:

<script type='text/javascript'>
function RichTextEditor_OnCoreLoad(loader)
{
}
</script>
function RichTextEditor_OnLoad(editor)
{
}
This event is invoked immediately after the RichTextEditor is fully loaded.

Example:

<script type='text/javascript'>
function RichTextEditor_OnLoad(loader)
{
}
</script>
function RichTextEditor_OnTextChanged(editor)
{
}
This event is raised if the content of RichTextEditor is changed by either a programmatic modification or user interaction.

Example:

<script type='text/javascript'>
function RichTextEditor_OnTextChanged(loader)
{
}
</script>
function RichTextEditor_OnPasteFilter(editor,info)
{
}
This event is raised before the data is pasted into RichTextEditor. It allows you intercept the paste function and filter the content being pasted.

Example:

<script type='text/javascript'>
function RichTextEditor_OnPasteFilter(editor,info)
{
	var html=info.Arguments[0];
	var cmd=info.Arguments[1];
	info.ReturnValue="<br/>You fire "+cmd+" to paste {<hr/>"+html+"<hr/>}.";
}
</script>
RichTextEditor_OnDispose This event occurs immediately when a RichTextEditor is removed successfully.
RichTextEditor_SelectionChanged This event is raised if the actual selection in the editor area changes.
RichTextEditor_OnTabModeChanged This event is raised when switching between edit, code, and preview mode.
RichTextEditor_OnUpdateUI This event is raised when the editor updates the user interface state.
RichTextEditor_OnInitEvent This event is raised after the iframe document of the editor is reset. You can use it to initialize the iframe document or attach events to the DOM in iframe.
RichTextEditor_OnUninitEvent This event is raised before the iframe document of the editor is reset. You can use it to dispose all registered DOM elements before OnInitEvent occurs.
RichTextEditor_OnPreCut This event is raised when starting to copy content in the editor. If ReturnValue=false, the action is canceled.
RichTextEditor_OnPreCopy This event is raised when starting to cut content in the editor. If ReturnValue=false, the action is canceled.
RichTextEditor_OnExecCommand This event is raised when ExecCommand is executed.
RichTextEditor_OnExecUICommand This event is raised when ExecUICommand is executed.
RichTextEditor_OnFullScreenChanged This event is raised when switching to fullscreen mode.

Send feedback about this topic to CuteSoft. © 2003 - 2014 CuteSoft Components Inc. All rights reserved.