Prevent the cursor from moving beyond the end of line. This is the standard for many text editors, including Microsoft editors.