启用高对比度模式时的语法着色. [英] Syntax colouring when High Contrast Mode is enabled.

查看:94
本文介绍了启用高对比度模式时的语法着色.的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在黑暗环境中工作时,Windows的明亮背景(例如File Explorer的白色背景)会伤害我的眼睛. Linux正式支持深色主题,但在Windows上,您将需要某种黑客手段(修改系统dll文件).它 似乎,在没有黑客手段的情况下获得深色主题(某种形式)的唯一方法是使用高对比度黑色"效果.主题.

When working in a dark environment, the bright backgrounds of Windows, such as the white background of File Explorer, hurt my eyes. Linux officially supports dark themes, but on Windows, you would need some kind of hacking (modifying system dll files). It seemed that the only way to get the dark theme (of some sort) without the hack is to use the "High Contrast Black" theme.

选择此主题后,Visual Studio似乎将自己锁定为高对比度".颜色主题,并且不允许我将其更改为其他颜色.问题在于所有文本现在看起来都是白色的.没有语法上色.我可以改变 在字体和颜色"设置中,每个元素都一个接一个地设置,但这既繁琐又费时.有什么简单的方法可以恢复语法颜色?黑暗主题具有良好的语法着色,我不知道为什么不能将该着色应用于此高级". 对比"主题.

When this theme is selected, Visual Studio seems to lock itself to the "High Contrast" colour theme, and does not allow me to change it to something else. The problem is that all texts now look white. There is no syntax colouring. I could change each element one by one in the Fonts and Colours settings, but that is tedious and time-consuming. Is there any easy way to get the syntax colouring back? The Dark theme had good syntax colouring, and I wonder why that colouring cannot be applied to this "High Contrast" theme.

推荐答案

郑贞宪,

将Windows主题更改为高对比度"时,在Visual Studio中得到相同的结果.

I get the same result in Visual Studio when I change the Windows theme to "High Contrast".

我们需要在Visual Studio中通过工具设置代码颜色->选项->环境->字体和颜色手动.由于更改Windows主题之后,将更改当前Windows上的所有程序,并且程序中的原始颜色需要适合 当前主题以确保可以看到内容.

We need to set the code color in Visual Studio through Tools -> Options -> Environment -> Fonts and Colors manually. Since after change Windows theme, all programs on current Windows will be changed and the original color in programs need to suit current theme to make sure the content could be seen.

我们可以通过这种手动方式根据Windows主题设置代码颜色,并使它们看起来更清晰.

We could through this manual way to set the code color based on the Windows theme and let them looks more clearly.

 

最好的问候,
Weiwei

Best Regards,
Weiwei


这篇关于启用高对比度模式时的语法着色.的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆