XeTeX was written to extend e-TeX to allow full Unicode working, including loading system fonts. The development started from the DVI-mode e-TeX, rather than from pdfTeX, which had added various new primitives to e-TeX. Much of the difference between pdfTeX and e-TeX is directly to do with producing PDF output, but there are some additions that are entirely independent of that.
Over the years, some of the ‘utilities’ have been added to XeTeX (for example
\pdfstrcmp, which in XeTeX is just
\strcmp). However, several have not made
it, but have been added to pTeX and upTeX. That’s meant that XeTeX has between
‘a bit behind’ in feature terms: there are things that simply can’t be done
without primitive support.
An opportunity arises
As I’ve said in my other post today,
the recent setting up of a Travis-CI testing
environment for TeX Live building means that it
is now easy to try adding new material to the
WEB sources of pdfTeX, XeTeX,
etc. As I was working on
\expanded anyway, I decided that I’d look at
bringing XeTeX back ‘into line’ with pTeX and upTeX. That’s important as
LaTeX team have been using almost all
of the primitives that were ‘missing’ in XeTeX.
The new features
So what has been added? The new additions are all named without the
These enable things like random numbers in the LaTeX3 FPU, measuring
and checking the details of files: all stuff that is in
expl3 and will now
work with XeTeX.
I should add that although I did the grind of working out how to integrate the pdfTeX code into XeTeX, Akira Kakuto sorted out the areas that needed knowledge of C, in particular where XeTeX’s Unicode internals don’t match up with pdfTeX’s 8-bit ones.
One more thing
As well as the above, I made one other minor adjustment to XeTeX: altering
\Ucharcat works so it can create category code 13 (‘active’) tokens.
That probably won’t show up for users except it helps the team extend some
expl3 code. Hopefully it will mean there is on fewer XeTeX
Getting the code
TeX Live only gets binary updates once per year, so users there will need to wait for the 2019 release. On the other hand, MiKTeX already has the new features, so if you are on Windows it’s pretty trivial to try out. If you use TeX Live and really want to test out, you can update your binaries in-place, for example from W32TeX: if you understand what that means, you probably know how to do it!