-
Notifications
You must be signed in to change notification settings - Fork 796
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
Add optional width parameter to GetToolTip #14891
Conversation
if provided, use the given width to call Display.squashTo on the layout
It doesn't change the default current behaviour, right? |
No, if no width is provided, the layout isn't modified in any way. |
Will it squash doc comments, too? |
No, but you might see them rendered in a window with a smaller width. But that depends on the caller of the API. Here with a width given: You can get the same change in the rendering of the doc comment if you drag the tooltip window with your mouse to a smaller width. But this PR dosn't add newlines to doc comments. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job, thanks, @dawedawe!
BTW what happens in case of some horribly long word or type? Like
type Donaudampfschiffahrtselektrizitätenhauptbetriebswerkbauunterbeamtengesellschaft = int
It's a corner case anyway, I'm just curious, would be grateful for a screenshot :)
@dawedawe alright, now I can sleep peacefully :D thanks for checking that! |
fixes #13772
with help of @nojaf
If provided, use the given width to call Display.squashTo on the layout of the ToolTip.
We were able to demonstrate the effects this would have in Rider:
Default behaviour with no width provided:
With width 20 for demo purposes: