Skip to content
This repository was archived by the owner on Apr 14, 2022. It is now read-only.

Some hover tooltips have a trailing two spaces #444

Closed
jakebailey opened this issue Dec 3, 2018 · 4 comments
Closed

Some hover tooltips have a trailing two spaces #444

jakebailey opened this issue Dec 3, 2018 · 4 comments

Comments

@jakebailey
Copy link
Member

image

image

Which aren't visual glitches, as I can highlight the text with my mouse (as above). It only happens for these simple one-liners. More complicated tooltips from docstrings don't seem to have this issue, likely because the text in these two examples is triple-quoted for syntax highlighting, while docstrings are not.

@jakebailey jakebailey added bug Something isn't working feature: tooltips labels Dec 3, 2018
@MikhailArkhipov
Copy link

MikhailArkhipov commented Dec 4, 2018

By design.

            foreach(var s in _md) {
                sb.AppendLine(s + "  "); // Keep hard line breaks
            }

https://meta.stackexchange.com/questions/40976/what-is-the-reason-for-the-top-secret-two-space-newline-markdown-weirdness

@jakebailey
Copy link
Member Author

If we know that the text is a single line, then it might be good to just not add the double space.

Past that, I think it's a little strange that we're controlling the line breaks ourselves rather than letting the renderer do it, but that's a different discussion.

@MikhailArkhipov
Copy link

Because we want text to appear exactly as it is formatted inside the Python file. Many docs include manually formatted tables and code blocks which are getting messed up if line breaks are not preserved.

@MikhailArkhipov
Copy link

MikhailArkhipov commented Dec 19, 2018

Since this is not a bug, closing. #424 is for general improvements.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants