[NTG-context] Quirk with \userpagenumber, datasets and the .tuc file

Bruce Horrocks ntg at scorecrow.com
Wed Dec 9 13:08:40 CET 2020


Here's an odd quirk...

I wanted to get at some of my dataset data for use outside of ConTeXt so I thought I would just extract it from the .tuc file. MWE:

  \definedataset [MyDS][delay=yes]
  \starttext
  \input tufte
  \setdataset [MyDS]
    [ title={Test title},
      page={\userpagenumber},
    ]
  \stoptext

In the TUC file I get:

  utilitydata.job.datasets.collected={
   ["MyDS"]={
    {
     ["index"]=1,
     ["order"]=1,
     ["page"]="1\\relax ",
     ["realpage"]=1,
     ["title"]="Test title",
    },
   },
  }

Note the \\relax following the page number. This isn't a problem for me at the moment but I wondered if it is something that needs to be looked at?

--
Bruce Horrocks
Hampshire, UK



More information about the ntg-context mailing list