How to call \environment in CLD file
context.environment() just throws an error: context.environment("foo.tex") -- throws an error --context.input("foo.tex") -- fine context.starttext() context("foo") context.stoptext() Regards, Khaled -- Khaled Hosny Arabic localiser and member of Arabeyes.org team Free font developer
Khaled Hosny
context.environment("foo.tex") -- throws an error
context("\\environment foo ") -- Peter Münster Contact information: http://pmrb.free.fr/contact/
On Fri, Jan 14, 2011 at 06:52:25PM +0100, Peter Münster wrote:
Khaled Hosny
writes: context.environment("foo.tex") -- throws an error
context("\\environment foo ")
The same error, no difference. Regards, Khaled -- Khaled Hosny Arabic localiser and member of Arabeyes.org team Free font developer
On 14-1-2011 6:58, Khaled Hosny wrote:
On Fri, Jan 14, 2011 at 06:52:25PM +0100, Peter Münster wrote:
Khaled Hosny
writes: context.environment("foo.tex") -- throws an error
context("\\environment foo ")
The same error, no difference.
as it's \environment somename_followed_by_space we need: context.environment(false, "foo.tex ") a false will omit the {} for the next argument. and the space is after the filename. Sorry that it looks so hackerish. I think that it makes sense to patch \environment to accept [filename] as well. (It's an old command) Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
On 14-1-2011 6:58, Khaled Hosny wrote:
On Fri, Jan 14, 2011 at 06:52:25PM +0100, Peter Münster wrote:
Khaled Hosny
writes: context.environment("foo.tex") -- throws an error
context("\\environment foo ")
btw, you can also use \useenvironment[filename], so context.environment { "foo.tex" } ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
On Fri, Jan 14, 2011 at 07:23:27PM +0100, Hans Hagen wrote:
On 14-1-2011 6:58, Khaled Hosny wrote:
On Fri, Jan 14, 2011 at 06:52:25PM +0100, Peter Münster wrote:
Khaled Hosny
writes: context.environment("foo.tex") -- throws an error
context("\\environment foo ")
btw, you can also use \useenvironment[filename], so
context.environment { "foo.tex" }
context.useenvironment { "foo.tex" } you mean, that is fine with me, much cleaner. Regards, Khaled -- Khaled Hosny Arabic localiser and member of Arabeyes.org team Free font developer
Khaled Hosny
On Fri, Jan 14, 2011 at 06:52:25PM +0100, Peter Münster wrote:
Khaled Hosny
writes: context.environment("foo.tex") -- throws an error
context("\\environment foo ")
The same error, no difference.
Then a minimal example is needed. This works here: local env = io.open("foo.tex", "w") env:write"\\setuplayout[width=1em]\n" env:close() context"\\environment foo " context.starttext() context"bla bla" context.stoptext() -- Peter Münster Contact information: http://pmrb.free.fr/contact/
On Fri, Jan 14, 2011 at 07:32:39PM +0100, Peter Münster wrote:
Khaled Hosny
writes: On Fri, Jan 14, 2011 at 06:52:25PM +0100, Peter Münster wrote:
Khaled Hosny
writes: context.environment("foo.tex") -- throws an error
context("\\environment foo ")
The same error, no difference.
Then a minimal example is needed. This works here:
Right, I just missed the space. Regards, Khaled -- Khaled Hosny Arabic localiser and member of Arabeyes.org team Free font developer
participants (3)
-
Hans Hagen
-
Khaled Hosny
-
pmlists@free.fr