我对 Emacs 的颜色做了一些更改,现在唯一的问题是光标在黑色背景上为黑色,我必须更改它。我该怎么办?
如果您运行的是最新版本的 emacs,您可以使用:
; Set cursor color to white
(set-cursor-color "#ffffff")
代替#ffffff
你可以使用任何你喜欢的颜色。对于十六进制代码列表谷歌说:http://www.tayloredmktg.com/rgb/ http://www.tayloredmktg.com/rgb/
也许您喜欢这个...以下代码更改每个上的光标颜色blink。只需评估代码及其运行:
; Using in Emacs 24.0
(defvar blink-cursor-colors (list "#92c48f" "#6785c5" "#be369c" "#d9ca65")
"On each blink the cursor will cycle to the next color in this list.")
(setq blink-cursor-count 0)
(defun blink-cursor-timer-function ()
"Zarza wrote this cyberpunk variant of timer `blink-cursor-timer'.
Warning: overwrites original version in `frame.el'.
This one changes the cursor color on each blink. Define colors in `blink-cursor-colors'."
(when (not (internal-show-cursor-p))
(when (>= blink-cursor-count (length blink-cursor-colors))
(setq blink-cursor-count 0))
(set-cursor-color (nth blink-cursor-count blink-cursor-colors))
(setq blink-cursor-count (+ 1 blink-cursor-count))
)
(internal-show-cursor nil (not (internal-show-cursor-p)))
)
请注意,此代码替换了“frame.el”中的 emacs 函数“blink-cursor-timer-function”。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)