Mouse highlight from last location


#1

This may be a personal preference, however when I’m using the mouse to highlight a section of code. It seems to have picked up the highlighting style where you press shift to use the current location, and end at the new location that is selected, instead of highlighting from where I place the cursor and drag.


#2

Yep … I’ve confirmed this behavior in v0.73.0.

Why are you holding down shift when highlighting with the mouse? Is there something else you’re expecting to happen? I notice that similar behavior to what Atom does happens in Apple Mail when editing a message.


#3

In a lot of editors (actually just about anywhere), if you click your cursor into a location, hold down shift, then click on another location, all the text between those two locations will be highlighted. I use this when I’m mass highlighting texts over large sections of code or web pages since the scrolling sometimes affects the highlighting.

Regarding the Apple Mail thing… Interesting. I don’t actually use that as a client, but if they have the same behaviour then it’s possible Atom is trying to follow Apple Mail’s structure.


#4

I never knew this, but I can see how it would be useful. I just tested this in Atom and it works the way you describe.

So we have two ways of selecting text that involve the mouse:

  1. Click and drag
  2. Click → Hold Shift → Click

I’ve confirmed that both of these work as expected.

But it sounds like in your original mail that you were doing a third one? Click → Hold Shift → Click and drag? If so, what did you expect to happen?


#5

I meant that if the cursor is already somewhere on the page, but I want to select code from another section by clicking, then dragging, the mouse to select the area I want to select, then it doesn’t work the way I’m used to. Instead of dragging from the location I select with my mouse, it selects the text between the original location and the mouses new location.


#6

I can confirm that clicking in one part of a page to set the cursor at the “start” of an intended selection, holding shift, then clicking at the “end” (after scrolling a bit) of the intended selection will select all text between the start and end locations.

This does not, however, work as in Sublime Text, which simply expands your selection every time you shift-click outside it, rather than re-set your “end” position.