[luatex] Proposal for extensible arrows

Hans Hagen pragma at wxs.nl
Sat Feb 13 14:17:05 CET 2016


On 2/13/2016 1:51 PM, Will Robertson wrote:
> Hi all,
>
> Some recent discussions about unicode mathematics and so on brought up the following issue. I thought it might be good to raise here in case it sparks anything. If not, no harm done :)
>
> In the current unicode/OpenType maths support in XeTeX and LuaTeX, with proper setup of \Udelcode and so on it’s possible to produce vertical extensible arrows for use with \left and \right; using \Umathaccent extensible horizontal arrow accents can be produced:
>
> \documentclass{article}
> \usepackage{unicode-math}
> \setmainfont{xits-math.otf}
> \begin{document}
> x$\overleftarrow{\hspace*{3cm}}$x
>
> x$\displaystyle
> \left\Uparrow\vrule height 3cm width 0pt\right.
> $x
> \end{document}
>
> But this does not cover the entire range of how extensible arrows are used, with LaTeX/amsmamth defining \leftarrowfill and \xleftarrow, for example. These are defined with the typical TeX macro approach of gluing small pieces of the arrow together with \cleaders, etc. In several ways, it would be preferable to avoid this approach and have the engine construct the extensible arrow directly.
>
> As such, I think there is scope for a new primitive or two to the extended mathematics support:
>
>      \Uhextensor <char> <length/glue>
>      \Uvextensor <char> <length/glue>
>
> (or whatever csnames).

we already have Uhextensible (and a whole bunch of extras) ... it all 
depends on what the font provides; the gyre fonts do have extensible 
arrows already

(It is unlikely that the math engine will be touched much, at least nto 
before 0.95. Quite some code was overhauled - a better split between old 
and new font as well as some detailed control over extensibles, 
delimiters etc. - some was added for completeness even if it could be 
done otherwise. An upcoming TB article will explain/show some.)

Hans


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
       tel: 038 477 53 69 | www.pragma-ade.com | www.pragma-pod.nl
-----------------------------------------------------------------


More information about the luatex mailing list