ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* image file resolver in Lua?
@ 2018-02-02  7:40 Henning Hraban Ramm
  2018-02-02 11:08 ` Rudolf Bahr
  0 siblings, 1 reply; 14+ messages in thread
From: Henning Hraban Ramm @ 2018-02-02  7:40 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Ahoi,

I’m using a Lua function to calculate image sizes, cropping etc.
This snippet:

local filename = figures.current().status.fullname
local pic = img.scan{filename = filename}

... works most of the time, but sometimes the "current" image is the previous one, might be because I’m using layers and postponing.
So I’d like to use just the same filename as I give to \externalfigure, i.e. without path and extension.
How can I address the same file path resolver in my Lua function?


Greetlings, Hraban
---
http://www.fiee.net
http://wiki.contextgarden.net
GPG Key ID 1C9B22FD

___________________________________________________________________________________
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

end of thread, other threads:[~2018-02-20  9:03 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-02  7:40 image file resolver in Lua? Henning Hraban Ramm
2018-02-02 11:08 ` Rudolf Bahr
2018-02-02 15:17   ` Henning Hraban Ramm
2018-02-03  6:57     ` Rudolf Bahr
2018-02-04 12:06       ` Hans Hagen
2018-02-04 18:04         ` Henning Hraban Ramm
2018-02-05 20:22           ` Pablo Rodriguez
2018-02-06  8:34           ` Procházka Lukáš Ing.
2018-02-06 12:13             ` Henning Hraban Ramm
2018-02-06 16:09               ` Procházka Lukáš Ing.
2018-02-06 19:51                 ` Henning Hraban Ramm
2018-02-05 14:12         ` Rudolf Bahr
2018-02-08 20:40         ` Henning Hraban Ramm
2018-02-20  9:03         ` Henning Hraban Ramm

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).