English 中文(简体)
标注“”
原标题:highlight "" in strings for emacs
最佳回答

您可使用<条码>全天候附加关键词,通过做以下一些事情来强调座标:

(font-lock-add-keywords  foo-mode  (("\s"\|\s|" 0  my-string-delimiter-face t)))

The regexp /s/>/code/ <代码>s对不同特性的辛瓦特类进行对比,可在Eelisp手册中读到:(elisp)Syntax表s(elisp)Regexp Backslash

如果你看不到<条码>>,那么读书的难度很小:>

<>0 系指将面面孔应用于整个配对体,t<>t <>t最终使座标上已经出现的任何表面都处于压倒之上(因为许多模式将强调包括有<条码>的限定词/条码>或类似)的整个座标。

<代码> foo-mode可以是任何方式(例如 emacs-lisp-mode,php-mode)或nil,使这一变化的缓冲区仅能进入目前的缓冲地带。 (在这种情况下,你可能应当把这一点放在你希望适用的模式的模棱两可之中)

www.un.org/Depts/DGACM/index_spanish.htm 可能是任何现存的面孔,或者你可以通过做如下事情来界定:

(defface my-string-delimiter-face
   ((t (:foreground "red" :weight bold)))
   "My custom face for string delimiters")
问题回答

暂无回答




相关问题
suppress additional braces in emacs electric mode

I started using ruby-electric-mode. I like it except that I am used to closing open brackets myself (the other pairing are still useful to me). How can I make emacs suppress additional brackets when ...

Setting up an emacs environment in windows?

I am currently constrained to a windows dev box and I want to migrate my projects from eclipse to emacs. What are some good references on setting up an emacs dev environment for windows? Anything ...

Emacs Setting which-function-mode

I would like to have which-function-mode on by default when I open up Emacs. I ve added the following lines to my .emacs file. (setq which-func-mode t) (setq which-function-mode t) When I open ...

Enabling go mode for emacs

I don t seem to be able to enable a go mode for emacs. C mode doesn t work without semicolons. The best I have found is the JavaScript mode by Karl Landstrom, since JavaScript also doesn t require ...

Custom Emacs key bindings are not working

The key bindings I ve defined in my .emacs file aren t working. Here s the file: ;init modes (menu-bar-mode 0) (tool-bar-mode 0) (cua-mode) (column-number-mode) (fset perl-mode cperl-mode) (cperl-...

eval during emacs lisp macro expansion

How can I fix the simple macro foo in (elisp)Eval During Expansion? None of the followings work: (defmacro foo1 (a) `(setq (eval ,a) t)) (defmacro foo2 (a) `(setq ,(eval a) t)) (defmacro foo3 (...

Get local cvs comment history when committing file/s in emacs

I often commit files with similar cvs comment but not in a single operation. I would like to able to bring up previous comments I ve used in a previous commit when I am in the process of writing a ...

热门标签