-
Notifications
You must be signed in to change notification settings - Fork 1.7k
VS Code wrap viewport width broken with type inlays #3333
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
Comments
I wonder if we had a really long (or multiple on one line?) code lense if they would wrap. |
Inlay type hints do not contribute to the number of characters in a line which, I think, is used to compute word wrapping. I guess we should file an issue to vscode regarding CSS pseudo-elements width not being considered for word wrapping. |
See also microsoft/vscode#16221. |
I think this is the underlying vscode issue, I added a comment about the rust-analyzer use case: microsoft/vscode#32856 (Also, they use thumbs-up count on the issue to prioritize, so you know what to do.) |
What's the status on this now that VS Code supports native inlay hints (that respect wrapping widths)? |
No news yet: microsoft/language-server-protocol#956 (comment). |
We switched to the native inlay hints which to my knowledge support this. |
Probably low-pri, but I noticed that in VS Code the "wrap to viewport width" setting doesn't work when rust-analyzer provides inline typehints.
Wrap to viewport width setting:

No typehints, wrapping to viewport works correctly:

With typehints, wrapping is incorrect:

Potentially related to #3138
The text was updated successfully, but these errors were encountered: