Gnus development mailing list
 help / color / mirror / Atom feed
From: Uwe Brauer <oub@mat.ucm.es>
To: ding@gnus.org
Cc: XEmacs Beta Discussion <xemacs-beta@xemacs.org>
Subject: problem in gnus-html-display-image: Xemacs while GNU Emacs is ok
Date: Wed, 15 Oct 2014 14:15:43 +0200	[thread overview]
Message-ID: <87a94xmsuo.fsf@mat.ucm.es> (raw)



gnus-html-display-image works differently in Xemacs an in gnus, 

A html message which contains some link to a gif image, is displayed
with GNU correctly but not with Xemacs. I debugged it with both Emacsen.

GNU emacs
(defun gnus-html-display-image (url start end &optional alt-text)
  "Display image at URL on text from START to END.
Use ALT-TEXT for the image string."
  (or alt-text (setq alt-text "*"))
  (if (string-match "\\`cid:" url)
      (let ((handle (mm-get-content-id (substring url (match-end 0)))))
	(when handle
	  (gnus-html-put-image (mm-with-part handle (buffer-string))
			       url alt-text)))
    (if (gnus-html-cache-expired url gnus-html-image-cache-ttl)
	;; We don't have it, so schedule it for fetching
	;; asynchronously.
	(gnus-html-schedule-image-fetching
	 (current-buffer)
	 (list url alt-text))
      ;; It's already cached, so just insert it.
      (gnus-html-put-image (gnus-html-get-image-data url) url alt-text))))
                                                        ^^: minibuffer
                                                        displays some
                                                        buffer which is
                                                        in gif format
                                                        then the
                                                        function display
                                                        it.

Xemacs

(defun gnus-html-display-image (url start end &optional alt-text)
  "Display image at URL on text from START to END.
Use ALT-TEXT for the image string."
  (or alt-text (setq alt-text "*"))
  (if (string-match "\\`cid:" url)
      (let ((handle (mm-get-content-id (substring url (match-end 0)))))
	(when handle
	  (gnus-html-put-image (mm-with-part handle (buffer-string))
			       url alt-text)))
    (if (gnus-html-cache-expired url gnus-html-image-cache-ttl)
	;; We don't have it, so schedule it for fetching
	;; asynchronously.
	(gnus-html-schedule-image-fetching
	 (current-buffer)
	 (list url alt-text))
                         ^^^returns: (nil . " *URL-5*"), which is a
                         buffer in gif format: as said in a different
                         message xemacs does not display the content of
                         this message
      ;; It's already cached, so just insert it.
      (gnus-html-put-image (gnus-html-get-image-data url) url alt-text))))
                                                                      ^xemacs
                                                                      jumps
                                                                      over
                                                                      this
                                                                      ()
                                                                      and
                                                                      does
                                                                      nothing

Any help would be appreciated.

Uwe Brauer 




                 reply	other threads:[~2014-10-15 12:15 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87a94xmsuo.fsf@mat.ucm.es \
    --to=oub@mat.ucm.es \
    --cc=ding@gnus.org \
    --cc=xemacs-beta@xemacs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).