[NTG-context] extracting pages using luacode
Hans Hagen
j.hagen at xs4all.nl
Sat Apr 25 16:56:30 CEST 2020
On 4/25/2020 4:17 PM, Floris van Manen wrote:
> I'm trying to extract pages from an existing pdf using lua.
> But this approach to extract pages 11 and 30 does not work:
>
> \starttext
> \startluacode
> for i, blz in ipairs({11, 30}) do
> context.startTEXpage()
> context.externalfigure("my_pdf.pdf", page=blz)
> context.stopTEXpage()
> end
> \stopluacode
> \stoptext
>
>
> Where am I missing the point?
the syntax ...
context.externalfigure( { "my_pdf.pdf" }, { page = blz } )
-----------------------------------------------------------------
Hans Hagen | PRAGMA ADE
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-----------------------------------------------------------------
More information about the ntg-context
mailing list