Re: Color mode in mhonarc?

2005-07-16 15:14:23
On Sat, Jul 16, 2005 at 02:19:09PM -0500, Earl Hood wrote:
On July 15, 2005 at 11:28, saf wrote:

I have a new question (I know I have so many questions!):
Is it possible to activate a kind of filter to show a different display 
for some different content?

You'll need to create a custom MIMEFILTERS filter for this.

I know I'm not on the right mailing list for this question,
but is it possible in mharc to specifiy mimefilters individually for specific 
mailing lists?
I could for example add syntax highlighting for all Perl, Python and other 
language mailing lists.

Having a general purpose one would be too complex and riddled with
false positives.

I think also, you are right.

I think the idea is nice, but such capabilities would have more
success on a per-list/archive basis.  For example, if the list
is known to be about Perl, with code examples being common, you
can register the "perl" filter for that archive, and that archive

(With Perl, you can just tell everyone to post messages in POD, and
 then just use a POD filter :-)

I think the people will never be so disciplined to do that! :-)

Another example is when another user recently posted about
auto-detecting python code.  However, python examples can conflict
with quoted-text rendering.  Therefore, something that would
highlight python code should only be applied to archives where
python code is common.

Yes it's a little complex, but could be possible, the question is,
can we tolerate some syntax highlighting errors? I think yes,
emacs has also some times some problems with syntax highlighting.

Side Comment: Now, if such code was tagged with its own media-type,
then something more general can be done.  I.e.  Messages are
authored using a multipart type, intermixing text/plain with
the code snippets.  For example:

  Subject: Perl code example
  Content-Type: multipart/mixed; boundary="XXX

  Content-Type: text/plain

  Check out the following code snippet:

  Content-Type: text/x-perl

  if ($x) {
    print "HELLO\n";
  } else {
    print "GOODBYE\n";

  Content-Type: text/plain

  Blah blah blah.


This is a good idea, but I think the people are too lazy to post messages in 
this format!

Of course, do not hold your breath for people actually doing this.
Most popular MUAs do not allow building such constructs easily,
if not at all.  It seems common practice nowadays for multipart
messages to be only for attachments versus a sequence of differing
(inline) media-types.

I will see what I could do with the mimefilters!

Best regards,
Administrator at
GnuPG public key: gpg --keyserver --recv-key 94B2664F

Attachment: signature.asc
Description: Digital signature

<Prev in Thread] Current Thread [Next in Thread>