You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When the hover content is really narrow, the rendered markdown is wider than the window width and introduces a line break. This means I have to go into the hover window to see what it wants to show me.
Here is a screenshot of the issue:
typescript
↪
Here is a screenshot of the hover buffer contents:
\`\`\`typescript
const key: string
\`\`\`
(The cursor is on the first line in the first column. The closing backticks for the code block are off-screen.)
The issue seems to be only the first line. When I put my cursor there or scroll it off-screen, everything works as expected.
Expected behavior
The first line should be narrow enough, that it does not break across lines.
Healthcheck output
==============================================================================
render-markdown: 1 ⚠️
render-markdown.nvim [version] ~
- ✅ OK plugin 8.3.5
- ✅ OK neovim >= 0.11
render-markdown.nvim [configuration] ~
- ✅ OK valid
render-markdown.nvim [treesitter] ~
- ✅ OK markdown: parser installed
- ✅ OK markdown_inline: parser installed
- ✅ OK latex: parser installed
- ✅ OK html: parser installed
- ✅ OK markdown: highlight enabled
render-markdown.nvim [icons] ~
- ✅ OK using: mini.icons
render-markdown.nvim [executables] ~
- ⚠️ WARNING latex2text: not installed
- ADVICE:
- Disable latex support to avoid this warning
- require('render-markdown').setup({ latex = { enabled = false } })
render-markdown.nvim [conflicts] ~
- ✅ OK headlines: not installed
- ✅ OK markview: not installed
- ✅ OK obsidian: not installed
Plugin configuration
DefaultConfiguration
Plugin error log
N/A
Confirmations
I have updated this plugin to the latest version using my plugin manager
I have provided the text contained in all screenshots as raw text in this issue. This means if there is a screenshot below it is the copy pasted contents of the file in the screenshot. I understand that my issue will be closed if I have not.
Additional information
No response
The text was updated successfully, but these errors were encountered:
## Details
Issue: #408
For narrow windows adding the language icon above code blocks can lead
to text wrapping which will lead to an extra line under the code block.
There are really only 2 ways to fix this:
1. Increase the window width such that it is wide enough to avoid wrapping.
2. Disable line wrapping.
In the first case we end up needing to accurately calculate the width we
need to avoid the line wrapping and also check that the new width does
not cause the window to flow out of bounds. There's lots of edge cases
to these and the end result doesn't look particularly great since it'll
add extra space off the side of these narrow doc buffers.
So instead we take the much simpler approach of disabling line wrapping
on these buffers, however we do this only when the content in the buffer
does not need line wrapping, i.e. the width of the longest line is <=
the width of the window. This should work for most situations but I'm
sure there will be some edge cases to it.
Neovim version (nvim -v)
v0.12.0-dev-197+g1dbede5b93
Neovim distribution
N/A
Operating system
Windows 11
Terminal emulator / GUI
WezTerm / Neovide
Describe the bug
When the hover content is really narrow, the rendered markdown is wider than the window width and introduces a line break. This means I have to go into the hover window to see what it wants to show me.
Here is a screenshot of the issue:

Here is a screenshot of the hover buffer contents:

(The cursor is on the first line in the first column. The closing backticks for the code block are off-screen.)
The issue seems to be only the first line. When I put my cursor there or scroll it off-screen, everything works as expected.
Expected behavior
The first line should be narrow enough, that it does not break across lines.
Healthcheck output
Plugin configuration
Plugin error log
Confirmations
Additional information
No response
The text was updated successfully, but these errors were encountered: