window: read_key: move cursor back to position it was at before helper function call