8000 rrt style: Missing syntax highlighting for `.diff` files · Issue #603 · alecthomas/chroma · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

rrt style: Missing syntax highlighting for .diff files #603

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

Closed
Nuc1eoN opened this issue Feb 7, 2022 · 2 comments · Fixed by #1064
Closed

rrt style: Missing syntax highlighting for .diff files #603

Nuc1eoN opened this issue Feb 7, 2022 · 2 comments · Fixed by #1064

Comments

@Nuc1eoN
Copy link
Contributor
Nuc1eoN commented Feb 7, 2022

Greetings,

I am using the theme rrt and I love it! But I've noticed that it does not syntax highlight .diff files at all.

Take this sample:

- foo
+ bar

And try it on https://swapoff.org/chroma/playground/.

It works perfectly with the monokai style, while rrt does not provide any highlighting. However other styles seem to be affected, too.

Thanks in advance, I hope it can be resolved. I did not seem to have any issues with rrt with other file formats and I do love the theme! :)

@Nuc1eoN Nuc1eoN changed the title rrt style: No syntax highlighting in .diff files rrt style: Missing syntax highlighting for .diff files Feb 7, 2022
@serhack
Copy link
Contributor
serhack commented Nov 10, 2022

Is there any color in particular you want? Otherwise I'll commit this:

<entry type="GenericDeleted" style="#f92672"/>
<entry type="GenericInserted" style="#a6e22e"/>

image

@Nuc1eoN
Copy link
Contributor Author
Nuc1eoN commented Dec 11, 2022

Hi @serhack,
Thank you for asking my opinion :) What do you think about:

<entry type="GenericDeleted" style="#f00"/>
<entry type="GenericInserted" style="#0f0"/>

and #87ceeb for the @@
and #ff0 for index and diff lines, like so:

rrt

I think it would suit the theme well.
I reused other rrt colors, but they hopefully shouldn't collide here..

Nuc1eoN added a commit to Nuc1eoN/chroma that referenced this issue Mar 26, 2025
This will *at the very least* enable proper styling of diff files. Also added GenericStrong and GenericEmph tokens.
Nuc1eoN added a commit to Nuc1eoN/chroma that referenced this issue Mar 26, 2025
This will *at the very least* enable proper styling of diff files. Also added the universal GenericStrong and GenericEmph tokens.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants
0