psb1558 / Junicode-font

A new version of Junicode font
SIL Open Font License 1.1
376 stars 18 forks source link

tall e (cv10=5) doesn’t work in Irish with ss02 (LibreOffice, Firefox, LaTeX) #245

Closed silmeth closed 8 months ago

silmeth commented 8 months ago

The letter variant for Irish tall e (cv10=5) doesn’t work when Insular stylistic set ss02 is on. This makes it difficult (impossible?) to achieve the right kerning of sequences like eḋ. I tried turning ss02 for e character to make it tall (2. in the screenshot), setting the character variants by hand (cv08=2 for Insular d, cv10=5 for tall e) but that doesn’t work with ⟨ḋ⟩ u+1e0b (3.), it works with grapheme joiner (u+034f) but the placement of the dot is wrong (4.). meḋraċ ~ meadhrach

You showed before this kerning in a comment on a previous issue:

Is it possible to get that with the current version?

silmeth commented 8 months ago

And the same using XeLaTeX.

Source code:

test.tex ```latex \documentclass[10pt, a5paper]{article} \usepackage[top=0.5in,right=0.5in,left=0.5in,bottom=0.7in]{geometry} \usepackage{fontspec} \usepackage[irish]{babel} \setmainfont{Junicode}[ ItalicFont={*-Italic}, Language=Irish, ] \begin{document} \begin{enumerate} \item { \Huge \addfontfeature{StylisticSet=2} \addfontfeature{CharacterVariant=10:4} meḋraċ } (Junicode:ss02\&cv10=5) \item { \Huge \addfontfeature{StylisticSet=2} m{\addfontfeature{CharacterVariant=10:4}e}ḋraċ } (Junicode:ss02; Junicode:cv10=5 on e) \item { \Huge \addfontfeature{CharacterVariant=8:1} \addfontfeature{CharacterVariant=10:4} meḋraċ } (Junicode:cv08=2\&cv10=5) \item { \Huge \addfontfeature{CharacterVariant=8:1} \addfontfeature{CharacterVariant=10:4} med͏̇raċ } (Junicode:cv08=2\&cv10=5 + d + grapheme joiner + dot above) \end{enumerate} \end{document} ```

the result: obraz

silmeth commented 8 months ago

Found a work-around for LibreOffice – applying ss02 only to a part of the word via Junicode:ss02[2:]&cv10=5 (this requires the precise location of the character in a paragraph and thus makes editing really difficult). obraz

Not sure how do that elsewhere (but I guess there is a way?).

psb1558 commented 8 months ago

Yeah, something is wrong. This is going to take some thought.

Stay tuned.

psb1558 commented 8 months ago

Found a work-around for LibreOffice

I'm working on something easier to use.

psb1558 commented 8 months ago

In the next version, this will work:

In LuaLaTeX or XeLaTeX, this source

\documentclass[10pt, a5paper]{article}
\usepackage[top=0.5in,right=0.5in,left=0.5in,bottom=0.7in]{geometry}
\usepackage{fontspec}

\usepackage[english,irish]{babel}

\setmainfont{Junicode}[
    ItalicFont={*-Italic},
    Language=Irish,
 ]

\begin{document}

\noindent This works:\\
{ \Huge \addfontfeature{StylisticSet=2}m{\addfontfeature{CharacterVariant=10:4}eḋ}raċ }\\[1ex]
note also:\\
{ \Huge \addfontfeature{StylisticSet=2}m{\addfontfeature{CharacterVariant=10:4}ed}raċ }\\
{ \Huge \addfontfeature{StylisticSet=2}m{\addfontfeature{CharacterVariant=10:4}e\char"034F\char"0301d}raċ }\\
{ \Huge \addfontfeature{StylisticSet=2}m{\addfontfeature{CharacterVariant=10:4}e\char"034F\char"0301ḋ}raċ }

\begin{enumerate}
    \item  { \Huge \addfontfeature{StylisticSet=2} \addfontfeature{CharacterVariant=10:4} meḋraċ } (Junicode:ss02\&cv10=5---this is best)
    \item  { \Huge \addfontfeature{StylisticSet=2} m{\addfontfeature{CharacterVariant=10:4}e}ḋraċ } (Junicode:ss02; Junicode:cv10=5 on e---fails because of formatting boundary between e and ḋ)
    \item  { \Huge \addfontfeature{CharacterVariant=8:1} \addfontfeature{CharacterVariant=10:4} meḋraċ } (Junicode:cv08=2\&cv10=5---okay but cv08=2 is superfluous if ss02 is on)
    \item  { \Huge \addfontfeature{CharacterVariant=8:1} \addfontfeature{CharacterVariant=10:4} med͏̇raċ } (Junicode:cv08=2\&cv10=5 + d + grapheme joiner + dot above---fails because of CGJ:
    d + dot should be allowed to resolve to U+1E0B)
\end{enumerate}

\end{document}

will produce this PDF: e-test.pdf

It may be a week or so before the next release.

silmeth commented 8 months ago

Closing – as seems to be done and working as expected in 2.200. obraz