Skip to content

Support Changing Theme of Syntax Highlighting #2523

Closed
@Joe-Zer0

Description

@Joe-Zer0

Is your feature request related to a problem? Please describe.
Please support the ability to change the theme of the syntax highlighting.

Describe the solution you'd like
I believe gitui uses syntect for syntax highlighting. syntect uses tmTheme files to set it's Theme (https://github.com/trishume/syntect/blob/master/src/highlighting/theme.rs). If gitui could accept a tmTheme file, it may be able to be passed to syntect to set the theme.

Describe alternatives you've considered
I've created a theme.ron, and while this is nice, it does not affect the syntax highlighting.

Additional context
bat (https://github.com/sharkdp/bat) uses tmTheme files to set it's theme. It does have a particularly interesting on that reuses your terminal colors for the syntax highlighting (https://github.com/sharkdp/bat/blob/master/assets/themes/ansi.tmTheme). Although I did have to modify it slightly to fit my needs.

Thank you for your consideration!

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions