emacsclient 无法加载颜色“unspecified-bg”
使用 emacsclient -c
时,我收到错误无法加载颜色“unspecified-bg”[16 次]
。我已经使用 emacs --daemon
启动了 emacs。这似乎意味着我的自定义面孔将无法加载。
当像平常一样启动emacs,然后使用Mx server-start
时,则根本不会发生这个问题。如何让 emacsclient -c
正确加载面孔?
这是相关代码:
(custom-set-faces '(default ((t (:inherit nil :stipple nil :background "black" :foreground "white" :inverse-video nil :box nil :strike-through nil :overline nil :下划线无:倾斜正常:重量正常:高度120:宽度正常:铸造厂“未知”:家庭“Inconsolata”)))))
I'm getting the error Unable to load color "unspecified-bg" [16 times]
when using emacsclient -c
. I've started up emacs using emacs --daemon
. This seems to mean that my custom faces won't load.
When starting emacs as usual, and then using M-x server-start
, then this problem doesn't happen at all. How can I get emacsclient -c
to load the faces properly?
Here's the relevant code:
(custom-set-faces '(default ((t (:inherit nil :stipple nil :background "black" :foreground "white" :inverse-video nil :box nil :strike-through nil :overline nil :underline nil :slant normal :weight normal :height 120 :width normal :foundry "unknown" :family "Inconsolata")))))
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
我不是 100% 确定这会解决您的问题,但您确实应该使用 color-theme 用于语法突出显示。 Custom 适用于 emacs 新手,因此我建议您尝试 color-theme 并看看它是否有效。以下是我在计算机上的设置方法:
~/.emacs.d/color-theme/
的位置。在您的 .emacs 中:
然后定义您的颜色主题:
当您启动 emacs 时,这将加载
color-them-mine
。您可以通过输入Mx color-theme
查看所有可用的颜色主题。要查看可用面孔的完整列表,请使用命令Mx list-faces-display
。I'm not 100% sure this would fix your problem, but you really should be using color-theme for syntax highlighting. Custom is meant for beginning emacs users, so I'd suggest you try out color-theme and see if it works. Here's how I have it set up on my machine:
~/.emacs.d/color-theme/
.In your .emacs:
Then you define your color theme:
This will load
color-them-mine
when you start emacs. You can see all available color themes by typingM-x color-theme <TAB>
. To see the full list of faces available, use the commandM-x list-faces-display
.听起来这可能是 bug #4776:http://debbugs.gnu。 org/cgi/bugreport.cgi?bug=4776#5。如果没有,请考虑使用
Mx report-emacs-bug
提交一份错误报告。Sounds like this might be bug #4776: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=4776#5. If not, consider filing a bug report for this one, using
M-x report-emacs-bug
.