Initial changes for REPLACE mode
Pulled out the replace_iter() function
Cursor x correction in replace mode
REPLACE sets buffer modified
Updated TODOs in replace
Handle REPLACE of newline