xmlContextChange

This event fires when the cursor is moved to a different node.

var highlightNode;

Editor.addEventListener("xmlContextChange", function(evt)
{  
  if (highlightNode)
    highlightNode.unhighlight();

  highlightNode = evt.newNode;
  if (!highlightNode)
    return;

  if (highlightNode.getNodeType() == 2)
    highlightNode = highlightNode.getOwnerElement();
  else if (highlightNode.getNodeType() != 1)
    highlightNode = highlightNode.getParentNode();

  highlightNode.highlight();
});

xmlContextChange event

Properties

newNode XopusNode
The node that was the result of a split node, or the node that received focus
oldNode XopusNode
The node from which the cursor came.
target Editor
The object that originally fired the event.
type String
The type of the event.