The exec_command_* event is fired when any ExecCommand is executed.
The exec_command_* event is raised when one particular ExecCommand is executed (exec_command_newdoc).
function(state,cmd,value)