[英]How do I change the editor's default font to a font that's installed on the system?
The editor defaults to a monospaced font, which looks like Courier New. 编辑器默认为等宽字体,类似于Courier New。 I want to use something like Consolas instead, but I only see a few fixed options that look like they map to system fonts.
我想改用Consolas之类的东西,但是我只看到一些固定的选项,它们看起来像它们映射到系统字体。 Is there a way to choose an installed font to use as the editor's default font?
有没有办法选择已安装的字体用作编辑器的默认字体?
I discovered how to choose a font that's not listed in the IDE's font selection menu after messing with configuration files for a while. 在弄乱配置文件一段时间后,我发现了如何选择一种未在IDE的字体选择菜单中列出的字体。 This was tested on Windows with NetBeans 6.9.1 and MPLAB X 1.95.
这已在Windows上使用NetBeans 6.9.1和MPLAB X 1.95进行了测试。 (Note: NetBeans 7 has a font chooser.)
(注意:NetBeans 7具有字体选择器。)
The configuration file for fonts and colors has been created. 字体和颜色的配置文件已创建。 You can either follow option 1 or 2 to open the configuration file, then see the last section to change the font.
您可以按照选项1或2打开配置文件,然后参阅最后一节以更改字体。 The second option is easier if you don't know where the configuration files are located.
如果您不知道配置文件的位置,则第二个选项会更容易。
MPLAB X
MPLAB X
/Users/ user /AppData/Roaming/.mplab_ide/dev/v1.95/config/Editors/FontsAndColors/NetBeans/org-netbeans-modules-editor-settings-CustomFontsColors-tokenColorings.xml
/ Users / 用户 /AppData/Roaming/.mplab_ide/dev/v1.95/config/Editors/FontsAndColors/NetBeans/org-netbeans-modules-editor-settings-CustomFontsColors-tokenColorings.xml
NetBeans
NetBeans的
/Users/ user /.netbeans/6.9/config/Editors/FontsAndColors/NetBeans/org-netbeans-modules-editor-settings-CustomFontsColors-tokenColorings.xml
/ Users / 用户 /.netbeans/6.9/config/Editors/FontsAndColors/NetBeans/org-netbeans-modules-editor-settings-CustomFontsColors-tokenColorings.xml
Either search for "Dialog" (or the font that was selected earlier) or "name="default"", which is an attribute of the fontcolor element. 搜索“对话框”(或之前选择的字体)或“名称=“默认”“,这是fontcolor元素的属性。 There should be a nested element that looks like:
应该有一个看起来像这样的嵌套元素:
<font name="Dialog" size="12"/>
<font name =“ Dialog” size =“ 12” />
Change "name" to the font that you want to use. 将“名称”更改为要使用的字体。 The selected font should be set after the IDE restarts.
IDE重新启动后,应设置所选字体。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.