Last active
August 5, 2022 10:20
-
-
Save ezgranet/19d6f117f11e2d27c4572a2e3160389e to your computer and use it in GitHub Desktop.
etbb parentheses spacing fix
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| %%%%%%%% | |
| %%%%% Michael sharpe's brilliant typeface `etbb' is a | |
| %%% wonderful adaptation of Edward Tufte's own adaptation of Bembo | |
| %%%%%% However, there is, as part of the font, an overlap between | |
| %%% the opening parenthesis --- ( --- and various letters, most notably J | |
| %% This is aesthetically displeasing, so I used this small snippet | |
| %%%% of XeTeX `interchartoks' to fix the spacing | |
| %%%% Now, (J doesn't overlap! | |
| \XeTeXinterchartokenstate = 1 | |
| \newXeTeXintercharclass \mycharclassj | |
| \XeTeXcharclass `\J \mycharclassj | |
| \newXeTeXintercharclass \mycharclasslittlej | |
| \XeTeXcharclass `\j \mycharclasslittlej | |
| \newXeTeXintercharclass \mycharclasst | |
| \newXeTeXintercharclass \mycharclassu | |
| \newXeTeXintercharclass \mycharclassv | |
| \XeTeXcharclass `\T \mycharclasst | |
| \XeTeXcharclass `\U \mycharclassu | |
| \XeTeXcharclass `\V \mycharclassv | |
| \newXeTeXintercharclass \mycharclassp | |
| \XeTeXcharclass `( \mycharclassp | |
| \XeTeXinterchartoks\mycharclassp\mycharclassj={\kern1.5pt } | |
| \XeTeXinterchartoks\mycharclassp\mycharclasslittlej={\kern1.5pt } | |
| \XeTeXinterchartoks\mycharclassp\mycharclasst={\kern0.7pt } | |
| \XeTeXinterchartoks\mycharclassp\mycharclassu={\kern0.7pt } | |
| \XeTeXinterchartoks\mycharclassp\mycharclassv={\kern0.7pt } | |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Most definitely; I think this is why the endpoint is to modify the kerning itself, so as to maintain maximum compatibility (I mainly use LuaTeX but I have so many older documents using specific XeTeX hacks that cross compatibility is important to me too)