info-gnus-english
[Top][All Lists]
Advanced

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

Re: gnus opening attachments


From: Lars Ingebrigtsen
Subject: Re: gnus opening attachments
Date: Sat, 28 Jan 2012 19:48:00 +0100
User-agent: Gnus/5.110018 (No Gnus v0.18) Emacs/24.0.92 (gnu/linux)

Thien-Thi Nguyen <ttn@gnuvola.org> writes:

> The order in ‘mailcap-mime-data’ is only relevant if there are no
> wildcards or Lisp-handled viewer candidates.  This is because when
> those are present, they are de-prioritized as a result of:
>
>         (setq passed (sort passed 'mailcap-viewer-lessp))
>
> You can reproduce the problem by adding something like:
>
>   image/*; xloadimage -shrink %s

Ah, I see.  So the idea is to allow (say) image/png to override image/*
without the sorting having to be explicit.  This allows the user to
provide defaults for the stuff not specified in the built-in alist.

It makes sense, I guess, but if the user really wants all image/* types
to go somewhere specific, then there's no way to do that the current way
it works, which sucks.

> One solution is to expose the "lessp" arg to the ‘sort’ call as a
> variable, so users can specify a function that causes wildcard "*" to
> mean override instead of default (as it is currently).  This is more
> upward compatible than the alternative -- adding a variable to disable
> sorting entirely -- since the MIME support infrastructure in Debian
> (and maybe others) now includes a user-specified "priority" option
> (man "update-mime").

Right...  so perhaps the best solution here would just be to add the
"priority" stuff to mailcap.el?  Then you can say

image/*; xloadimage %s; priority=5

to use xloadimage on all the images?

No Gnus/Emacs 24 is in a feature freeze at the moment, though, and this
would count as a new feature, I think, so implementing this would have
to wait a bit.

-- 
(domestic pets only, the antidote for overdose, milk.)
  http://lars.ingebrigtsen.no  *  Sent from my Rome



reply via email to

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