emacs缩进面在命令行

时间:2015-07-09 09:12:13

标签: shell emacs colors terminal elpy

我正在使用emacs,elpy和magit编辑python代码。使用-nw选项启动emacs时(来自gnome 3中的bash和gnome-terminal)。以这种方式启动时,emacs使用黑色背景单个字符突出显示缩进的代码块;使用图形显示(不带-nw选项)时,相同的字符为浅灰色。请查看附带的两个屏幕截图:

in graphical mode

in terminal

有没有办法修改脸部的黑暗以使其不那么突出?

1 个答案:

答案 0 :(得分:1)

我找到了一个有效的解决方案。我不确定它是否是最好的:如果有人知道更好的方法,请发表评论!

简而言之:

  1. 将光标放在缩进的块上;
  2. M-x customize-face;
  3. 选择默认值(highlight-indentation-face);
  4. 选择Show all(脸部继承自fringes);
  5. 勾选Background(这将覆盖条纹背景颜色);
  6. 选择白色(别名为#e5e5e5)
  7. Apply and Save
  8. 最后一步将几行写入〜/ .emacs文件(在linux上)以保留自定义值。在我的系统中,添加的行是:

    (custom-set-variables)
    (custom-set-faces
      '(highlight-indentation-face ((t (:inherit fringe :background "white")))))
    
相关问题