macos Emacs + Mac OSX 和更改默认字体

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/1257426/
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

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-10-21 06:19:29  来源:igfitidea点击:

Emacs + Mac OSX and changing default font

emacsmacosemacs23

提问by Andrzej ?liwa

how I can change default font to Monaco with antialiasing on Emacs 23. Where I can find dedicated binary for Emacs 23.1 for cocoa with antialised font settings?

如何在 Emacs 23 上使用抗锯齿将默认字体更改为 Monaco。在哪里可以找到具有抗锯齿字体设置的可可的 Emacs 23.1 专用二进制文件?

回答by CubaLibre

There is another question that deals with fonts on Emacs and Mac OS here: How do I set fonts on Emacs for Mac?

这里还有一个关于 Emacs 和 Mac OS 上字体的问题:如何在 Emacs for Mac 上设置字体?

I found it easiest to add something like this to my init.el

我发现将这样的内容添加到我的 init.el 中最容易

 (set-face-attribute 'default nil
                :family "Inconsolata" :height 145 :weight 'normal)

回答by ayman

You can set the font faces via: M-x customize-facesand type defaultwhen prompted Customize face (...):There's an option to Save for Future Sessionswhich will write to your custom.elfile, so the face will be set next time you run Emacs.

您可以通过以下方式设置字体:M-x customize-facesdefault在出现提示时键入Customize face (...):有一个选项Save for Future Sessions将写入您的custom.el文件,因此下次运行 Emacs 时将设置字体。

There are two distributions which are popular

有两种流行的发行版

Both are excellent binary distributions.

两者都是优秀的二进制分布。

回答by Pinochle

I grab my OS X Emacs binaries from http://atomized.org/wp-content/cocoa-emacs-nightly/.

我从http://atomized.org/wp-content/cocoa-emacs-nightly/获取我的 OS X Emacs 二进制文件。

You can find the settings for the default font in M-x customize, then once inside the customize menu, you follow this path: -> Faces -> Basic Faces -> Default.

您可以在 中找到默认字体的设置M-x customize,然后在自定义菜单中,您可以按照以下路径操作:-> Faces -> Basic Faces -> Default

回答by Hamza Yerlikaya

If you have xcode installed you can build emacs your self nothing extra needed, which uses anti aliased monaco as the default font.

如果你安装了 xcode,你可以自己构建 emacs,不需要额外的东西,它使用抗锯齿摩纳哥作为默认字体。