* Re: User agent highlighting in gnus
[not found] <fa7ov3$1kjv$1@talisker.lacave.net>
@ 2007-08-19 9:08 ` Reiner Steib
2007-08-19 14:01 ` Xavier Maillard
2007-08-19 16:38 ` Hadron
0 siblings, 2 replies; 10+ messages in thread
From: Reiner Steib @ 2007-08-19 9:08 UTC (permalink / raw)
To: info-gnus-english
On Sat, Aug 18 2007, Xavier Maillard wrote:
> highlights user-agent header according to three distinct lists of
> good, bad and unknown user-agents.
Using `gnus-header-face-alist' seems much more simple. Something like
the following...
(add-to-list
'gnus-header-face-alist
(list (concat
"^"
(regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
":.*"
(regexp-opt '("Gnus" "Mutt") t))
nil font-lock-keyword-face))
Bye, Reiner.
Crosspost & Followup-To: gnu.emacs.gnus
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-19 9:08 ` User agent highlighting in gnus Reiner Steib
@ 2007-08-19 14:01 ` Xavier Maillard
2007-08-19 16:23 ` Reiner Steib
2007-08-19 16:38 ` Hadron
1 sibling, 1 reply; 10+ messages in thread
From: Xavier Maillard @ 2007-08-19 14:01 UTC (permalink / raw)
To: info-gnus-english
Reiner Steib wrote:
> On Sat, Aug 18 2007, Xavier Maillard wrote:
>
>> highlights user-agent header according to three distinct lists of
>> good, bad and unknown user-agents.
>
> Using `gnus-header-face-alist' seems much more simple. Something like
> the following...
Maybe you are right :) That's pretty old code so dunno if
gnus-header-face-alist existed at that time.
Xavier
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-19 14:01 ` Xavier Maillard
@ 2007-08-19 16:23 ` Reiner Steib
0 siblings, 0 replies; 10+ messages in thread
From: Reiner Steib @ 2007-08-19 16:23 UTC (permalink / raw)
To: info-gnus-english
On Sun, Aug 19 2007, Xavier Maillard wrote:
> That's pretty old code so dunno if gnus-header-face-alist existed at
> that time.
`gnus-header-face-alist' was changed from defvar to defcustom in
1997. ;-)
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-19 9:08 ` User agent highlighting in gnus Reiner Steib
2007-08-19 14:01 ` Xavier Maillard
@ 2007-08-19 16:38 ` Hadron
2007-08-19 22:02 ` Reiner Steib
1 sibling, 1 reply; 10+ messages in thread
From: Hadron @ 2007-08-19 16:38 UTC (permalink / raw)
To: info-gnus-english
Reiner Steib <reinersteib+gmane@imap.cc> writes:
> On Sat, Aug 18 2007, Xavier Maillard wrote:
>
>> highlights user-agent header according to three distinct lists of
>> good, bad and unknown user-agents.
>
> Using `gnus-header-face-alist' seems much more simple. Something like
> the following...
>
> (add-to-list
> 'gnus-header-face-alist
> (list (concat
> "^"
> (regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
> ":.*"
> (regexp-opt '("Gnus" "Mutt") t))
> nil font-lock-keyword-face))
>
> Bye, Reiner.
>
> Crosspost & Followup-To: gnu.emacs.gnus
Could you explain this block. Not being a lisp programmer I can't really
see how to set a nice "loud" face for all User-Agent or X-Newsreader with
"Mutt" in and another font for either with "Gnus" in and another for
either with any other face again.
--
Perl combines all of the worst aspects of BASIC, C and line noise.
-- Keith Packard
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-19 16:38 ` Hadron
@ 2007-08-19 22:02 ` Reiner Steib
2007-08-20 14:43 ` Hadron
0 siblings, 1 reply; 10+ messages in thread
From: Reiner Steib @ 2007-08-19 22:02 UTC (permalink / raw)
To: info-gnus-english
On Sun, Aug 19 2007, Hadron wrote:
> Could you explain this block. Not being a lisp programmer I can't really
> see how to set a nice "loud" face for all User-Agent or X-Newsreader with
> "Mutt" in and another font for either with "Gnus" in and another for
> either with any other face again.
(add-to-list
'gnus-header-face-alist
(list (concat
"^"
(regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
":.*Mutt")
nil your-mutt-face))
(add-to-list
'gnus-header-face-alist
(list (concat
"^"
(regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
":.*Gnus")
nil your-gnus-face))
(add-to-list
'gnus-header-face-alist
(list (concat
"^"
(regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
":.*") ;; other
nil your-other-reader-face))
You need to defface your-*-face. I'm not sure if the order works in
this way. You may have to change it or add the APPEND argument of
`add-to-list'.
Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-19 22:02 ` Reiner Steib
@ 2007-08-20 14:43 ` Hadron
2007-08-21 14:38 ` Steffen Schwigon
0 siblings, 1 reply; 10+ messages in thread
From: Hadron @ 2007-08-20 14:43 UTC (permalink / raw)
To: info-gnus-english
Reiner Steib <reinersteib+gmane@imap.cc> writes:
> On Sun, Aug 19 2007, Hadron wrote:
>
>> Could you explain this block. Not being a lisp programmer I can't really
>> see how to set a nice "loud" face for all User-Agent or X-Newsreader with
>> "Mutt" in and another font for either with "Gnus" in and another for
>> either with any other face again.
>
> (add-to-list
> 'gnus-header-face-alist
> (list (concat
> "^"
> (regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
> ":.*Mutt")
> nil your-mutt-face))
>
> (add-to-list
> 'gnus-header-face-alist
> (list (concat
> "^"
> (regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
> ":.*Gnus")
> nil your-gnus-face))
>
> (add-to-list
> 'gnus-header-face-alist
> (list (concat
> "^"
> (regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
> ":.*") ;; other
> nil your-other-reader-face))
>
> You need to defface your-*-face. I'm not sure if the order works in
> this way. You may have to change it or add the APPEND argument of
> `add-to-list'.
>
> Bye, Reiner.
Just for google completion:
Other way around - here I hilite gnus and Outlook type and used quoting
for the face names available from list-faces-display from the facemenu+
library from drew adams.
,----
| (add-to-list
| 'gnus-header-face-alist
| (list (concat
| "^"
| (regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
| ":.*") ;; other
| nil font-lock-comment-face))
|
| (add-to-list
| 'gnus-header-face-alist
| (list (concat
| "^"
| (regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
| ":.*Outlook.*")
| nil 'gnus-emphasis-highlight-words))
|
| (add-to-list
| 'gnus-header-face-alist
| (list (concat
| "^"
| (regexp-opt '("User-Agent" "X-Mailer" "Newsreader" "X-Newsreader") t)
| ":.*Gnus.*")
| nil 'gnus-server-opened))
|
`----
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-20 14:43 ` Hadron
@ 2007-08-21 14:38 ` Steffen Schwigon
2007-08-21 14:52 ` Simias
2007-08-21 15:39 ` Hadron
0 siblings, 2 replies; 10+ messages in thread
From: Steffen Schwigon @ 2007-08-21 14:38 UTC (permalink / raw)
To: info-gnus-english
Hadron <hadronquark@googlemail.com> writes:
>
> ,----
> |
> | ...
> |
> `----
BTW, how do you generate those frame'd quotes? Is this a gnus or an
emacs feature or do you draw it manually? Sometimes also a variant of
this appears in this list, that contains a header like a section from
an info manual.
Steffen
--
Steffen Schwigon <schwigon@webit.de>
Dresden Perl Mongers <http://dresden-pm.org/>
Deutscher Perl-Workshop <http://www.perl-workshop.de/>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-21 14:38 ` Steffen Schwigon
@ 2007-08-21 14:52 ` Simias
2007-08-22 12:38 ` Steffen Schwigon
2007-08-21 15:39 ` Hadron
1 sibling, 1 reply; 10+ messages in thread
From: Simias @ 2007-08-21 14:52 UTC (permalink / raw)
To: info-gnus-english
Steffen Schwigon <schwigon@webit.de> writes:
> Hadron <hadronquark@googlemail.com> writes:
>>
>> ,----
>> |
>> | ...
>> |
>> `----
>
> BTW, how do you generate those frame'd quotes? Is this a gnus or an
> emacs feature or do you draw it manually? Sometimes also a variant of
> this appears in this list, that contains a header like a section from
> an info manual.
>
> Steffen
I think this is what you want:
,----
| http://www.davep.org/emacs/boxquote.el
`----
see? :)
--
Simias
rot13 for email
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-21 14:38 ` Steffen Schwigon
2007-08-21 14:52 ` Simias
@ 2007-08-21 15:39 ` Hadron
1 sibling, 0 replies; 10+ messages in thread
From: Hadron @ 2007-08-21 15:39 UTC (permalink / raw)
To: info-gnus-english
Steffen Schwigon <schwigon@webit.de> writes:
> Hadron <hadronquark@googlemail.com> writes:
>>
>> ,----
>> |
>> | ...
>> |
>> `----
>
> BTW, how do you generate those frame'd quotes? Is this a gnus or an
> emacs feature or do you draw it manually? Sometimes also a variant of
> this appears in this list, that contains a header like a section from
> an info manual.
>
> Steffen
boxquote-region
its in the debian emacs-goodies-el package but you can find the elisp
elsewhere too.
--
Please, Mother! I'd rather do it myself!
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: User agent highlighting in gnus
2007-08-21 14:52 ` Simias
@ 2007-08-22 12:38 ` Steffen Schwigon
0 siblings, 0 replies; 10+ messages in thread
From: Steffen Schwigon @ 2007-08-22 12:38 UTC (permalink / raw)
To: info-gnus-english
Simias <fvzvnf.a@tznvy.pbz> writes:
> I think this is what you want:
>
> ,----
> | http://www.davep.org/emacs/boxquote.el
> `----
>
> see? :)
Ah, nice.
Thanks. :-)
Steffen
--
,----
| Steffen Schwigon <schwigon@webit.de>
| Dresden Perl Mongers <http://dresden-pm.org/>
| Deutscher Perl-Workshop <http://www.perl-workshop.de/>
`----
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2007-08-22 12:38 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <fa7ov3$1kjv$1@talisker.lacave.net>
2007-08-19 9:08 ` User agent highlighting in gnus Reiner Steib
2007-08-19 14:01 ` Xavier Maillard
2007-08-19 16:23 ` Reiner Steib
2007-08-19 16:38 ` Hadron
2007-08-19 22:02 ` Reiner Steib
2007-08-20 14:43 ` Hadron
2007-08-21 14:38 ` Steffen Schwigon
2007-08-21 14:52 ` Simias
2007-08-22 12:38 ` Steffen Schwigon
2007-08-21 15:39 ` Hadron
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).