Re: [PATCH] emacs: honour notmuch-show-text/html-blocked-images in w3m messages

Subject: Re: [PATCH] emacs: honour notmuch-show-text/html-blocked-images in w3m messages

Date: Thu, 19 Aug 2021 11:16:16 +0100

To: Tomi Ollila, Jonathan Wilner, David Bremner, jao, notmuch@notmuchmail.org

Cc: jao

From: David Edmondson


On Thursday, 2021-08-19 at 12:54:51 +03, Tomi Ollila wrote:

> On Tue, Aug 17 2021, David Edmondson wrote:
>
>> On Tuesday, 2021-08-17 at 09:07:53 -07, Jonathan Wilner wrote:
>>
>>> Apologies in advance for thread-jacking this patch !
>>>
>>> No matter what I try to do, I can't configure notmuch/emacs to show
>>> any inline images. That's using any of the renderer options, from shr
>>> to the various w3ms, other than html2text. I've set every possible
>>> variable to allow things, to no avail.
>>>
>>> Using w3m under Emacs on the same machine pulls in local and network images fine.
>>>
>>> Does anyone either have this working as the default or even using a
>>> toggle ("T") to enable images one message at time?
>>
>> I use (with shr):
>>
>> (defun dme:notmuch-show-refresh-show-images ()
>>   "Refresh the current buffer with external images enabled."
>>   (interactive)
>>   (make-local-variable 'notmuch-show-text/html-blocked-images)
>>   (setq notmuch-show-text/html-blocked-images nil)
>
> How does let-bind differ with the above ?

It would be fine.

>>   (notmuch-show-refresh-view))
>> (define-key notmuch-show-mode-map "I" 'dme:notmuch-show-refresh-show-images)
>>
>
> Tomi
>
>>>
>>> Thanks in advance,
>>>
>>> Jonathan
>>>
>>> David Bremner <david@tethera.net> writes:
>>>
>>>> jao <jao@gnu.org> writes:
>>>>
>>>>> When mm-text-html-renderer is set to 'w3m, the variable playing the
>>>>> role of a regular expression for blocked images is
>>>>> w3m-ignored-image-url-regexp.  We bind it when the renderer is not
>>>>> 'shr.
>>>>> ---
>>>> applied to master
>>>> _______________________________________________
>>>> notmuch mailing list -- notmuch@notmuchmail.org
>>>> To unsubscribe send an email to notmuch-leave@notmuchmail.org
>>> _______________________________________________
>>> notmuch mailing list -- notmuch@notmuchmail.org
>>> To unsubscribe send an email to notmuch-leave@notmuchmail.org
>> _______________________________________________
>> notmuch mailing list -- notmuch@notmuchmail.org
>> To unsubscribe send an email to notmuch-leave@notmuchmail.org
> _______________________________________________
> notmuch mailing list -- notmuch@notmuchmail.org
> To unsubscribe send an email to notmuch-leave@notmuchmail.org
_______________________________________________
notmuch mailing list -- notmuch@notmuchmail.org
To unsubscribe send an email to notmuch-leave@notmuchmail.org

Thread: