Skip to content
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

How can I change the pygments 'style' in decompilation/diff view? #312

Open
agnosticlines opened this issue Aug 14, 2024 · 6 comments
Open

Comments

@agnosticlines
Copy link

agnosticlines commented Aug 14, 2024

Hi Joxean, I've written a pygments style file for my theme of choice and I'd like to hook it up to diaphora, how can I go about doing this? There doesn't seem to be a way to modify it for example in the cfg file, diaphora is a fantastic tool but I always have to change my IDA theme back to the default one to get the diff/patch view working properly :-(

Been grepping around trying to find it, seems to be used in CHtmlViewer and HtmlViewer, would be really nice if there was a centralised place to swap the theme

@joxeankoret
Copy link
Owner

I don't really know, to be honest. Let me take a look to it tonight...

@agnosticlines
Copy link
Author

Fair enough! I think I've offered to sponsor full theme support for diaphora before, it's the one obstacle I have to using it, I really really love my custom theme, I'd love it if it just took IDA theme support, but not sure if there's a 1->1 mapping for those and diaphora's UI elements, like the diff colours etc

@joxeankoret
Copy link
Owner

Uhm... are you using the official IDA themes support or a plugin? If it's the official method, I believe I could somehow easily support it.

@agnosticlines
Copy link
Author

Yeah official ida themes with CSS https://github.com/catppuccin/ida-debugger etc

@joxeankoret
Copy link
Owner

Note to myself: it can be implemented following the recommendation of Igor to read from the registry the current theme, and then parsing the CSS of the theme to get the colours. Not terribly trivial, but can be implemented.

@agnosticlines
Copy link
Author

Note to myself: it can be implemented following the recommendation of Igor to read from the registry the current theme, and then parsing the CSS of the theme to get the colours. Not terribly trivial, but can be implemented.

Happy to donate to some goal of getting it landed if that'd help

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

No branches or pull requests

2 participants