本文介绍了emacs有80多个突出字符吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在这里看到一些解决方案,如果超过80个字符,它将突出显示整行,并且一旦线变得大于,就执行线包裹
80.我想做的是编辑我的 .emacs
文件,使80以外的任何角色都有不同的背景。所以前80个字符将具有我当前的emacs背景,然后字符> 80将有一个黑色背景说。有人可以指向正确的方向吗?谢谢!解决方案
我最近写了一个。这是它的要点:
(require'whitespace)
(setq whitespace-line-column 80);;限制线长度
(setq whitespace-style'(face lines-tail))
(add-hook'prog-mode-hook'空格模式)
I have seen some solutions on here which will highlight an entire line if it goes beyond 80 characters, and also to do a line-wrap
once the line becomes greater than 80. What I would like to do is to edit my .emacs
file so that any character beyond 80 takes on a different background. So the first 80 characters will have my current emacs background, then characters > 80 would have a black background say. Can someone point me in the right directions? Thanks!
解决方案
I recently wrote an extensive article on the subject. Here's the gist of it:
(require 'whitespace)
(setq whitespace-line-column 80) ;; limit line length
(setq whitespace-style '(face lines-tail))
(add-hook 'prog-mode-hook 'whitespace-mode)
这篇关于emacs有80多个突出字符吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!