From: Hans-Peter Binder <hpb@appledomain.de>
Subject: Re: Make Gnus highlighting Lisp snippets ?
Date: Wed, 09 Jun 2004 10:32:20 +0200 [thread overview]
Message-ID: <m28yex9lnv.fsf@appledomain.de> (raw)
In-Reply-To: <plop87vfi15ho3.fsf@gnu-rox.org>
* Xavier Maillard <zedek@gnu-rox.org> writes:
> Yo,
>
> Is there a possibility (I am pretty sure there is one) to make
> Gnus (No Gnus) highlighting code snippets for certain groups ?
>
> In fact I am reading a lot of Lisp related usenet groups and
> pretty often Lisp source are posted. My problem is I don't
> really see how I can tell Gnus to detect Lisp code in messages.
>
> So the idea would be to restrain this code detection on a set of
> known Lisp groups and have a pattern to detect Lisp mixed with
> text.
>
> Any idea on how to do this ?
Maybe this one can help you.
;; fontlocking Lisp in News,
;; i.e. all groups with 'gnu' and 'emacs'
(defvar egoge-emacs-lisp-ngs-regexp
(regexp-opt
'(
"gnu" "emacs"
)))
(add-to-list 'mm-uu-type-alist
'(emacs-lisp "^(" ")\\s-*\\(\n\n\\|\n?\\'\\)"
mm-uu-emacs-sources-extract nil
egoge-mm-uu-emacs-lisp-test))
(defun egoge-mm-uu-emacs-lisp-test ()
(and gnus-newsgroup-name
(string-match egoge-emacs-lisp-ngs-regexp
gnus-newsgroup-name)))
(mm-uu-configure)
Regards/Gruesse
Hans-Peter Binder
--
(coffee-mode -1)
next prev parent reply other threads:[~2004-06-09 8:32 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-06-09 7:12 Xavier Maillard
2004-06-09 8:32 ` Hans-Peter Binder [this message]
[not found] ` <plop87oens4hxm.fsf@gnu-rox.org>
[not found] ` <m2n03cl2s9.fsf@appledomain.de>
[not found] ` <ut5zn7cc57y.fsf@havengel.ii.uib.no>
[not found] ` <m24qpjyioa.fsf@appledomain.de>
2004-06-10 16:58 ` Steinar Børmer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m28yex9lnv.fsf@appledomain.de \
--to=hpb@appledomain.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).