japanoise / emsys

ersatz-emacs text editor
MIT License
3 stars 2 forks source link

handle backspace at end of file #9

Closed nicholascarroll closed 2 years ago

nicholascarroll commented 2 years ago

if at the end of file you will be on a new empty line. Then if you press the backspace key, you should move to the end of the previous line, which is the actual last line.

Relevant section of main.c: void editorBackSpace(struct editorBuffer *bufr) {
if (bufr->cy == bufr->numrows){

nicholascarroll commented 2 years ago

Thanks!