Make Chinese and Japanese characters count as word characters
Bring back startStyle and endStyle for marked spans

Closes #918
Added "dirty counter" so we can tell when the user has undone/redone to the last point at which the document was marked clean.
Slightly modify and document markClean/isClean
Add tests for markClean
Don't assume character 0 has x coordinate 0

Closes #921
Prevent overeager caching of line dimensions

Closes #887

The problem was that an empty line was first measured with the editor in a hidden
state, producing dimensions that were all zero. This result was then cached and
reused when the editor was unhidden.
Clear the measureLine cache when refresh() is called

So that one can change the font size, call refresh, and
not have old cached measurements cause artifacts.

Closes #922
Change display patching algorithm

To not require tons of empty DIVs when a section is hidden.

Issue #920
Fix obsolete repaints triggered by option updates
Reduce potential for update queueing on slow browsers

Holding a key would queue up a screen and cursor update (which requires a line measure)
for each character typed. That could cause the display to lag behind the input in a
visible, obvious way.

This still doesn't make responses instant when editing long lines in Opera, but at least
makes the maximum delay bounded to the time a single update takes.
Pass an 'origin' string when making changes
Remove compoundChange API method

Things that happen in a single operation are now always combined into
an undo history event. Subsequent typing or deleting is combined, if
it is close together in time, even when done in separate operations.

Closes #889

Also stores old selection position in undo history, restoring it
when applying a changeset.

Issue #923
Small amendment to 2513434b0e0fbb7

Remove unused code, fix selection resetting
Clip input position to setCursor

So that passing in a bogus position doesn't cause a run-time error
and/or corruption.

Issue #928
Remember cursor positions both before and after undo events

Issue #923
Make setGutterMarker work on the CodeMirror-linenumbers gutter

Closes #926
Add Qt webkit as exception for Ctrl and Cmd key event properties

Just like Opera, it flips the ctrlKey and metaKey on Mac

Closes #924
Switch the linter to Acorn
Feature-detect zero-width space support

Apparently Opera Win *doesn't* handle them properly, whereas Opera
Linux does.

Closes #929