Re: [NTG-context] Use figures without file extension

2012-05-27 Thread Rogers, Michael K
On May 26, 2012, at 10:49 PM, Aditya Mahajan wrote: using the inbuilt library is definely simpler! Yes, but as you said earlier, you'll still have to do something about GIFs. It would be nice if luatex had at worst a non-fatal error on scanning a non-supported file. Michael _

Re: [NTG-context] Use figures without file extension

2012-05-26 Thread Aditya Mahajan
On Sun, 27 May 2012, Rogers, Michael K wrote: I don't know if this helps but the following tells what the type of the image file is. (In my case I copied a jpg to img1 and a png to img2, without extensions of course.) Thanks. Hans implemented a version of unix file command for checking the

Re: [NTG-context] Use figures without file extension

2012-05-26 Thread Rogers, Michael K
I don't know if this helps but the following tells what the type of the image file is. (In my case I copied a jpg to img1 and a png to img2, without extensions of course.) \startluacode userdata = userdata or { } function userdata.mytype(s) context(img.scan({filename=s}).imagetype) end

Re: [NTG-context] Use figures without file extension

2012-05-26 Thread luigi scarso
On Sat, May 26, 2012 at 4:23 PM, Hans Hagen wrote: > On 26-5-2012 16:04, Aditya Mahajan wrote: >> >> On Sat, 26 May 2012, Hans Hagen wrote: >> >>> On 26-5-2012 04:08, Aditya Mahajan wrote: Currently, ConTeXt only recognizes the type of figure from the file extension. If a filename d

Re: [NTG-context] Use figures without file extension

2012-05-26 Thread Hans Hagen
On 26-5-2012 16:04, Aditya Mahajan wrote: On Sat, 26 May 2012, Hans Hagen wrote: On 26-5-2012 04:08, Aditya Mahajan wrote: Currently, ConTeXt only recognizes the type of figure from the file extension. If a filename does not have an extension, \externalfigure fails. For example: $ cp `luatoo

Re: [NTG-context] Use figures without file extension

2012-05-26 Thread Aditya Mahajan
On Sat, 26 May 2012, Hans Hagen wrote: On 26-5-2012 04:08, Aditya Mahajan wrote: Currently, ConTeXt only recognizes the type of figure from the file extension. If a filename does not have an extension, \externalfigure fails. For example: $ cp `luatools hacker.jpg` something ah .. i see, no

Re: [NTG-context] Use figures without file extension

2012-05-26 Thread Hans Hagen
On 26-5-2012 04:08, Aditya Mahajan wrote: Currently, ConTeXt only recognizes the type of figure from the file extension. If a filename does not have an extension, \externalfigure fails. For example: $ cp `luatools hacker.jpg` something ah .. i see, no extension .. too tricky to support that a

Re: [NTG-context] Use figures without file extension

2012-05-26 Thread Hans Hagen
On 26-5-2012 04:08, Aditya Mahajan wrote: \starttext \externalfigure[something] \stoptext weird ... here it works ... can you runt with tracing? \enabletrackers[graphics.locating] \starttext \externalfigure[cow] \stoptext Hans --

[NTG-context] Use figures without file extension

2012-05-25 Thread Aditya Mahajan
Currently, ConTeXt only recognizes the type of figure from the file extension. If a filename does not have an extension, \externalfigure fails. For example: $ cp `luatools hacker.jpg` something Then, \starttext \externalfigure[something] \stoptext fails. However, if I set