有没有办法让文字模式下的不同面孔渲染一个单词?Emacs文本模式突出显示
1
A
回答
5
查看`highlight-regexp'。只需输入你想改变面部的单词(虽然它可以是任何正则表达式)。
M-X亮点,正则表达式
highlight-regexp is an alias for `hi-lock-face-buffer' in
`hi-lock.el'.
It is bound to M-s h r.
(highlight-regexp regexp &optional face)
Set face of each match of regexp to face.
Interactively, prompt for regexp then face. Buffer-local history
list maintained for regexps, global history maintained for faces.
Use M-p to retrieve previous history items,
and M-n to retrieve default values.
1
是,
你想要的是字体锁定模式。
在这里看到:http://www.gnu.org/software/emacs/manual/html_node/emacs/Font-Lock.html
具体你要打开font-lock-mode
,然后通过font-lock-add-keywords
指定关键字的列表。
相关问题
- 1. emacs magit diff突出显示
- 2. Emacs区域突出显示
- 3. 括号突出显示 - emacs
- 4. 删除Emacs突出显示
- 5. Emacs w3m将突出显示的区域导出为文本
- 6. Algolia - 格式突出显示的文本只显示突出显示的部分
- 7. 评论字符串修复emacs ruby模式突出显示
- 8. 突出显示的标题在Emacs RST-模式
- 9. 突出显示Lisp表单的Emacs模式
- 10. emacs xterm鼠标模式双击以突出显示单词
- 11. 变量只在声明中突出显示? (Emacs的c + +模式)
- 12. Emacs在C++中的不完全突出显示模式
- 13. Emacs lua模式语法突出显示不起作用
- 14. 突出显示文本
- 15. 突出显示文本,住
- 16. 突出显示的文本
- 17. 突出显示文本programmaticly
- 18. 突出显示文本CSS
- 19. EditText突出显示文本
- 20. CSS文本突出显示
- 21. 突出显示文本
- 22. 移动向上箭头不会突出显示文本emacs iterm2
- 23. 将div(模态)显示为接近突出显示的文本
- 24. 在emacs字符串中突出显示“”
- 25. emacs突出显示背景更改
- 26. Emacs:持久突出显示区域
- 27. Emacs上的Scaml语法突出显示
- 28. Emacs匹配标签突出显示
- 29. 在emacs中突出显示julia代码
- 30. 奇怪的Emacs突出显示问题
吧?在文本模式? – Bahbar 2009-11-05 21:25:55
当然,为什么不呢,你只需要为文本模式添加一个钩子。我刚刚在我的本地机器上完成了它。你认为什么不可能? – chollida 2009-11-05 21:32:21