Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Fix preceding boundary calculation for changes inside of folds #212

Merged
merged 1 commit into from Feb 16, 2017

Conversation

nathansobo
Copy link
Contributor

If a change is inside a fold and that fold appears at the beginning of a soft-wrapped line segment, we need to continue iterating upward in our search for a line boundary. Previously we would stop because the screen column was 0, but that is invalid if the beginning of the buffer row isn't on screen due to being folded.

We also think the new logic in findBoundaryPrecedingBufferRow expresses the intent of the method more clearly now.

馃崘d with @as-cii

/cc @maxbrunsfeld

If a change is inside a fold and that fold appears at the beginning of a
soft-wrapped line segment, we need to continue iterating upward in our
search for a line boundary. Previously we would stop because the screen
column was 0, but that is invalid if the beginning of the buffer row
isn't on screen due to being folded.

Signed-off-by: Antonio Scandurra <as-cii@github.com>
@nathansobo nathansobo merged commit 929d465 into master Feb 16, 2017
@nathansobo nathansobo deleted the ns-as-fix-preceding-boundary-search branch February 16, 2017 20:59
nathansobo pushed a commit that referenced this pull request Feb 17, 2017
Fix preceding boundary calculation for changes inside of folds
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.

None yet

1 participant