When a spellcheck reaches the end of the document, it is supposed
to be able to continue from the beginning of the document to the
point at which the spellcheck was started.
This was not working in the case where the word at the starting
position was replaced due to a spelling correction, which causes the
starting position to be lost.
Fix this situation by recording the position immediately *before*
the spellcheck starting position, so that it will not be affected
by a spelling correction *at* the starting position.
Reviewed-on: https://gerrit.libreoffice.org/40123Tested-by: Jenkins <firstname.lastname@example.org>
Reviewed-by: Michael Stahl <email@example.com>