如何在 Eclipse 中更改 Python 代码的默认字体?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/9868711/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How do I change the default font for Python code in Eclipse?
提问by bnguyen82
In Eclipse, how can I change default font for Python code in the editor (PyDev plugin)?
在 Eclipse 中,如何在编辑器(PyDev 插件)中更改 Python 代码的默认字体?
I navigate to menu Window→ Preference→ General→ Appearance→ Colors & Fonts, but I don't find which item would affect the Python code font.
我导航到菜单Window→ Preference→ General→ Appearance→ Colors & Fonts,但我没有找到哪个项目会影响 Python 代码字体。
回答by gecco
As you are using PyDev, you should have a look at menu Window→ Preferences→ PyDev→ Editor(PyDev Editor Preferences).
当您使用PyDev 时,您应该查看菜单Window→ Preferences→ PyDev→ Editor( PyDev Editor Preferences)。
回答by Abhishek Upadhyaya
This is for Mac:
这适用于 Mac:
Go to Eclipse → Preferences→ General→ Appearance→ Colors and Fonts→ Basic→ Text Font.
转到 Eclipse → Preferences→ General→ Appearance→ Colors and Fonts→ Basic→ Text Font。
Edit the font structure for the text font.
编辑文本字体的字体结构。
回答by bnguyen82
Following the guidance of gecco, I found out the item in General→ Appearance→ Colors & Fontswhich affects Python code fonts. It's Text Fontin the Basicfolder.
在gecco的指导下,我在General→ Appearance→ Colors & Fonts中找到了影响 Python 代码字体的项目。它的文本字体的基本文件夹。
回答by Robert Casey
On a Mac, I can get to the PyDev settings via:
在 Mac 上,我可以通过以下方式进入 PyDev 设置:
Eclipse → Preferences→ PyDev(in tree) → Editor(subtree)
Eclipse →首选项→ PyDev(在树中)→编辑器(子树)
In my case, I wanted to change hash tag comments from nearly invisible grey to a better color. It worked like a charm.
就我而言,我想将哈希标签注释从几乎不可见的灰色更改为更好的颜色。它就像一个魅力。

