add Cursor::moveUp/Down to generalize up/down

the idea of the generalized algorithm is:
- first check next and prev, if so prepend/append cursor to them
- else do the equivalent of cursor.parent.bubble('up'/'down', cursor),
  except instead of requiring .up/.down to be a function, it can be
  a MathBlock, and if so,
    + moveUp will appendTo it
    + moveDown will prependTo it
  The idea is to be analogous to how jQuery, when you bind an event
  handler, instead of a function, it can be `false` and jQuery will know
  you meant `function() { return false; }`, while we know you meant
  `function(cursor) { cursor.append/prependTo(theMathBlock); }`.
Fraction set .up and .down props

trivial: in createBlocks, set the .up and .down properties of the
command and child blocks to be the numerator and denominator,
respectively
SupSub set .up and .down props

way more annoying: ignoring the glaring if/else-instead-of-inheritance
anti-pattern, which we'll fix when we figure out an decent architecture
for instantiation of commands with makers instead of bind() and
constructor args (or something),
- we set .up or .down on the SupSub to point to the block, depending on
  whether it's a Sup or a Sub,
- and then we give the block a method that says,
    + on up out of a Sub or down out of a Sup, put the cursor to the
      left of the SupSub (since this is probably the exponent of
      subscript of the thing to the left),
        * unless the cursor is at the end of the SupSub, or at the end
          of something that's at the end of the SupSub, or in general
          at the end of something all of whose ancestors up until the
          SupSub are at the end of their parent blocks

Test cases illustrating why the hell that's desired behavior forthcoming
RootMathBlock::onKey uses cursor.moveUp/Down

now that case 'Up'/'Down' are one-liners, re-arrange so Shift-Up/Down
are together
add test cases for up/down
Merge branch 'dev' into feature.up-down

Conflicts:
	src/commands.js
Merge branch 'dev' into feature.up-down
allow .up and .down to be functions

...and treat the return values the same as plain values.
factor out Cursor::seekHoriz from Cursor::seek

also style changes
use seekHoriz in move{Up,Down}

also factor out the duplicated code between the two methods into the
private moveUpDown.
factor out move{Left,Right}Within from move{Left,Right}
limit seekHoriz to a containing block
make Cursor::offset a private method
deleteSelection *only* deletes the selection

new method .prepareEdit() will delete the selection and show the cursor.

Cursor internal methods now must call .show() manually.
clearSelection now *only* clears the selection.

new method .prepareMove() clears the selection and shows the cursor.

Cursor internal methods must now also call show()
explicitly comment `if (...); // pass`
Cache the point within a containing block on up/down

This cache is cleared on every edit, selection, or movement other than
up/down.  This allows up and down to return to familiar places, and
makes up and down "undo"able actions.
add parser.js

Parser.js is a simple parser combinator library, based loosely on
Haskell's Parsec and jQuery's $.Deferred.
improve parser error messages

failure() now takes a second argument - the message.
ditch CharConditionParser, make CharParser smarter