Virtualtext formatting and alignment fixes#4473
Virtualtext formatting and alignment fixes#4473hsanson merged 1 commit intodense-analysis:masterdense-analysis/ale:masterfrom
Conversation
w0rp
left a comment
There was a problem hiding this comment.
Could you do the following?
- Add videos or GIFs into the PR description to show a "before" and "after" for the changes.
- Localise the new blocks of code into a new function or two to stop functions getting any larger.
- Add comments in code to explain what the new code is doing.
- Add Vader tests for code where you can. See:
test/test_virtualtext.vader. - Change text alignment to only be applied when a new settings are enabled. I may want this on or off by default.
- Add documentation for the new settings and how they work.
- Set default values for new settings.
Aligning text is a good idea. In my editor, I want all warnings and errors to appear at the end of lines, but not so far to the right that they don't fit on the screen. If you see a file full of errors... fix the file so that doesn't happen, or turn the linter off.
|
Screenshots added. I hope they are ok.
As you can see, a few characters in javascript, and you have pages of errors, going backwards and forwards in the file. |
|
The GIFs look good. 👍 The other issue I linked in the issue covers cleaning up spam from linters. |
f46fd2b to
c1b77a6
Compare
Added support for buffer local settings, and setting column as a percentage of window width. I can run the existing tests ok, but I'm not sure what tests I can add. |
|
Can't wait for this! |
hsanson
left a comment
There was a problem hiding this comment.
Good improvement to visuals and I have confirmed it does not break things at least on my side. We can think about tests latter.
Example implementation of the enhancement described in #4472
This include minimum and maximum columns expected for messages to start, and filtering to ensure only
one error appears per line of code.
This change converts this:
To this: