help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: Electric Buffer mode too boring


From: Drew Adams
Subject: RE: Electric Buffer mode too boring
Date: Thu, 24 Apr 2008 15:35:47 -0700

> I've been using this with XEmacs for years:
> 
> (defconst Electric-buffer-menu-mode-font-lock-keywords
>   (purecopy
>    (list
>     '("^ MR Buffer.*"                 . 
> font-lock-preprocessor-face) ;hdr 1
>        '("^ -- ------.*"              . 
> font-lock-preprocessor-face) ;hdr 2
>        '("^\\(....Man: .*\\)" 1 font-lock-variable-name-face 
> t) ;Manpg (new)
>        '("^[. ][*][^%].[^*].*"        . 
> font-lock-comment-face)       ;Mod x temp
>        '("^....[*]Buffer List[*].*"   . 
> font-lock-doc-string-face) ;Buffer list
>        '("^\\(....[*]shell.*\\)"      1 
> font-lock-reference-face t) ;shell buff
>        '("^....[*].*"                 . 
> font-lock-string-face) ;Temp buffer
>        '("^....[+].*"                 . 
> font-lock-keyword-face) ;Mail buffer
>        '("^....[A-Za-z0-9/]*[-][+].*" . 
> font-lock-keyword-face) ;Mail buffer
>        '(".*Dired.*"                  . font-lock-function-name-face)
>        )))
> 
> ; This hook run after buffer formatted, so it is necessary to 
> re-fontify it..;
> (add-hook 'electric-buffer-menu-mode-hook
>         '(lambda ()
>            (font-lock-mode 1)
>            (font-lock-fontify-buffer)))
> 
> I've never been able to figure out why it doesn't work with gnu emacs.
> Help!

You might be interested in buff-menu+.el:
http://www.emacswiki.org/cgi-bin/wiki/BufferMenu#BufferMenuPlus

 





reply via email to

[Prev in Thread] Current Thread [Next in Thread]