Add convenient event methods to all event-emitting objects

i.e. linehandle.on, markedrange.off, etc.
[activeline addon] Don't get confused by collapsed spans

Issue #1668
[smartymixed mode] Add
[smartymixed mode] Integrate
Merge branch 'master' of https://github.com/marijnh/CodeMirror

Conflicts:
	.gitignore