emacs-devel
[Top][All Lists]
Advanced

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

Re: display word wrapping


From: David Kastrup
Subject: Re: display word wrapping
Date: 08 Jun 2004 10:23:57 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

address@hidden (Kim F. Storm) writes:

> David Kastrup <address@hidden> writes:
> 
> > If an image type is known, I hope that it is present as just its
> > name, and _not_ as a cons cell (jpeg . t) or so.
> > 
> > If not, we have a major incompatibility to the previous behavior.  
> 
> I would not call it a major incompatibility.  Code should not rely
> on that variable -- they should call image-type-available-p.

Says who?

> > Can't we just keep the variable with the original meaning, and store
> > the lookup cache data somewhere else?
> 
> It could be done that way (the C code could use an internal
> unsupported_image_types list which is NOT exported to lisp).
> 
> But I don't see a big reason to do so (since image-types is not
> reliable anyway).

Tell that to the Elisp manual.  Even in its current version it says:

    File: elisp,  Node: Images,  Next: Buttons,  Prev: Display Property,  Up: 
Display

    Images
    ======

    To display an image in an Emacs buffer, you must first create an image
    descriptor, then use it as a display specifier in the `display'
    property of text that is displayed (*note Display Property::).  Like the
    `display' property, this feature is available starting in Emacs 21.

       Emacs can display a number of different image formats; some of them
    are supported only if particular support libraries are installed on your
    machine.  The supported image formats include XBM, XPM (needing the
    libraries `libXpm' version 3.4k and `libz'), GIF (needing `libungif'
    4.1.0), Postscript, PBM, JPEG (needing the `libjpeg' library version
    v6a), TIFF (needing `libtiff' v3.4), and PNG (needing `libpng' 1.0.2).

       You specify one of these formats with an image type symbol.  The
    image type symbols are `xbm', `xpm', `gif', `postscript', `pbm',
    `jpeg', `tiff', and `png'.

     - Variable: image-types
         This variable contains a list of those image type symbols that are
         supported in the current configuration.


image-type-available-p is not even documented anywhere.  And of
course, stupid as I am, I have followed the Elisp manual's information
in a package I provide.

Since image-types has been the only documented way of accessing that
information so far, I think there is some justification in not
changing its meaning before any package provider has had a chance to
adapt.

I would prefer it if there was some time window of changing packages
and adapting to new conventions before breaking things.

BTW, do you have an idea since which Emacs version
image-type-available-p has been available?

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum




reply via email to

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