SCEditor

keyDown()

keyDown(func) Since: 1.4.1

Binds a handler to the key down event on the editor.

Syntax

instance.keyDown(func[, excludeWysiwyg][, excludeSource]);

Parameters

func
Type Function

Function that will be called when the event occurs

excludeWysiwyg
Type: Boolean
Default: false

If to not bind the event to the WYSIWYG editor.

excludeSource
Type: Boolean
Default: false

If to not bind the event to the source editor.

Return

Type: sceditor

Example

var textarea = ...;
sceditor.instance(textarea).keyDown(function(e) {
	alert('Key down event fired.');
});