Implement back/forward one word escape sequences in console

OS X-only at the moment, but will support Linux as well. Not sure if Windows uses these escape sequences or not.