Refactoring the code along with
*The method used to pass boundary() to getRow when cursor was in a nested
 inset. This is wrong and created subtle bugs in the code.
*Cursor::textRow is modified to use the same code, although this should not
 change anything in this case.
*Cursor::setCurrentRow is therefore updated to remove an extra test.
*Some unrelated changes:
- rename row_need_slde to row_moved
- some small code simplifications