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

Select buffer lines when clicking the gutter, not screen lines - #5814

Merged
nathansobo merged 3 commits into
masterfrom
iz-gutter-click-select-whole-soft-wrapped-line
Mar 3, 2015
Merged

nathansobo merged 3 commits into
masterfrom
iz-gutter-click-select-whole-soft-wrapped-line

Conversation

@izuzak

@izuzak izuzak commented Mar 3, 2015

Copy link
Copy Markdown
Contributor

Fixes #5738:

  • d21ae2c modifies the click handlers for the gutter to select buffer lines, rather than screen lines. Clicking the gutter for any screen line of a wrapped buffer line selects the whole buffer line (previously, only the clicked screen line would have been selected).
  • 03a064b adds more tests for checking how click handlers for the gutter behave when soft wrap is turned on (I duplicated all the existing tests, turned on soft wrap, and then tweaked them to test the new functionality).

Before 📺 (notice screen lines being selected):

1

After 📺 (notice buffer lines being selected):

gutter

cc @nathansobo for 👀

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are excellent, thorough tests!

@nathansobo

Copy link
Copy Markdown
Contributor

Kicked CI again to see if the build failures were a fluke. The code looks good to me. Thanks for taking care of this @izuzak. You are a champion.

nathansobo pushed a commit that referenced this pull request Mar 3, 2015
…wrapped-line

Select buffer lines when clicking the gutter, not screen lines
@nathansobo
nathansobo merged commit b20eaa0 into master Mar 3, 2015
@nathansobo
nathansobo deleted the iz-gutter-click-select-whole-soft-wrapped-line branch March 3, 2015 14:58
@nathansobo

Copy link
Copy Markdown
Contributor

👏

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.

Clicking the gutter for soft-wrapped lines selects the physical line instead of the logical line

2 participants