howl-editor / howl

The Howl Editor
http://howl.io
Other
712 stars 68 forks source link

Moving cursor left or right when text is selected should jump to end of selection #416

Closed zesterer closed 6 years ago

zesterer commented 6 years ago

When a region of text is selected, moving to the left or to the right should make the cursor jump to the end of that section, such as in the example below:

This is some text
     ^ Cursor starts here

Holding shift and right selects text like so:

This [is some] text
              ^ Cursor is here, text is selected

Pressing right should make the cursor jump to the end of the selection like so:

This is some text
            ^ Cursor should be here

However, the current behaviour places the cursor at the beginning of the selection like so:

This is some text
     ^ Cursor actually ends up here

This is extremely unintuitive behaviour and breaks my workflow (and probably that of other users). It's also not the behaviour used in other editors. I don't know if it's possible to configure Howl to not do this, but I've yet to find a sensible way of configuring it as such.

nilnor commented 6 years ago

That would be extremely unintuitive, but it's not behaviour I recognize. Nor can I reproduce it, neither in master or in the last release. Do you perhaps have some local customizations that causes this? You can run howl from the command line with --no-profile to quickly check the default behaviour.

zesterer commented 6 years ago

After a little experimentation, I can confirm that this issue appears with the --no-profile flag, but that it's also not quite as I initially described. It seems to occur only when text is selected backwards from the initial cursor position, and right is then pressed.

nilnor commented 6 years ago

Yes, that makes more sense. Fixed in master now!