From: Sanjoy Mahajan <sanjoy@olin.edu>
To: <ntg-context@ntg.nl>
Subject: \externalfigure doesn't find mps file in subdirectory
Date: Sun, 4 Aug 2013 09:04:52 -0400 [thread overview]
Message-ID: <87k3k138uj.fsf@approx.mit.edu> (raw)
\externalfigure won't find a metapost eps file in a subdirectory, if the
mps has the numerical (.1) extension.
Here's a minimal example (test.tex):
\setupexternalfigures[directory={fig}]
\starttext
\externalfigure[simple.1]
\stoptext
where fig/simple.1 is from a simple .mp file that fills a 1-cm box (see
below).
The resulting test.pdf shows the gray box
name : simple.1
file : simple.1
state: unknown
Only this combination of circumstances triggers the problem. Giving the
full path ("\externalfigure[fig/simple.1]") works fine, as does renaming
the file to simple.mps (within the fig/ directory), as does using
instead simple-1.pdf (made with mptopdf).
Thus, I have several workarounds, but it might be useful to figure out
what is not working. I've noticed this problem on and off for a while
now, but only now made a minimal example. (Is the path-searching code
trying to append extensions and directory prefixes at the same time, and
thus not finding the file?)
This is with MkIV 2013.05.28 from vanilla TL2013.
For completeness, here's simple.1, although any file will show the
problem equally well:
%!PS
%%BoundingBox: 0 0 29 29
%%HiResBoundingBox: 0 0 28.34645 28.34645
%%Creator: MetaPost 1.803
%%CreationDate: 2013.08.04:0841
%%Pages: 1
%%BeginProlog
%%EndProlog
%%Page: 1 1
0 0 0 setrgbcolor
newpath 0 0 moveto
28.34645 0 lineto
28.34645 28.34645 lineto
0 28.34645 lineto
closepath fill
showpage
%%EOF
-Sanjoy
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
next reply other threads:[~2013-08-04 13:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-08-04 13:04 Sanjoy Mahajan [this message]
2013-08-05 12:37 ` Sanjoy Mahajan
2013-08-05 21:18 ` Sietse Brouwer
2013-08-05 22:00 ` Hans Hagen
2013-08-06 9:04 ` Sietse Brouwer
2013-08-06 12:38 ` Sanjoy Mahajan
2013-08-06 7:50 ` Alan BRASLAU
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=87k3k138uj.fsf@approx.mit.edu \
--to=sanjoy@olin.edu \
--cc=ntg-context@ntg.nl \
/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).