line numbers in margin from xml in context mkiv
![](https://secure.gravatar.com/avatar/64e91ceb4b55a0f392a1b385d16f42af.jpg?s=120&d=mm&r=g)
All, After being away from my project for a while I returned to find that something that worked now no longer does. I updated the minimals on my Mac and context is running as I would expect: jjc% context --version mtx-context | main context file: /Users/jjc/context/tex/texmf-context/tex/context/base/context.mkiv mtx-context | current version: 2011.04.24 15:15 But now, while running my environment.tex file against my target TEI/xml file context complains: ! Undefined control sequence. l.77 \defineinmargin [lineNumbers] [normal] ? My own fragile understanding of what I'm doing may well be at fault, but perhaps something relevant has changed with the minimals? I had an environment file that I'd arrived at by much trial and error that renders page/line numbers encoded in the xml/TEI source in the margins of my pdf output: \startxmlsetups xml:pb \def\svopage{\xmlatt{#1}{n}.} \xmlflush{#1} \stopxmlsetups \startluacode function filter(lb) if math.mod(lb,5) == 0 then context.svopage() context(lb) end end \stopluacode \define[1]\MyNumber% {\ctxlua{filter(#1)}\endgraf} \startxmlsetups xml:lb \xmldoifelse{#1}{ancestor::head[@type='diarytitle']} {\\} {\lineNumbers{\tfxx\MyNumber{\xmlatt{#1}{n}}}} \xmlflush{#1} \stopxmlsetups \defineinmargin [lineNumbers] [normal] Any suggestions would be gratefully received. Jon
![](https://secure.gravatar.com/avatar/49e63acb01f2ca80efce7eed08310ce8.jpg?s=120&d=mm&r=g)
On 27-4-2011 1:26, Jon Crump wrote:
All,
After being away from my project for a while I returned to find that something that worked now no longer does. I updated the minimals on my Mac and context is running as I would expect:
jjc% context --version mtx-context | main context file: /Users/jjc/context/tex/texmf-context/tex/context/base/context.mkiv mtx-context | current version: 2011.04.24 15:15
But now, while running my environment.tex file against my target TEI/xml file context complains:
! Undefined control sequence. l.77 \defineinmargin [lineNumbers] [normal] ?
see typo-mar.mkiv ... more control over margindata and new commands 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 -----------------------------------------------------------------
participants (2)
-
Hans Hagen
-
Jon Crump