Skip to content
This repository was archived by the owner on Mar 3, 2023. It is now read-only.

Autoscroll correctly when dragging gutter selections - #8350

Merged
nathansobo merged 1 commit into
masterfrom
ns-fix-autoscroll-on-gutter-selection
Aug 12, 2015
Merged

nathansobo merged 1 commit into
masterfrom
ns-fix-autoscroll-on-gutter-selection

Conversation

@nathansobo

Copy link
Copy Markdown
Contributor

Fixes #2696

  • Explicitly assign the orientation of the selection when it crosses the initially clicked row.
  • Autoscroll to the cursor, not the entire selection.

@nathansobo
nathansobo force-pushed the ns-fix-autoscroll-on-gutter-selection branch from 0c50bf0 to aa31450 Compare August 12, 2015 19:03
* Explicitly assign the orientation of the selection when it crosses
  the initially clicked row.
* Autoscroll to the cursor, not the entire selection.
@nathansobo
nathansobo force-pushed the ns-fix-autoscroll-on-gutter-selection branch from aa31450 to fbea2d7 Compare August 12, 2015 19:13
nathansobo pushed a commit that referenced this pull request Aug 12, 2015
Autoscroll correctly when dragging gutter selections
@nathansobo
nathansobo merged commit ce8b834 into master Aug 12, 2015
@nathansobo
nathansobo deleted the ns-fix-autoscroll-on-gutter-selection branch August 12, 2015 20:32
@izuzak

izuzak commented Aug 13, 2015

Copy link
Copy Markdown
Contributor

👏 Thanks for fixing this, @nathansobo. I was just playing with this and noticed that the problem still happens if you press and hold cmd or shift before select-scrolling 🌵. Would that be an easy followup fix or would it be helpful to open a new issue for this?

@nathansobo

Copy link
Copy Markdown
Contributor Author

I can do a followup.

@nathansobo

Copy link
Copy Markdown
Contributor Author

@atom/feedback As I tested this, I also noticed that selecting with the mouse in the gutter selects entire buffer lines instead of screen lines. This feels a bit counter-intuitive to me and leads to the selections feeling jumpy instead of smooth. What would people think about always selecting screen lines in the gutter?

@mnquintana

Copy link
Copy Markdown
Contributor

What would people think about always selecting screen lines in the gutter?

👍 This would make the most sense to me too

@izuzak

izuzak commented Aug 14, 2015

Copy link
Copy Markdown
Contributor

What would people think about always selecting screen lines in the gutter?

Ahhh, just noticed this comment -- sorry, @nathansobo, I left a note in your PR: #8377 (comment). Would love to hear more thoughts on this and also how other editors behave.

@lee-dohm

Copy link
Copy Markdown
Contributor

I would suggest using screen lines in the case of soft wrap, but in the case of folding, it should use buffer lines.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants