emacs - emacs 如何选择使用哪个脚本进行初始化?
问题描述
在 Ubuntu 18.10 上的 emacs 25.2.2 和 arch 上的 26.2 中,我们都遇到了以下奇怪的行为:
Ubuntu 18:我的主目录中有一个 .emacs 文件。如果我运行 emacs,它可以工作
.emacs 设置缩进样式、字体和颜色
(custom-set-faces
;; custom-set-faces was added by Custom.
;; If you edit it by hand, you could mess it up, so be careful.
;; Your init file should contain only one such instance.
;; If there is more than one, they won't work right.
'(default ((t (:inherit nil :stipple nil :background "white" :foreground "black" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight bold :height 180 :width normal :foundry "urw" :family "Nimbus Mono L")))))
(set-background-color "black")
(set-foreground-color "green")
当 gnome-settings 运行 emacs 时,它不会正确设置字体,但会设置缩进和颜色。因此,我得出结论,首次设置 gnome 时字体设置不起作用。
在 arch 上,运行 emacs 看起来不错。但是,如果我们加载文件并 Mx eval-buffer 字体会发生变化。评估两次会再次更改字体。eval 第三次什么也没做。
谁能解释发生了什么,以及无论何时运行命令,我们如何可靠地选择字体?
解决方案
推荐阅读
- select - 编译简单解码器时类型错误解析中缀表达式
- filter - Lucene 标记化/过滤器未按预期工作 | Solr分析混乱
- javascript - select2 在 webpack encore symfony 中不起作用
- spring-boot - Spring Boot Test 无法使用 JUnit 5 为自定义集成测试源集加载应用程序上下文
- reactjs - 发生错误验证后反应钩子形成 onChange 行为不端
- python - 如何使字典中的键成为字典的键
- mysql - Mysql Table - CREATE COLUMN 比较其他列的值?
- list - 如何遍历单个
飞镖中的列表对 - excel - VBA 从监视窗口打开 Outlook
- html - 调整从中心 CSS 扩展的图像大小