Ctrl + Arrows: which algorithm or standard?

Is there a consistent algorithm of what should happen when a user presses Ctrl + Left-Arrow or Ctrl + Right-Arrow in a text editor or text editor? I have noticed behavior in the Chrome text box, and Windows Notepad, for example, is not the same; the "go to last / next bit" pattern is similar, but not the same.

I am looking for this information to emulate behavior in my own Chrome / JavaScript-based text editor, as I am not comfortable with how Chrome sometimes does this.

+3
source share
3 answers

The standard action would be to move on to the next non-off-block block of text in any direction (and, as you noticed, this may depend on the context of the โ€œblock without spacesโ€)

+1
source

This is more than browser-dependent inconsistency; it varies across OSes. On Mac OS, Ctrl + Left / Right / Up / Down switches to another space (desktop), so you can not use this as an important key binding if you want to also serve Mac users.

This is more about key binding than algorithm, I just wanted to throw it away. :)

+1
source

. Linux Windows , , .

+1

Source: https://habr.com/ru/post/1721259/


All Articles