-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable nobreak-char-display in view modes #661
Comments
Ah, now I see this won't solve the Eglot problem, since it copies the |
Did you find a solution for this with Eglot? |
Yes, this has been fixed on the Eldoc side. |
I have never used this language server or seen that particular problem. Now, I think this can only be solved on the markdown-mode side. Eglot already renders correctly asterisks that demarcate list items, turning them into |
I see, thank you. From the discussion under the second link I shared it seems the |
This is of course dumb; if there was a good reason to mangle the markdown to the point it's unreadable in the raw, then LSP should support transmitting text as HTML instead. Unfortunately, I see LSP more and more as a VS Code interface that others are invited to use at their own peril than a truly editor-agnostic protocol. |
Sadly, I think you may be right. |
Distinguishing non-breaking spaces and the like is generally not useful in
{markdown,gfm}-view-mode
. So these modes should setnobreak-char-display
to nil by default. Another option would be to tie this setting to the value ofmarkdown-hide-markup
.I encounter this issue often in Eglot's eldoc buffers, which use
gfm-view-mode
to prettify markdown text received from an external process. This markdown sometimes contains lots non-breaking spaces. Note the red undelining in all the indented lines of the screenshot below.Actual Behavior
The global value of
nobreak-char-display
applies to{markdown,gfm}-view-mode
buffers.Steps to Reproduce
In a scratch buffer, enter a non-breaking space (
C-x 8 RET non-breaking space RET
). Thenobreak-space
face will be applied to that character. Now typeM-x gfm-view-mode RET
. Thenobreak-space
face remains, but it should disappear.Backtrace
Not needed.
Software Versions
The text was updated successfully, but these errors were encountered: