Ensure cursor doesn't end up outside of visible window

Closes #738
Implement a new gutter system

- Multiple gutters are explicitly created with the gutters
  option
- Markers go into a specific gutter, new setGutterMarker,
  clearGutter methods
- The line number gutter is separate
- The 'fixedGutter' feature is removed (painful to do now,
  was shaky anyway)
Implement arbitrary-height lines

Experimental for now.
Move to {left,top,bottom} objects throughout

No more random {x,y,yBot} thrown into the mix.
More stable drawing of selection
Also measure a 'right' in measureLine

Get rid of eolSpanContent mess.

Preparation for RTL text handling.
First stab at bi-directional text support

Issue #294
Memoize measureLine
New scrolling model

This will make fixedGutter work properly, and make it the only model
(no more gutter that scrolls out of view).

Also reorganizes the basic css file to be easier to modify for users.

Issue #730
Properly handle leading/trailing whitespace in bidi algorithm
Skip over combining characters when moving through text

Makes Hebrew text mostly usable
Base the callback interface on events

This allows multiple handlers to listen for a single event, and makes
the API a bit more uniform.

Issue #725
[tests] Add test for text-unit motion
Overhaul the folding system

It is now more structured (knows about ranges) and allows automatic
unfolding when the cursor enters the folded range.
Add a change event to lines, use it to make folding more robust
Get rid of eltOffset helper, use getBoundingClientRect directly
Drop unused eltText helper function
Start new z-stacking context in mover div

Prevents styled backgrounds from hiding the selection
Prevent vertical gaps from showing up in selection marker
Move matchBrackets out of the core

Add CodeMirror.defineOption function for defining new options.

Add findMatchingBracket to the methods exported by this extension.

Closes #746