[NTG-context] About the use of command handlers

2020-05-28 Thread Jairo A. del Rio
Hello list! I was reading the following: https://wiki.contextgarden.net/Style_Alternatives I wanted to figure out how to make a simple module. However, there's a point in the example below which I don't understand % macros=mkvi \startmodule[look] \unprotect \writestatus{loading}{ConTeXt User

Re: [NTG-context] Checking existence of a macro (control sequence) by Lua

2020-05-28 Thread context
Hello, one more question - why macros \Undefined and \DoNothing show "defined" although I (tried to) undefine them? \starttext \def\MyMacro{Ahoj} \def\MyMac#1#2{Something} \def\Undefined{} \let\Undefined\undefined \def\DoNothing{} \let\DoNothing\donothing \startluacode

[NTG-context] referencing both real and user pagenumbers

2020-05-28 Thread Alan Bowen
I have a collection of papers printed previously that are to go into a single volume so that, while the papers retain their original pagination and internal cross-referencing, they are also paginated continuously. I have managed to do this using userpagenumbers for the individual papers and

[NTG-context] annotations in \insertpages

2020-05-28 Thread Pablo Rodriguez
Dear list, I have the following sample: \setupinteraction[state=start] \starttext \attachment[file=https://kbdeveloper.qoppa.com/wp-content/uploads/blank_signed.pdf] \insertpages[https://kbdeveloper.qoppa.com/wp-content/uploads/blank_signed.pdf][interaction=all] \stoptext Is there

[NTG-context] Unicode chars and \insertpages (Win7)

2020-05-28 Thread Pablo Rodriguez
Dear list, I have the following sample: \startext \insertpages[ξ_file.pdf] \stoptext Using latest on Linux, it works perfectly fine. On Windows (I’m still on Win7), it doesn’t work unless I replace "ξ" with an ASCII character. Could this be fixed or is it really a limiatation of

Re: [NTG-context] Dangerous bend metafont/post code?

2020-05-28 Thread Gerben Wierda
I’ve used:\startMPpage[instance=doublefun]% Inspired by and largely copied from Donald Knuth's METAFONT dangerous bend glyphh=11;u=h/15;w=h*8.5/4.6;heavyline=2;y1=25/27h;x4=0;x1+x1=x1a+x1b=x4b+x2a=x4+x2=x4a+x2b=x3b+x3a=x3+x3=w;x4a=x4b=x4+u;

Re: [NTG-context] 'debug' version of METAPOST draw?

2020-05-28 Thread Keith McKay
Would Chapter 11, section 11.1 Showing Paths of the MetaPost manual, be any help here? Below is a MWE of a random path of curves and straight lines. The points are shown using drawpoints. The arrow path and control lines are also shown and are better described in the Metapost manual.

Re: [NTG-context] bug in \doifinset

2020-05-28 Thread Pablo Rodriguez
On 5/28/20 12:23 AM, Hans Hagen wrote: > On 5/27/2020 10:39 PM, Wolfgang Schuster wrote: >> Pablo Rodriguez schrieb am 27.05.2020 um 22:31: >>> [...] >>> I think this may be a bug, since the sample above would only get "yes" >>> with { i7}. >> >> No spaces are allowed in these lists. Older

Re: [NTG-context] bug in \doifinset

2020-05-28 Thread Pablo Rodriguez
On 5/27/20 11:58 PM, luigi scarso wrote: >> On Wed, May 27, 2020 at 11:28 PM Pablo Rodriguez wrote: >> Without commas, lists are harder both to read and to write (at least, to me). > > what about > > \starttext > \startTEXpage[offset=1em] > \doifinsetelse{i7}{% > i4,% > i5,% > i7,% > } >        

Re: [NTG-context] LMTX: different output if dots are used in the file name

2020-05-28 Thread Marco Patzer
On Thu, 28 May 2020 18:18:51 +0200 Hans Hagen wrote: > > MkIV (everything's predictable and fine): > > 10.10.10.tex → 10.10.10.pdf > > 10.10.11.tex → 10.10.11.pdf > > 11.10.11.tex → 11.10.11.pdf > > > > LMTX: > > 10.10.10.tex → 10.10 (not even a PDF suffix) > >

Re: [NTG-context] LMTX: different output if dots are used in the file name

2020-05-28 Thread Hans Hagen
On 5/28/2020 5:59 PM, Marco Patzer wrote: On Thu, 28 May 2020 17:33:19 +0200 Hans Hagen wrote: On 5/28/2020 2:49 PM, Marco Patzer wrote: Hi! LMTX and MkIV behave differently if dots are used in the file name. Example: printf '%s\n' '\starttext\null\stoptext' > foo.10.tex && context

Re: [NTG-context] LMTX: different output if dots are used in the file name

2020-05-28 Thread Marco Patzer
On Thu, 28 May 2020 17:33:19 +0200 Hans Hagen wrote: > On 5/28/2020 2:49 PM, Marco Patzer wrote: > > Hi! > > > > LMTX and MkIV behave differently if dots are used in the file > > name. Example: > > > >printf '%s\n' '\starttext\null\stoptext' > foo.10.tex && context > > foo.10.tex > > > >

Re: [NTG-context] LMTX: different output if dots are used in the file name

2020-05-28 Thread Marco Patzer
On Thu, 28 May 2020 17:33:19 +0200 Hans Hagen wrote: > On 5/28/2020 2:49 PM, Marco Patzer wrote: > > Hi! > > > > LMTX and MkIV behave differently if dots are used in the file > > name. Example: > > > >printf '%s\n' '\starttext\null\stoptext' > foo.10.tex && context > > foo.10.tex > > > >

Re: [NTG-context] \Umathcodenum and get...dir in lmtx

2020-05-28 Thread Hans Hagen
On 5/28/2020 4:03 PM, Marcel Fabian Krüger wrote: Hi, I had two issues with luametatex: The manual documents getters and setters for the directions: The direction states can be queried and set with: tex.gettextdir() tex.getpardir() tex.setmathdir() tex.getlinedir() tex.settextdir()

[NTG-context] 'debug' version of METAPOST draw?

2020-05-28 Thread Gerben Wierda
I would like to be able (during development) to draw paths where the points of the path (and maybe thing slike directions) are visualised. E.g. a path where each pair in teh path is also drawn as a dot and maybe teh directions drawn as small arrows. Does someone have such a beast lying around?

Re: [NTG-context] LMTX: different output if dots are used in the file name

2020-05-28 Thread Hans Hagen
On 5/28/2020 2:49 PM, Marco Patzer wrote: Hi! LMTX and MkIV behave differently if dots are used in the file name. Example: printf '%s\n' '\starttext\null\stoptext' > foo.10.tex && context foo.10.tex MkIV: → foo.10.pdf LMTX: → foo.pdf Is this intentional? consider it to be so Hans

Re: [NTG-context] Checking existence of a macro (control sequence) by Lua

2020-05-28 Thread context
Hello, thanks Henri and Hans for all solutions! On 2020-05-28 10:34, Hans Hagen wrote: On 5/28/2020 12:42 AM, cont...@vivaldi.net wrote: Hello, is it possible to check whether a macro exists (or - is it a non-\undefined control sequence) with Lua? Suppose: \starttext  

[NTG-context] \Umathcodenum and get...dir in lmtx

2020-05-28 Thread Marcel Fabian Krüger
Hi, I had two issues with luametatex: The manual documents getters and setters for the directions: The direction states can be queried and set with: tex.gettextdir() tex.getpardir() tex.setmathdir() tex.getlinedir() tex.settextdir() tex.setpardir() tex.getmathdir() tex.setlinedir()

[NTG-context] LMTX: different output if dots are used in the file name

2020-05-28 Thread Marco Patzer
Hi! LMTX and MkIV behave differently if dots are used in the file name. Example: printf '%s\n' '\starttext\null\stoptext' > foo.10.tex && context foo.10.tex MkIV: → foo.10.pdf LMTX: → foo.pdf Is this intentional? This is LuaMetaTeX, Version 2.06.05 current version: 2020.05.25 23:39 Marco

[NTG-context] LMTX: natural table error namespace 'naturaltablelocal', key ', '

2020-05-28 Thread Marco Patzer
Hi! With LMTX the following example results in setup > error in line 7, namespace 'naturaltablelocal', key ',' setup > error in line 7, namespace 'naturaltablelocal', key ',' The file runs without error in MkIV. Has something changed or is it a bug? \starttext

Re: [NTG-context] Checking existence of a macro (control sequence) by Lua

2020-05-28 Thread Hans Hagen
On 5/28/2020 12:42 AM, cont...@vivaldi.net wrote: Hello, is it possible to check whether a macro exists (or - is it a non-\undefined control sequence) with Lua? Suppose: \starttext   \def\MyMacro{Ahoj}   \def\MyMac#1#2{Something}   \startluacode     IsDefined = function(ctl_seq)   

Re: [NTG-context] Checking existence of a macro (control sequence) by Lua

2020-05-28 Thread Hans Hagen
On 5/28/2020 12:49 AM, luigi scarso wrote: On Thu, May 28, 2020 at 12:43 AM > wrote: Off-topic: your email are always marked as spam by my gmail . Are you sure that your address setup is ok  ? also, a reply to that vivaldi address always bounces (same for gmx

Re: [NTG-context] Checking existence of a macro (control sequence) by Lua

2020-05-28 Thread Henri Menke
On 28/05/20, 00:42, cont...@vivaldi.net wrote: > Hello, > > is it possible to check whether a macro exists (or - is it a non-\undefined > control sequence) with Lua? Suppose: > > > \starttext > \def\MyMacro{Ahoj} > \def\MyMac#1#2{Something} > > \startluacode > IsDefined =