Handle highlight events from emacs
Fix some names. Delete accidentally-duped code. Send highlight events.