コマンドを扱うオブジェクト。
Methods
-
<static> add(name, description, func)
-
コマンドを追加する。
Parameters:
Name Type Description namestring コマンド名
descriptionstring コマンドの説明
funcfunction 実行する関数
-
<static> addCommandEventFilter(cb)
-
コマンドイベントフィルターを追加する。
Parameters:
Name Type Description cbmodule:silkedit.CommandManager.commandEventFilter コマンドイベントフィルター
-
<static> remove(name)
-
コマンドを削除する。
Parameters:
Name Type Description namestring コマンド名
-
<static> removeCommandEventFilter(cb)
-
コマンドイベントフィルターを削除する。
Parameters:
Name Type Description cbmodule:silkedit.CommandManager.commandEventFilter コマンドイベントフィルター
-
<static> run(name, args)
-
コマンドを実行する。
Parameters:
Name Type Description namestring コマンド名
argsobject 引数
Type Definitions
-
commandEventFilter(event)
-
コマンドイベントフィルターはコマンド実行前に呼びだされる。trueを返すとコマンドを実行しない。
Parameters:
Name Type Description eventobject コマンドイベント
Properties
Name Type Description namestring コマンド名
argsobject コマンド引数
Returns:
trueならコマンドを実行しない。falseなら実行。
- Type
- boolean