Don't autocorrect on single-quote

DRQS 52056181

Previously, autocorrect was too eager because it treats single-quotes as a word
separator.  So if the user wants to type "hadn't", autocorrect kicks in when
the user enters "'", and it autocorrects the previous word from "hadn" to
"hand", so the user ends up with "hand't".

This commit makes it so that we don't autocorrect on single-quotes.  Instead,
we will wait for the user to complete the word with a space.

This change makes it possible that we autocorrect a word that is not directly
to the left of the caret.  For example, if the user types "hlelo' ", then we
will need to autocorrect the word that is two characters behind the caret.  To
handle these situations, this commit changes the way the selection is modified
before and after SpellingCorrectionCommand to be more resilient as to where the
misspelled word actually is, in relation to the caret position.
Fix spellcheck range when marking old selections

The 'endOfWord' method doesn't work quite right when the caret was just before
a single-quote.  For example, if we had "doesn|'t", then 'startOfWord' returns
the correct position, but 'endOfWord' returns the position after the
single-quote (i.e. the trailing "t" is not included).  This causes "doesn'" to
be marked as a misspelled word.

This commit fixes this issue by giving 'endOfWord' the start of the word, so
that it will scan past the single-quote if the single-quote was actually part
of the word.