several bugfixes in saving/loading cursor position

Created by  Kartik K. Agaram  on June 8, 2023
SW7BSBMJZLUDRMHO2HMCHQW6PPGCEBL4JSDTAHVYPCZLBEKY54XQC
Change contents