Move the caret to the end of line when soft wrap enabled

I’ve found some discussions about this topic but no usable answer to the problem. Can someone kindly tell me whether (and if yes, then how) can I in Atom move the caret to the hard end of line when I have soft wrap enabled. Key END move me to the end of the wrapped line, not to the actual end of the line. In Sublime Text, moving to the actual end of the line is done by twice pressing the key END but that doesn’t work in Atom. In keybindings, I haven’t found any command that would promise to do this and would be mappable to a key.

To explain this visually - I would like the carret (blue) move to the position at the end of the line (green) while the key END moves me only to the end of the wrapped line (red)


Thanks a lot for your help.

If I understood your description correctly, the editor:move-to-end-of-line command is the behavior you want. To map the command to end, you can add something like this in your keymap file:

 'end': 'editor:move-to-end-of-line'
1 Like

Thanks, I somehow missed that it does exactly what I want. For the future visitors’ reference: Additional Movement and Selection Commands

So my keymap.cson now contains something like this:
‘alt-end’: ‘editor:move-to-end-of-line’
‘alt-home’: ‘editor:move-to-beginning-of-line’