notofonts / hebrew

Noto Hebrew
SIL Open Font License 1.1
2 stars 1 forks source link

Nikud misplaced horizontally under double-yud and double-vov digraphs #38

Closed markhdavid closed 7 months ago

markhdavid commented 8 months ago

Defect Report

These fonts (all 3 families: Sans, Serif, Rashi) render digraphs double-vov (Unicode Character “װ” (U+05F0) ; Name: Hebrew Ligature Yiddish Double Vav) and double-yud (Unicode Character “ײ” (U+05F2) ; Name: Hebrew Ligature Yiddish Double Yod), primarily used for Yiddish, such that nikud that's supposed to be centered under a character get put under the second (i.e., leftmost) subletter of the digraph. So a nikud, such as pasekh, tsere, segol, et al, is centered under the 2nd yud of double-yud and under 2nd vov of double-vov. That's wrong. Nikud is supposed to be centered with respect to both subletters of the digraph. That's how these work. That's the whole point of why you need these digraphs. If you wanted the nikud centered under the second character of the digraph, you wouldn't need a digraph: you'd put out two separate yud or vov characters with the nikud following the second character and unambiguously intended to be centered under that second character. More precisely, the bottom anchor x position for the digraph should be halfway between where the bottom anchor x would be on each of the subletters.

Title

Nikud misplaced horizontally under double-yud and double-vov digraphs - should be horizontally centered under both subletters, not under leftmost

Font

NotoSansHebrew-Regular.ttf Noto_Sans_Hebrew.zip NotoSerifHebrew-Regular.ttf Noto_Serif_Hebrew.zip NotoRashiHebrew-Regular.ttf Noto_Rashi_Hebrew.zip

Where the font came from, and when

https://fonts.google.com/noto/specimen/Noto+Sans+Hebrew https://fonts.google.com/noto/specimen/Noto+Serif+Hebrew https://fonts.google.com/noto/specimen/Noto+Rashi+Hebrew For each font, click Download family, unzip resulting download, find font file in static subdirectory. Date: 2024-02-06

Font Version

Sans: Version 2.003 Serif: Version 2.003 Rashi: Version 1.006

Issue

These fonts (all 3 families: Sans, Serif, Rashi) render digraphs double-vov (Unicode Character “װ” (U+05F0) ; Name: Hebrew Ligature Yiddish Double Vav) and double-yud (Unicode Character “ײ” (U+05F2) ; Name: Hebrew Ligature Yiddish Double Yod), primarily used for Yiddish, such that nikud that's supposed to be centered under a character get put under the second (i.e., leftmost) subletter of the digraph. So a nikud, such as pasekh, tsere, segol, et al, is centered under the 2nd yud of double-yud and under 2nd vov of double-vov. That's wrong. Nikud is supposed to be centered with respect to both subletters of the digraph. That's how these work. That's the whole point of why you need these digraphs. If you wanted the nikud centered under the second character of the digraph, you wouldn't need a digraph: you'd put out two separate yud or vov characters with the nikud following the second character and unambiguously intended to be centered under that second character. More precisely, the bottom anchor x position for the digraph should be halfway between where the bottom anchor x would be on each of the subletters. Note that this bug report applies to every Noto Hebrew font (Sans, Serif, Rashi). I have also tried it with their equivalents under Noto Hebrew HEAD build, here: https://notofonts.github.io/hebrew/, and reproduced the same results.

  1. To reproduce, use the following sample text at any of the three Google Fonts preview pages (for Sans, Serif, or Rashi): װֶעלְכֶע װֶעלְן זײַן רײַך בײֵנער
  2. For example, go to https://fonts.google.com/noto/specimen/Noto+Sans+Hebrew, scroll down to the input box that says, "Type here to preview text", paste in the above sample text.
  3. Observe that each nikud (= diacritic or vowel point), e.g., segol (U+05B6), under each digraph, e.g., double-vov (U+05F0), is horizontally positioned underneath the 2nd (leftmost) subletter.
  4. Expected results: each nikud should be horizontally positioned centered between the position it would be at for each of the two subletters. In other words, the bottom anchor x position for the digraph should be halfway between where the bottom anchor x would be on each of the subletters.

Character data

Here are the characters in example combination double-vov + segol (װֶ): U+05F0 [װ] HEBREW_LIGATURE_YIDDISH_DOUBLE_VAV U+05B6 [ֶ] HEBREW_POINT_SEGOL

Here are the characters in example combination double-yud + patah (ײַ): U+05F2 [ײ] HEBREW_LIGATURE_YIDDISH_DOUBLE_YOD U+05B7 [ַ] HEBREW_POINT_PATAH

Here is a text file, digraphs-sample-text.txt, containing all the above cited test text, usable in the Tools section below: digraphs-sample-text.txt

Screenshot

Results with Noto Sans Hebrew at its Google Docs page with test text: װֶעלְכֶע װֶעלְן זײַן רײַך בײֵנער

Google Fonts Noto Sans Hebrew - bad double-yud and double-vov digraphs - Screenshot 2024-02-06 at 3 21 59 PM

Results with test shown in the Tools section below.

rashi-sample

Tools for reporting bugs

For example, starting in the static subdirectory of the Rashi download directory, place the file provided above under Character data into this directory, then run the following command:

hb-view --font-file NotoRashiHebrew-Regular.ttf --text-file digraphs-sample-text.txt --output-file "rashi-sample.png"

See results above under Screenshot

markhdavid commented 8 months ago

This issue is very similar to issue https://github.com/fontef/frankruhllibre/issues/16 for Frank Ruhl Libre, filed by me, @markhdavid, yours truly. That issue led to the related issue https://github.com/google/fonts/issues/6062 in Google Fonts, which yielded insightful commentary by @simoncozens and related fruitful discussion on the Glyphs App discussion board, here: https://forum.glyphsapp.com/t/yiddish-ligatures-should-not-be-considered-ligatures/25468

Similarly, this is very similar to issue https://github.com/meirsadan/david-libre/issues/17 for David Libre, also by me.

markhdavid commented 8 months ago

I would like to be assigned this bug. I have submitted my Google Individual Contributor License Agreement (CLA). I have a current Glyphs App license, and I've already done a fix that works in my private fork of this repo, as well as having done a fix like this before with Frank Ruhl Libre, David Libre, and Heebo.

I would be need some orientation - it's hard to tell what branch and with which source files the main line of development is taking place currently. Along these lines, I do not understand how the font family of NotoSansHebrewDroid-Regular.ttf, et al, relates to the Noto Hebrew project, but that font does not appear to have this issue. Does that font represent initial attempts to solve this issue? I did not mention this "Droid" variant because it is not released for Google Fonts, as far as I can tell, so I did not think it deserved mention my main issue description.

simoncozens commented 8 months ago

You've very welcome to work on this - I think we just need anchors on the double-yod and double-waw glyphs. The main branch is where PRs get merged, so I would start a new branch and make a PR to main.

Noto Sans Hebrew Droid is a special Android version of Noto Sans Hebrew which maintains an older design; it can be largely ignored.

markhdavid commented 8 months ago

Thanks @simoncozens.

Also wonder what NotoSansHebrewNew.glyphs is? For now I'll assume I should ignore it along with NotoSansHebrewDroid.glyphs.

I have to create another issue that affects these characters, which I want to handle first. I should have that up in next day or so.

markhdavid commented 7 months ago

Note that the fix for newer issue https://github.com/notofonts/hebrew/issues/39 should go in before this issue https://github.com/notofonts/hebrew/issues/38, since it directly impacts it.