unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: "Juanma Barranquero" <lekktu@gmail.com>
Cc: chunyu@hit.edu.cn, emacs-devel@gnu.org
Subject: Re: .eps in image mode
Date: Mon, 25 Dec 2006 04:15:20 +0100	[thread overview]
Message-ID: <f7ccd24b0612241915m2a38a98evc8d62c3a1cf1bfe1@mail.gmail.com> (raw)
In-Reply-To: <E1GyWqu-0002WO-9W@fencepost.gnu.org>

On 12/24/06, Richard Stallman <rms@gnu.org> wrote:

> Does this patch give the right results?

> *** image.el    19 Dec 2006 11:57:52 -0500      1.64
> --- image.el    23 Dec 2006 21:04:58 -0500

It certainly works for `magic-mode-alist', i.e., it forces PostScript
files not to be automatically detected as images.

As for this part, INCLUDE-MAYBES is declared as a new argument, but it
is not referenced outside of the docstring, so
`image-type-from-file-header' still returns nil for PostScript files:

> --- 225,246 ----
>
>
>   ;;;###autoload
> ! (defun image-type-from-buffer (&optional include-maybes)
>     "Determine the image type from data in the current buffer.
> ! Value is a symbol specifying the image type, or nil if none
> ! corresponds to the buffer contents.
> !
> ! If INCLUDE-MAYBES is nil (the default), we return nil for
> ! file types that should not always be treated as images
> ! even though they can be so treated."
>     (let ((types image-type-header-regexps)
>         type
>         (opoint (point)))
>       (goto-char (point-min))
>       (while types
>         (let ((regexp (car (car types)))
> !           (image-type (nth 1 (car types)))
> !           (not-always (nth 2 (car types)))
>             data)
>         (if (or (and (symbolp image-type)
>                      (looking-at regexp))

                    /L/e/k/t/u

  reply	other threads:[~2006-12-25  3:15 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87irg45jh6.fsf@chunyu.hit.edu.cn>
2006-12-23 20:14 ` .eps in image mode Richard Stallman
2006-12-23 22:52   ` Juanma Barranquero
2006-12-24 17:09     ` Richard Stallman
2006-12-25  3:15       ` Juanma Barranquero [this message]
2006-12-26  2:25         ` Richard Stallman

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=f7ccd24b0612241915m2a38a98evc8d62c3a1cf1bfe1@mail.gmail.com \
    --to=lekktu@gmail.com \
    --cc=chunyu@hit.edu.cn \
    --cc=emacs-devel@gnu.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.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).