-
Notifications
You must be signed in to change notification settings - Fork 8.5k
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
Add cursorColor to color scheme #4651
Add cursorColor to color scheme #4651
Conversation
Add the option to set the cursor color as part of the color scheme. This is very useful for light themes, where the cursor disappears unless its color is set in the profile.
While locally validating, I didn't see my changes to the built-in color schemes reflected. Is this expected? |
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.
oof fat-fingered ctrl+enter
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.
This looks good to me. I'd love some extra tests to check scenarios like:
- a scheme doesn't have a
cursorColor
set - A profile doesn't have a
cursorColor
but it's scheme does - A profile doesn't have a
cursorColor
and neither does it's scheme - A profile does have a
cursorColor
but it's scheme doesn't
But I'm still happy with this without those extra tests 😄
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.
- Yeah, I wanna see the tests above too please.
- I want to double check something. This doesn't make
cursorColor
required for acolorScheme
right? Like, when this goes in, existing users that have customcolorScheme
s withoutcursorColor
will be unaffected by this change? - Could you please update doc/cascadia/SettingsSchema.md too?
@DHowett-MSFT Also, the discussion on #764 sounds like |
Add a test that checks the resulting cursor color for all combinations of setting cursor color or not setting it in profile and color scheme, and for not setting a color scheme at all.
I added the tests @zadjii-msft suggested (and a tiny bit more).
If they set a |
There is no default cursor color for profile, and the documentation shouldn't say there is. The default cursor color is only relevant for color schemes (where it's correctly documented).
Align json and md on "of the" (instead of "for the").
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 love this. Really sorry we took so long to review it. Thanks for the work!
Happy to merge after conflict resolution.
And yes, this should just close the referenced issue. Cursor shape shouldn’t be part of a color palette. :) |
@carlos-zamora You should make another pass on this one, so we can get it merged |
@DHowett-MSFT, whenever you're ready :) |
Hello @DHowett-MSFT! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
Thanks for the contribution! |
🎉 Handy links: |
Add the option to set the cursor color as part of the color scheme.
This is very useful for light themes, where the cursor disappears unless its color
is set in the profile.
Related to issue #764, but doesn't fully resolve it.
Validation
I tested this manually by creating a light color scheme, setting the cursor color
to black and setting the profile color scheme to the newly created color scheme.
I validated the cursor is black, then set the cursor color in the profile (to red)
and saw it trumps the cursor color from the color scheme.