Implement first-class docs and linked docs
- Move a lot of methods from the CodeMirror to the Doc prototype - Allow getting, attaching, and copying of Doc objects - Add linkedDoc to create documents that stay in sync - Allow such linked docs to be sub-view on their parent - Rewrite history handling - Remove the concept of a view Documentation still failing.
Add docs for first-class document features, split API section into subsections to make it easier to read.
Fix flaky behavior when undoing after adding a mark
The mark would disappear into thin air if it was on a line affected by the undo (or redo). Now it is properly preserved.
Fix typo in makeChangeSingleDocInEditor
`makeChangeSingleDocInEditor` was throwing exceptions because of the typo.
Use operations for all display updates
Stop passing 'true' as a changeset to updateDisplay, simplify a bunch of things.
Fix for invalid matching symbol in vim keymap.
When the matching symbol of a closing bracket is on a different line, it will match to the incorrect opening bracket. For example, go to http://codemirror.net/demo/vim.html and place the cursor on the closing brace at line 11 and press '%'. It will incorrectly match the opening brace on line 4 instead of the brace on line 8. This patch fixes that by starting the line search at the *end* of the line when searching backwards.
Fix inconsistencies in operation nesting
Operating on line widgets from within an operation would cause crashes.
Add "hide"/"unhide" events for markers
These fire when the marker is removed/resurrected by editing and undo operations. Closes #1093
when checking whether the wrapper element is still part of the DOM, c…
…heck all the way up to the document body
The window.onresize handlers registered for each editor would prevent them from ever getting collected.
Stop using named function expressions
IE<9 does some truly messed-up things when it sees these. Another great JS feature banished for the foreseeable future by the bunglers in Redmont, sigh.
[foldcode addon] Fix off-by-one error when determining brace type in …
…braceRangeFinder Closes #1185
Modified addWidget logic to modify the "near" vertical positioning to…
… default to positioning the element below the position, and added "above" vertical positioning to default to sticking the widget above the pos instead
[addWidget] Restore 'over' vertical position, make the default placem…
…ent below the char again Issue #1189
[scrollTo] Use the curOp.updateScrollPos functionality
This removes some duplicate code, and delays the scrolling to the next display update which makes it less likely to interfere with other actions in unexpected ways.
[matchbrackets addon] Work around IE7 bug
Where it mysteriously makes the editor stop working (typed input no longer goes to textarea) whenever highlighting fires. Issue #1193
There's no guarantee that we'll be able to get the document from the parent link (might not be set). Closes #1199
Make coordsChar take page coordinates again
It had accidentally started taking window coordinates in the 3.0 refactor.