Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Tune behavior of ignore whitespace on current line #169
Description of the Change
In case test case's intention was not clear, see following illustration what happens on save.
When two editor open same file. Two editor shares same buffer.
case 1: saved when editor1 is active
result: editor1's cursor line was excluded
case 2: saved when editor2 is active
result: editor2's cursor line was excluded
case 3: saved when either editor1 nor editor2 was active
This situation happens when
result: just removed all trailing spaces
Currently same buffer have multiple
So as my understanding making
Users are no longer surprised by trailing WS at cursor line is removed in spite of
@t9md, I tried testing this fix out and I'm not seeing this working...
I added a console.log to ensure that your changes are being used.
I followed the steps in your example and looked at the issue in question. Let me know if I'm missing something.
The behavior you showed in your GIF is expected behavior of this PR.
When editor is saved, right pane is active, so trailing-WS at line1 is preserved, but left pane's cursor line(line2) is NOT preserved since it's not active pane when editor was saved.
I feel this behavior is natural,
In that case, I feel it bug since