-
Notifications
You must be signed in to change notification settings - Fork 757
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
[scide] Change default theme #4025
Conversation
The only comment I will make about this is that I would expect "atomic" literals, i.e. numbers, characters, and true/false/nil/inf, to be all the same color. At the very least, numbers and characters because of how often you transform between them. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've been using the new default theme all day so far and I'm really loving it!
addToTheme("evaluatedCode", background, orange); | ||
addToTheme("whitespace", background); | ||
addToTheme("keyword", red); | ||
addToTheme("built-in", yellow); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see @brianlheim's point. "built-in" is the only use of yellow. It might be best to make it purple. "char" could also be purple.
Chars and builtins are now purple along with numeric literals. Yellow is discarded. It was hard to read anyway.
thanks for the feedback. i've decided to discard yellow (which was hard to read anyway). the first post has been updated. in the future, i'd love to expand ScIDE::ScLexer so it can parse a wider variety of SC tokens. i actually have a branch for separate syntax highlighting for binary operators, but it's a "10% more beautiful" thing, and not very critical for these 3.10 makeovers. |
Bright backgrounds are not my cup of tea, but this one is a real improvement! |
This is an internal private method, no user impact.
i set the parentheses to appear bold, but unfortunately not all fonts have bold. i also tried underline (like in sublime text) but the qt underline has some garish-looking results when it intersects with characters or the cursor, so not great either. so, back to a subtle background color. i wouldn't use green here, btw. a light shade of green looks pretty gaudy, a dark shade of green will create confusion for users with red/green colorblindness.
yeah that's a good idea, thanks. i also nudged the string color a little to the purple side so it's more easily distinguishable from classes. |
On 29 Aug 2018, at 05:36, Nathan Ho ***@***.***> wrote:
i set the parentheses to appear bold, but unfortunately not all fonts have bold.
That’s interesting: Monaco (the default font on macOS set in SC) indeed has no bold variant.
But I have set Source Code Pro, which has.
So I checked with Menlo, which also comes w/ macOS, and it has a bold variant.
But alas, the brackets are not emphasised as well. Just plain.
Did I miss something? (yes, 'Highlight Bracket Contents’ is active)
This I just checked with the original patch from your PR.
Just noting in case something else isn’t right.
i wouldn't use green here, btw. a light shade of green looks pretty gaudy, a dark shade of green will create confusion for users with red/green colorblindness.
of course - that’s an important point, I should have thought of that (got a student w/ this condition)
on my screen now it’s very subtle, almost indiscernible.
that’s the reason why I tried to give it a slight hue. but that’s (literally) just from my POV here,
which is of course not the general view. And users are certainly invited to change that.
i also nudged the string color a little to the purple side so it's more easily distinguishable from classes.
looks good now - IMHO the anti-aliasing works a hint better this way.
|
Are we good to go? |
I am satisfied with this! Thanks @snappizz |
i've made the background for currentLine/matching parentheses a little less subtle per @miczac's request. after CI passes, this should be good to go. thanks all for the feedback, there was much less resistance to this than i expected :) |
Purpose and Motivation
the default IDE theme is quite ugly. providing a professional looking default theme improves first impressions of SC. also if SC educators don't have to look at #ffffff white backgrounds when helping students, that's a plus.
this PR supplies a new default theme. here's what it looks like with some SynthDef code:
here is the full gamut of code colors and the syntax elements they correspond to:
i wanted to keep it a light theme to avoid making the change too radical from 3.9. the colors are lifted from Kary Pro Color, but i switched them around considerably to keep an attractive balance of hues in typical SC code.
the background is light gray and not white like the old theme. however, it is still quite high contrast. it looks especially great with a beefy font choice like Source Code Pro Medium (above) or Meslo LG.
i avoided bold text. some themes can pull it off, but i think it looks pretty unprofessional in syntax highlighting. the most popular editor themes use bold very sparingly.
too many inconsistent colors become hard to tweak, and just don't look very good. i reused some colors:
~environmentVars
/_Primitive
(both of which are very unlikely to occur in adjacent code), and numerics/characters/builtins (all of which are "atomic" literals).old theme is renamed to "classic."
Types of changes
cosmetic change
Checklist
Remaining Work
right now the help browser still has #fffff background, so it looks off from the default theme. we should change it, but i will leave that for another PR.