JetBrains PyCharm 2017.3.5社区版配色配置文件格式咨询及报错排查
Fixing Your PyCharm 2017.3.5 Color Scheme File
Hey there! The issue you're hitting is that PyCharm's .icls color scheme files aren't plain key-value text files—they rely on a specific XML structure the IDE needs to parse correctly. Your current file is just a flat list of assignments, which PyCharm can't interpret at all.
Let's convert your color values into the proper XML format. Here's what your hot_fudge_sunday_color_scheme.icls should look like:
<scheme name="Hot Fudge Sunday" version="142" parent="Darcula"> <colors> <color name="DEFINITION_FOREGROUND" value="#D92B10"/> <color name="ERROR_FOREGROUND" value="#FF0000"/> <color name="STRING_BACKGROUND" value="#2B0F01"/> <color name="KEYWORD_FOREGROUND" value="#4AD231"/> <color name="NORMAL_FOREGROUND" value="#208008"/> <color name="COMMENT_BACKGROUND" value="#2B0F01"/> <color name="HIT_FOREGROUND" value="#208008"/> <color name="BUILTIN_BACKGROUND" value="#2B0F01"/> <color name="STDOUT_FOREGROUND" value="#D92B10"/> <color name="CURSOR_FOREGROUND" value="#208008"/> <color name="BREAK_BACKGROUND" value="#2B0F01"/> </colors> <!-- Uncomment below if you want to add font styles like bold/italic for specific elements --> <!-- <attributes> <attribute name="KEYWORD" bold="true"/> </attributes> --> </scheme>
Critical Details to Keep in Mind:
- The root
<scheme>tag is mandatory: include aname(the display name for your scheme),version(142 is compatible with 2017.3.5), andparent(pick a base scheme likeDarculaorDefaultto inherit styles you don't explicitly set). - Color names must be uppercase with underscores: your original
definition-foregroundbecomesDEFINITION_FOREGROUND, which matches PyCharm's internal naming rules. - Every color lives inside the
<colors>block, defined as a<color>element withname(the internal identifier) andvalue(your hex color code) attributes.
How to Install This Scheme:
- Save the XML above as
hot_fudge_sunday_color_scheme.icls. - Drop it into PyCharm's color scheme directory:
- Windows:
C:\Users\<YourUsername>\.PyCharmCE2017.3\config\colors - Mac:
~/Library/Preferences/PyCharmCE2017.3/colors - Linux:
~/.PyCharmCE2017.3/config/colors
- Windows:
- Restart PyCharm, then head to
Settings > Editor > Color Scheme—you'll see "Hot Fudge Sunday" in the list of available schemes.
If some elements don't pick up your colors, double-check the name attributes match PyCharm's exact identifiers. You can export an existing default scheme to see the full list of valid color names if needed.
内容的提问来源于stack exchange,提问作者Toothpick Anemone
相关产品推荐
相关产品推荐

