5

I want to use a feature file to change the positioning of a single letter, but it does not seem to work. Here is an example:

\documentclass{article}

\usepackage{fontspec}

\RequirePackage{filecontents}
\begin{filecontents*}{kern.fea}
    languagesystem DFLT dflt;
    languagesystem latn dflt;
    feature kern {
        #pos a <0 100 0 0>; # this does not work and breaks the rest of the file 
        pos e <0 100 0 0> x; 
        pos i s -300;
    } kern;
\end{filecontents*}

\setmainfont[FeatureFile=kern.fea]{texgyrepagella-regular.otf}

\begin{document}
    This is an example text.
\end{document}

If I understand font features correctly, the line pos a <0 100 0 0>; should raise the letter a by 100 units. What happens if that line is uncommented in the above example depends on the version of lualatex:

  • With TeX Live 2013, the statement works but the other two statements stop working.
  • With TeX Live 2015, all three statements have no visible effect.

Do I do something wrong or is this a bug?

tim
  • 501
  • 4
    I didn't test your example, but you should avoid feature files as the support has been dropped in luaotfload 2.7: https://github.com/lualatex/luaotfload/issues/347 – Ulrike Fischer May 09 '16 at 18:55
  • Thank you for the advice. The alternative mentioned in that issue seems not work with Tex Live 2015. I also have read http://tex.stackexchange.com/a/10473/102921, which can be a replacement for pos i s -300;, but I couldn't find a way to change the position of a single glyph. – tim May 09 '16 at 22:22
  • 1
    Install texlive 2016. You can do it in parallel. https://www.tug.org/texlive/pretest.html. It doesn't make sense to try to find out how to get it working with older luatex/luaotfload versions. If there are bugs they won't be corrected and every code will be outdated in some month. – Ulrike Fischer May 10 '16 at 08:33
  • With texlive 2016 (and somehow with some installations of texlive 2015) the feature types substitution, ligature, and kern work, but there seems not to be a position type to change the position of a single glyph independent of other glyphs. – tim May 10 '16 at 15:13

0 Answers0