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

Added more syntax languages and themes #2822

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Redhawk18
Copy link
Contributor

This pr uses the two face crate which just bundles syntect and the themes used by bat. All themes were tested using the editor example and the extra languages were testing with .toml and .nix files which are not included by syntect, overall adding support for common use cases.

Let me know what you would suggest about the themes that don't display properly, I left comment notes by them but I can just delete them.

Copy link

@CosmicHorrorDev CosmicHorrorDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few suggestions, but nothing too major

@CosmicHorrorDev
Copy link

Got a couple of commit suggestions that you can cherry-pick if you want

  • CosmicHorrorDev@127bd0a | Bring back base16 highlighter themes
  • CosmicHorrorDev@0045223 | Switch LazyThemeSet to EmbeddedLazyThemeSet
    • This one makes .get()ting a theme infallible and drops the need to have fn key(self) -> &static str by going through EmbeddedThemeName instead

add more syntec themes

update rfd

clippy

clippy 2

suggestions and removed syntect in favor of two-face export of syntect

removed comment

forgot the other cargo.toml :P

Bring back base16 highlighter themes

(cherry picked from commit 127bd0a)

Switch LazyThemeSet to EmbeddedLazyThemeSet

(cherry picked from commit 0045223)
@Redhawk18
Copy link
Contributor Author

Got a couple of commit suggestions that you can cherry-pick if you want

* [CosmicHorrorDev@127bd0a](https://github.com/CosmicHorrorDev/iced/commit/127bd0a7205889ffbdb2b9540b92d42a6d85aeb6) | Bring back base16 highlighter themes

* [CosmicHorrorDev@0045223](https://github.com/CosmicHorrorDev/iced/commit/0045223ca5e337cdfe3a4684816244f996511f41) | Switch LazyThemeSet to EmbeddedLazyThemeSet
  
  * This one makes `.get()`ting  a theme infallible and drops the need to have `fn key(self) -> &static str` by going through `EmbeddedThemeName` instead

genius code, thank you.

Copy link

@CosmicHorrorDev CosmicHorrorDev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Everything's all good now from my side 👍

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 this pull request may close these issues.

2 participants