Gnus development mailing list
 help / color / mirror / Atom feed
* new feature implemented: highlighting by regexp
@ 2003-06-23 21:46 Wes Hardaker
  2003-10-17 23:40 ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 2+ messages in thread
From: Wes Hardaker @ 2003-06-23 21:46 UTC (permalink / raw)
  Cc: Michael Baer

[-- Attachment #1: Type: text/plain, Size: 1614 bytes --]


I'm attaching code I've been tinkering with for a while and it seems to
be doing just fine.  Basically, it allows you to add highlighting
expressions to both summary and article buffer display.  Because gnus
is in a feature freeze, it is entirely self-contained and requires no
patches to gnus to make it work.  Eventually it probably should add
the treatment functions directly to the list in gnus-art.el, but since
I'm assuming it "wouldn't be prudent at this juncture" to check it
into CVS the code should probably not require a patch to gnus-art.el
at this point.  In the mean time, adding (require 'gnus-highlight) to
your .gnus file should be enough to enable it.

I'm interested in any feedback, of course...

There is no info documentation yet, but the variable descriptions
should be adequate enough to get you started.

FYI, I've only checked this under xemacs but I'm sure it's likely to
work without problems under emacs as there is nothing emacs specific
in it.  If the emacs users want to double check it for me, I'd
appreciate it.

Note: you can do cool highlighting using summary buffer bbdb marks and
this.  eg, I have a expression in use that looks like:

	("^......[^EOR].\\+[^[]*\\[\\([^]]+\\)\\]"    . "#b0e0ff")

Which highlights any authors name in a light purple who exists in my
.bbdb (the \\+ in the regexp) and the article is not read, expired or
old (the [^EOR]).  The rest of the expression selects the [.*] that
marks the author's name within the line.

-- 
"In the bathtub of history the truth is harder to hold than the soap,
 and much more difficult to find."  -- Terry Pratchett

[-- Attachment #2: gnus-highlight.el --]
[-- Type: application/emacs-lisp, Size: 8161 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: new feature implemented: highlighting by regexp
  2003-06-23 21:46 new feature implemented: highlighting by regexp Wes Hardaker
@ 2003-10-17 23:40 ` Lars Magne Ingebrigtsen
  0 siblings, 0 replies; 2+ messages in thread
From: Lars Magne Ingebrigtsen @ 2003-10-17 23:40 UTC (permalink / raw)


Wes Hardaker <wes@hardakers.net> writes:

> Basically, it allows you to add highlighting expressions to both
> summary and article buffer display.

Cool.  Please re-submit after No Gnus starts...  :-)

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2003-10-17 23:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-06-23 21:46 new feature implemented: highlighting by regexp Wes Hardaker
2003-10-17 23:40 ` Lars Magne Ingebrigtsen

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).