all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#36523: 26.1; Image files are sometimes not found
@ 2019-07-06 12:16 Markus Triska
  2019-07-06 12:33 ` Eli Zaretskii
  0 siblings, 1 reply; 2+ messages in thread
From: Markus Triska @ 2019-07-06 12:16 UTC (permalink / raw)
  To: 36523


When I start Emacs with "$ emacs -Q", the description of the variable
data-directory reads:

    data-directory is a variable defined in ‘C source code’.
    Its value is "/opt/local/share/emacs/26.1/etc/"

In addition, I see that there is a file right.xpm with path:

    /opt/local/share/emacs/26.1/etc/images/custom/right.xpm

Also, the info manual states in 39.17.2 Image Descriptors:

   ‘:file FILE’
        This says to load the image from file FILE.  If FILE is not an
        absolute file name, it is expanded in ‘data-directory’.

Hence, I expect the following form to insert right.xpm, which is located
in images/custom/right.xpm relative to data-directory:

   (insert-image '(image :type xpm
                         :file "images/custom/right.xpm"
                         :ascent center))

However, when I evaluate the form with C-x C-e, I see a blank rectangle
at the end of the form instead of the intended image.

In contrast, changing the form to:

   (insert-image '(image :type xpm
                         :file "custom/right.xpm"
                         :ascent center))

inserts the intended image. Please note that "images/" had to be dropped
from the path, even though it belongs to the path of the file.

Could you please consider changing the documentation or implementation
to match the observed behaviour?

Thank you and all the best,
Markus


In GNU Emacs 26.1 (build 1, x86_64-apple-darwin15.3.0, X toolkit, Xaw scroll bars)
 of 2018-09-22 built on laptop
Windowing system distributor 'The X.Org Foundation', version 11.0.11502000

Configured features:
XPM JPEG TIFF GIF PNG GSETTINGS NOTIFY ACL GNUTLS LIBXML2 FREETYPE XFT
ZLIB TOOLKIT_SCROLL_BARS LUCID X11 MODULES THREADS LCMS2






^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#36523: 26.1; Image files are sometimes not found
  2019-07-06 12:16 bug#36523: 26.1; Image files are sometimes not found Markus Triska
@ 2019-07-06 12:33 ` Eli Zaretskii
  0 siblings, 0 replies; 2+ messages in thread
From: Eli Zaretskii @ 2019-07-06 12:33 UTC (permalink / raw)
  To: Markus Triska; +Cc: 36523-done

> From: Markus Triska <triska@metalevel.at>
> Date: Sat, 06 Jul 2019 14:16:03 +0200
> 
> 
> Also, the info manual states in 39.17.2 Image Descriptors:
> 
>    ‘:file FILE’
>         This says to load the image from file FILE.  If FILE is not an
>         absolute file name, it is expanded in ‘data-directory’.
> 
> Hence, I expect the following form to insert right.xpm, which is located
> in images/custom/right.xpm relative to data-directory:
> 
>    (insert-image '(image :type xpm
>                          :file "images/custom/right.xpm"
>                          :ascent center))
> 
> However, when I evaluate the form with C-x C-e, I see a blank rectangle
> at the end of the form instead of the intended image.
> 
> In contrast, changing the form to:
> 
>    (insert-image '(image :type xpm
>                          :file "custom/right.xpm"
>                          :ascent center))
> 
> inserts the intended image. Please note that "images/" had to be dropped
> from the path, even though it belongs to the path of the file.
> 
> Could you please consider changing the documentation or implementation
> to match the observed behaviour?

Fixed, thanks.





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-07-06 12:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-06 12:16 bug#36523: 26.1; Image files are sometimes not found Markus Triska
2019-07-06 12:33 ` Eli Zaretskii

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.