feat(view): render soft-wrap indicators in the gutter#14825
Open
matoous wants to merge 1 commit intohelix-editor:masterfrom
Open
feat(view): render soft-wrap indicators in the gutter#14825matoous wants to merge 1 commit intohelix-editor:masterfrom
matoous wants to merge 1 commit intohelix-editor:masterfrom
Conversation
ea55858 to
98f1cca
Compare
Member
the-mikedavis
left a comment
There was a problem hiding this comment.
I like the look of the wrap indicator in the gutter. Do you have an opinion on this @pascalkuthe
| pub tab_width: u16, | ||
| pub max_wrap: u16, | ||
| pub max_indent_retain: u16, | ||
| pub wrap_indicator: Box<str>, |
Member
There was a problem hiding this comment.
I wonder if we would want to keep this field and just set it to "" for now? I'm not sure what we would use it for in the future but the document formatter is meant to be flexible enough to be used for reflowing and other uses than rendering
Contributor
Author
|
@pascalkuthe if you please find a few minutes, your thoughts on this change would be greatly appreciated 🙇 |
Moves the soft-wrap indicator into the gutter to keep the text flush and take an advantage of otherwise empty space. Fixes: helix-editor#14802
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Moves the soft-wrap indicator into the gutter to keep the text flush and take an advantage of otherwise empty space.
Alternative approach would be to keep the
wrap_indicatorinTextFormatbut use it for only e.g. diagnostics but not soft wraps. Open for suggestions.Fixes: #14802
Didn't notice that there's already #14818, so this is pretty much the same thing, minus extra configuration options to keep things simple.
Before:
After: