Skip to content

Commit

Permalink
end key to end of line
Browse files Browse the repository at this point in the history
  • Loading branch information
kjloveless committed Nov 12, 2024
1 parent da42cdd commit 078b8ef
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -360,7 +360,9 @@ function editorProcessKeypress() {
break;

case EditorKey.END_KEY:
e.cursorX = e.screenCols - 1;
if (e.cursorY < e.numRows) {
e.cursorX = e.row[e.cursorY].length;
}
break;

case EditorKey.PAGE_UP:
Expand Down

0 comments on commit 078b8ef

Please sign in to comment.