-
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
Make Terminal look great in High Contrast #6833
Make Terminal look great in High Contrast #6833
Conversation
Thanks a lot for your work on this. I'm waiting for this to land in master for the pipeline not being a PR one to test the artifacts 😄 |
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.
Thanks for doing this!
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.
In general, I am neither surprised nor horrified to learn that there is a global magic flag that is set to "do weird stuff to my application" mode by default.
Thank you for doing this. We really needed it.
Console defaults to CP_OEM streams or something equally vile �� |
I feel very seen right now |
@msftbot merge this in 5 minutes |
Hello @DHowett! Because you've given me some instructions on how to help merge this pull request, I'll be modifying my merge approach. Here's how I understand your requirements for merging this pull request:
If this doesn't seem right to you, you can tell me to cancel these instructions and use the auto-merge policy that has been configured for this repository. Try telling me "forget everything I just told you". |
Hello @DHowett! Because this pull request has the Do note that I've been instructed to only help merge pull requests of this repository that have been opened for at least 8 hours, a condition that will be fulfilled in about 4 minutes. No worries though, I will be back when the time is right! 😉 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 (
|
<!-- Enter a brief description/summary of your PR here. What does it fix/what does it change/how was it tested (even manually, if necessary)? --> ## Summary of the Pull Request Update the Palette to be readable under High Contrast mode <!-- Other than the issue solved, is this relevant to any other issues/existing PRs? --> ## References Regressed in #6833 <!-- Please review the items on the PR checklist before submitting--> ## PR Checklist * [X] Closes #6892 * [X] CLA signed. If not, go over [here](https://cla.opensource.microsoft.com/microsoft/Terminal) and sign the CLA * [ ] Tests added/passed * [ ] Documentation updated. If checked, please file a pull request on [our docs repo](https://github.com/MicrosoftDocs/terminal) and link it here: #xxx * [ ] Schema updated. * [X] I've discussed this with core contributors already. If not checked, I'm ready to accept this work might be rejected in favor of a different grand plan. Issue number where discussion took place: #6892 <!-- Provide a more detailed description of the PR, other things fixed or any additional comments/features here --> ## Detailed Description of the Pull Request / Additional comments I pulled the styling of the KeyChord text into a Style, so we can give it a different style under High Contrast. Under HC, I just left all the colors at their default, so ListView can do its thing. (IMHO, the HC style now looks better than the non-HC mode, but maybe I'm biased ;) ) <!-- Describe how you validated the behavior. Add automated tests wherever possible, but list manual validation steps taken as well --> ## Validation Steps Performed | | Old | New | |---|:---:|:---:| | Light |  |  | | Dark |  |  | | HC White |  |  | | HC Black |  |  |
🎉 Handy links: |
Summary of the Pull Request
This PR enables
ApplicationHighContrastAdjustment::None
. Doing this disables a set of mitigations in XAML designed to band-aid apps that were never explicitly designed for High Contrast (HC) modes. Terminal now has full control of and responsibility for its appearance in HC mode. This allows Terminal to look a lot better.PR Checklist
Detailed Description of the Pull Request / Additional comments
On paper, we should be able to set
HighContrastAdjustment="None"
on the<Application>
element. But that doesn't have any effect. I don't know if this is a bug in<Toolkit:XamlApplication>
or somewhere else. So instead I set the property in codebehind, which is not as ideal, but does at least work. I'd love to a way to move this into App.xaml.The Find box had a couple stray styles to override the ToggleButton's foreground color. With backplating removed, these styles became actively harmful (white foreground on highlight color background), so I just removed them. The built-in style for ToggleButton is perfect as-is.
Validation Steps Performed
Vicariously validate via viewing various vivid videos.
High Contrast White:

High Contrast Dark:

The previous appearance, prior to this PR, for comparison purposes:

@mimi89999 this is the PR you've been waiting for ;) Thanks for reporting the HC bugs, and please do keep leaning on apps to make them look great in HC mode.