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

Brightness #4

Closed
ptoche opened this issue Apr 23, 2021 · 6 comments
Closed

Brightness #4

ptoche opened this issue Apr 23, 2021 · 6 comments

Comments

@ptoche
Copy link

ptoche commented Apr 23, 2021

First, thanks for this awesome project!

My feedback: I'm finding the color contrast a little too high in places, making it harder to read certain parts, e.g. comments. Obviously it's a matter of taste, but I thought you might find the feedback useful.

Julia - Monokai Vibrant:

a

Julia - Monokai Classic:

c

Solarized Dark (much less contrast):

b

Your themes are prettier, no doubt, but the contrast feels a bit strong for a dark theme imho.

Of the two I like the Monokai Vibrant best, but with a little less contrast.

@ptoche
Copy link
Author

ptoche commented Apr 23, 2021

I've just noticed one can select a preferred "high contrast theme" in visual studio code. Your Monokai Vibrant theme is definitely my first choice in that context!

Unfortunately there is no way to reduce the brightness/contrast for an entire theme. That would have been an easy fix.

@CameronBieganek
Copy link
Owner

Hi, @ptoche, thanks for using Julia Color Themes and thanks for the feedback!

My color themes are actually just modifications of existing color themes. I think I kept the color palette the same as the original themes (although I added magenta to Monokai Classic). The part that I changed is that I modified and added Julia specific scope selectors which determine which scopes/tokens within the source code get colored the various colors. For example, I colored brackets, parentheses, commas, and semicolons as orange. According to the Julia TextMate grammar, brackets, parentheses, commas, and semicolons are all categorized as the meta.bracket scope.

The theme that Julia Monokai Classic is based on is the Monokai theme that ships with VS Code, and the theme that Julia Monokai Vibrant is based on is this one.

I'm certainly willing to accept pull requests if you'd like to add your own custom themes. :)

Also, @neoabs made a couple of themes that I will probably add one of these days, see #3.

@ptoche
Copy link
Author

ptoche commented Apr 25, 2021

Thanks for getting back to me Cameron. I understand! Actually it makes sense to be using existing themes, that have been tried and tested. VS's default dark theme works well enough for a "light" theme. What would it take to add Julia-specific scope selectors? Which part of the code does that? :-)

@ptoche ptoche closed this as completed Apr 25, 2021
@ptoche
Copy link
Author

ptoche commented Apr 25, 2021

This is VS code's default Dark theme. Not as sprightly, but the eye doesn't get tired and comments are easy to read.

a

@CameronBieganek
Copy link
Owner

CameronBieganek commented Apr 26, 2021

What would it take to add Julia-specific scope selectors? Which part of the code does that?

@ptoche In the Julia Monokai Classic theme, the Julia-specific scope selectors are here, and there are some Python-specific scope selectors that I added further down in the file.

The background reading needed to understand TextMate grammars is here and here.

There's also a handy tool in VS Code for when you're experimenting with syntax highlighting. If you open up the command window (Cmd + Shift + P on mac), and run the Developer: Inspect Editor Tokens and Scopes command, it will show you to which scope each section of the source code is assigned by the Julia TextMate Grammar.

Also note that you can directly override all color choices using scope selectors in your JSON settings file:
https://code.visualstudio.com/docs/getstarted/themes#_editor-syntax-highlighting

@ptoche
Copy link
Author

ptoche commented Apr 26, 2021

Wow. Thanks for a very thorough answer. I've tried the Developer: Inspect Editor Tokens and Scopes tool: Very convenient! 👍

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