我想设置org-mode标题的字体大小。
它们默认情况下太大了(是的,大小确实很重要)。
我一直在尝试查找参考资料,但非常恼人的是,我没有找到。
如何通过我的配置文件自定义所有标题的比例值?
通过emacs中的组设置--> org-faces,我发现它被设置为高度和比例。
我想将所有比例设置为1。
找到了答案。虽然太明显了,但仍然很烦人。
(custom-set-faces
'(org-level-1 ((t (:inherit outline-1 :height 1.0))))
'(org-level-2 ((t (:inherit outline-2 :height 1.0))))
'(org-level-3 ((t (:inherit outline-3 :height 1.0))))
'(org-level-4 ((t (:inherit outline-4 :height 1.0))))
'(org-level-5 ((t (:inherit outline-5 :height 1.0))))
)
(custom-theme-set-faces!
'doom-city-lights
'(org-level-4 :inherit outline-4 :height 1.1)
'(org-level-3 :inherit outline-3 :height 1.25)
'(org-level-2 :inherit outline-2 :height 1.5)
'(org-level-1 :inherit outline-1 :height 1.75)
'(org-document-title :height 2.0 :underline nil))
或者你可以在 org-mode 之后挂载 doom-docs-mode(它会打开所有的“美化”):
(add-hook! 'org-mode-hook 'doom-docs-mode)
Daniel的解决方案无法改变 #+Title 的字体大小/高度。 我在 spacemacs 的自定义主题上成功实现了这一点。 通过编辑 dotfilespacemacs,即 .spacemacs > (defun dotspacemacs/emacs-custom-settings () 部分或者如果是标准 Emacs,则是你的 regular init.el。
(custom-set-faces
'(org-level-1 ((t (:inherit outline-1 :height 2.0))))
'(org-level-2 ((t (:inherit outline-2 :height 1.8))))
'(org-level-3 ((t (:inherit outline-3 :height 1.6))))
'(org-level-4 ((t (:inherit outline-4 :height 1.4))))
'(org-level-5 ((t (:inherit outline-5 :height 1.0))))
(set-face-attribute 'org-document-title nil :height 2.0)
感谢 Viking667 先生/小姐和 habamax 在 IRC 提供的解决方案。对于他们的帮助,我们表示感谢。
(setq solarized-scale-org-headlines nil)
- Ben Challenor