-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Adjust the rustdoc highlighting colour scheme #12648
Comments
I think I should reconsider my career in graphic design. |
I'm looking at this. |
(The relevant file is |
BTW I was wondering, why not just use |
Also, it's pretty much impossible to have consistency between rustdoc and the old codemirror (tutorial) since both parsers behave very differently. |
Doesn't this mean every line is a new This bug is specifically about the colour scheme of rustdoc since it's so wild. Also, #11392 about using rustdoc for everything. |
My preference for the highlighting scheme is bold for keywords, green for macros, red for strings (the current color is fine), gray for comments (would be nice if code within comments were highlighted). |
No, it would look like this: <pre class="code">
<ol>
<li class="L1"></li>
<li class="L2"></li>
<li class="L3"></li>
...
</ol>
</pre> I think it would be better to use that since that's the browser native numberings.
No it doesn't. The identifier of a list aren't inlined with the content. Here is an example. |
Oh, awesome. It does seem like a good idea, if you can get that to work. |
Another note: current rustdoc parsing could be improved, i.e. the "ident" class corresponds to variable names, function names, paths, parameters... could be more split if you ask me. |
The highlighting is performed by just by the token types the lexer (with a little bit of extra logic for attributes, macros and $ non-terminals in macros) and so does not have that information. |
…=flodiebold fix: Report proc macro errors in expressions correctly as well They didn't have a krate before, resulting in the generic "proc macro not found" error. Also improve error messages a bit more.
It's currently very bright and distracting (IMO).
(Sorry @alexcrichton :( )
Current scheme, for future triage/comparison purposes:
The text was updated successfully, but these errors were encountered: