cyrealtype / Lora-Cyrillic

Lora fonts — serif family for text. Variable Open Source Font
http://www.cyreal.org/fonts/lora/
SIL Open Font License 1.1
413 stars 34 forks source link

Spacing around backtick / unwanted accents #55

Closed benrbray closed 2 years ago

benrbray commented 2 years ago

Thank you for this beautiful font! I'm using it as one of the font options for a math-focused WYSIWYG markdown editor. Accordingly it is common to include backticks ``` as part of markdown syntax. However, I've been experiencing mysterious accent characters appearing while using the Lora font, which don't appear when using any other fonts:

image

image

As you can see, the raw text is just mysterious `accent`, with no accented characters. Can you think of a reason why Lora would cause this issue? Is there any way to fix it? I've already tried font-variant-ligatures: none.

Notably, I cannot reproduce the issue on Google fonts:

image

alexeiva commented 2 years ago

Grave accent combined with Latin a produces aacute thanks to glyphs composition

U+0060 GRAVE ACCENT

you need to disable ccmp feature, not ligatures https://helpx.adobe.com/fonts/using/open-type-syntax.html#ccmp

benrbray commented 2 years ago

Thanks for the reply. Do you know the correct way to disable ccmp? I've tried both of the below with no luck. Any alternatives to this?

font-feature-settings: "ccmp" off;
font-feature-settings: "ccmp" 0;
thlinard commented 2 years ago

@benrbray Seems your editor replaces U+0060 GRAVE ACCENT by U+0300 COMBINING GRAVE ACCENT.

alexeiva commented 2 years ago

Actually grave has an unnecessary top anchor that fixates to base glyphs. That was my oversight in from an older version. So removing this anchor should solve the issue.

Screenshot 2022-04-22 at 14 22 34

alexeiva commented 2 years ago

@benrbray Let me know if this version works for you. Lora-v3.003.zip

benrbray commented 2 years ago

It works!! Thank you very much!