开发者

hl-line-mode emacs color change

Emacs' hl-line-mode is just what i need but i would like to change it's horrible yellow color, anyone know how can i do that开发者_开发问答?


I use (set-face-background hl-line-face "gray13").

here's what it looks like with a black background.

hl-line-mode emacs color change

Very subtle. Mostly I notice it when moving the cursor, which is what I wanted.

If you want to see a display of all the various colors, try (list-colors-display). It will show a list of colors in a new buffer.

EDIT: heh heh, since I am getting upvoted for pretty pictures, here it is "live":

hl-line-mode emacs color change

(ps: that animated gif was produced with the Cropper tool and the AnimatedGif plugin.)


M-x customize-group RET hl-line RET

and modify "Hl Line face".

Alternatively, you could use (for example):

(set-face-background 'hl-line "#333333")

edit: cheeso's answer would be the more robust approach for that second version.


On top of all the nice answers, you can also do it with use-package as follows:

(use-package hl-line                                                                                                                                                                                                                                                                                                  
  :custom-face                                                                                                                                                   
  (hl-line ((t (:background "#aaaaaa")))))

hl-line is the customizible face added in Emacs 22 according to the author of hl-line+.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜