Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- documentclass{article}
- usepackage{fontspec}
- setmainfont{FreeSerif.otf}
- % turn on xetex character class feature
- XeTeXinterchartokenstate=1
- % character class for beta
- newXeTeXintercharclassmyc
- % assign beta to the class
- XeTeXcharclass`β=myc
- % specify that swapbeta should be inserted between any
- % normal character (class zero) and a beta (class mych)
- XeTeXinterchartoks 0 myc{swapbeta}
- % define swapbeta to swallow a β and expand to ϐ
- defswapbeta β{ϐ}
- % To do the same for phi just define a new class and a new swapphi
- % command and set up a substitution for that.
- % testing...
- begin{document}
- abc βέβα
- end{document}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement