bugFree UCS Outline Fonts - Bugs: bug #50819, Overlapping Gujarati ascenders and...

 
 

bug #50819: Overlapping Gujarati ascenders and script tag typo

Submitted by:  David Corbett <dscorbett>
Submitted on:  Mon 17 Apr 2017 06:45:53 PM UTC  
 
Category: individual character(s)Severity: 3 - Normal
Item Group: letter positioning poorStatus: Fix posted
Privacy: PublicAssigned to: Steve White <Stevan_White>
Open/Closed: OpenRelease: development

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Mon 31 Jul 2017 10:17:49 AM UTC, comment #23:

I went ahead with the fragile, complicated solution, because a fragile, ocmplicated solution in hand is better than a robust elegant solution in the bush -- so far as I know.

Of course your examples are very extreme, and I never for a minute believd these are real words.
In fact, I've only rarely even seen an i-matra with a reph. With a candrabindu, I think it occurs only in Sanskrit, where it is very rare. These things might even be handled on a case-by-case basis. Not clear what would be easier.

I need to make a test with a full set of conjuncts with i-matra + cetera, to see what all goes crazy.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Sun 30 Jul 2017 11:56:37 AM UTC, comment #22:

The way I've been attaching the reph &cet to the i-sign is very complicated and fragile. Looking for somethnig better.

https://www.microsoft.com/typography/OpenTypeDev/gujarati/intro.htm
Example #1 shows the reph &cetera being positioned over the last character of the cluster... but unless the i-matra is guaranteed never to intrude into the reph's space, things will get nasty.

There is a 'pref' table in OpenType. It's used in Bengali to arrange for a 'ra' to preceed a consonant...can't see it's really uused anywhere else. Dould it be used here somehow? Dubious.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Sat 29 Jul 2017 03:16:56 PM UTC, comment #21:

The two new widths of i (guj_i_2_wide and guj_i_3_wide) should have the same variants as the other widths. To be explicit, there should be guj_ir_2_wide, guj_ir_anusvara_2_wide, guj_ir_candrabindu_2_wide, guj_ir_3_wide, guj_ir_anusvara_3_wide, and guj_ir_candrabindu_3_wide.

data:text/html;charset=utf-8,<div style="font: 100px FreeSerif">%E0%AA%B0%E0%AB%8D%E0%AA%9C%E0%AB%8D%E0%AA%B0%E0%AA%BF<br>%E0%AA%B0%E0%AB%8D%E0%AA%9C%E0%AB%8D%E0%AA%B0%E0%AA%BF%E0%AA%82<br>%E0%AA%B0%E0%AB%8D%E0%AA%9C%E0%AB%8D%E0%AA%B0%E0%AA%BF%E0%AA%81<br>%E0%AA%B0%E0%AB%8D%E0%AA%95%E0%AB%8D%E0%AA%9C%E0%AB%8D%E0%AA%B0%E0%AA%BF<br>%E0%AA%B0%E0%AB%8D%E0%AA%95%E0%AB%8D%E0%AA%9C%E0%AB%8D%E0%AA%B0%E0%AA%BF%E0%AA%82<br>%E0%AA%B0%E0%AB%8D%E0%AA%95%E0%AB%8D%E0%AA%9C%E0%AB%8D%E0%AA%B0%E0%AA%BF%E0%AA%81</div>

David Corbett <dscorbett>
Sat 29 Jul 2017 08:22:46 AM UTC, comment #20:

Yes, that is one of the remaining issues, related to the fact that the i sign doesn't always stretch quite where I would like it. But this is a hard problem -- I don't know if there is an ideal solution in OpenType. I'll just describe the issues here.

1) The i sign conventionally arches over consonants and consonant clusters, almost to the right side of the last consonant in the cluster. This alone is very hard to accomplish with any accuracy.

2) In the presence of an i-sign, anusvara, candrabindu and other high marks are supposed to float the same point of the consonant as they would without the i-sign, but somehow make room for it vertically.

What happens here is, the i-sign has stretched a wee bit further than is ideal, and bumped into the mark.

OpenType positioning lookups apply only to a preceding base glyph, but the i sign is transported to the beginning of the cluster by the font shaping step, out of reach of positioning.

As to stretching, the only option in OpenType is to make a range of stretched i-sign auxiliary glyphs, and guess the width of the consonant cluster using contextual chaining. But this is very rough. To make the strech precise, and allow freedom of width of all glyphs involved, would require a huge number of auxiliary glyphs, and huge tables to pick them. Everybody settles for a happy medium.

What I've one with mark placement is to determine that an i-sign is present, in which case the mark glyph is swapped with one placed higher. I'll experiment further with this -- maybe it will be enough.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Sat 29 Jul 2017 12:13:27 AM UTC, comment #19:

The anusvara overlaps the vowel sign in the words ⟨ઠિંગુજી⟩, ⟨ડિંડોરી⟩, and ⟨ધિંગડા⟩. I agree that it is reasonable to not worry about the unattested clusters.

David Corbett <dscorbett>
Fri 28 Jul 2017 10:20:49 PM UTC, comment #18:

Hi David,

At this point, I think the font does something sensible with most of the combinations in your examples. The few that are obviously messed up turn up no search engine hits save the present thread, and other Gujarati fonts also fail to render anyting for them.

Let me know if I've mis-read that.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Fri 28 Jul 2017 04:16:08 PM UTC, comment #17:

⟨ર્ઘઁ⟩ is rendered as if it were ⟨ર્ઘૈઁ⟩.

David Corbett <dscorbett>
Fri 28 Jul 2017 12:08:51 PM UTC, comment #16:

Hi David,

I made some improvements, I think.

Still less than great: the width classes of the i-symbol could be refined and expanded. That will take some work.

I don't have a general solution for i+cons+candrabindu. I don't see that anybody makes a ligature of it. Might make special candrabindu and anusvara just for that combination, even smaller and higher than the others?

Check out the vedic marks!

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Fri 28 Jul 2017 07:23:38 AM UTC, comment #15:

I found something like your example અર્ઘઁ except it's દીર્ઘઁ here:
http://sanskritdocuments.org/doc_veda/sv-kauthuma.html?lang=gu
I stand corrected.

That document contains several other candrabindus.

I think this occurs in transcription of Sanskrit. I have never seen it in Gujarati text.

As to the other fonts: the fact that one of them deals with a limited set of these cases means that somebody thought that it was important enough to spend time on. It's also interesting that other font designers did not.

I remain un-thrilled by the solution in that one font. Sure would be nice to see an image of an old printed book!

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Thu 27 Jul 2017 09:40:14 PM UTC, comment #14:

Hi David,

I finally got around to researching this further.

I don't like to refer to other fonts, but I'm in the dark as to how this stuff should look. I looke at several freely-available fonts. None of the ones I looked at deals with the candrabindu at all.

So I went to Windows, and observed the Shruti font. It doesn't deal with the problem of crashing ascenders in general, but instead, it has a couple of dozen ligatures of various consonant forms with candrabindu. They aren't really ligatures -- the candrabindu is just re-sized (making it tiny) and placed around the letter so they don't collide. I'm not thrilled with its looks.

Of course, what we prefer here is a typographic tradition.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Sat 22 Apr 2017 02:53:52 PM UTC, comment #13:

Could you create a mark class for nukta and configure the lookup to skip that class?

Reph appears in conjunction with candrabindu in the word “અર્ઘઁ” argham̐. I can’t see any phonetic reason why they shouldn’t be together.

David Corbett <dscorbett>
Sat 22 Apr 2017 10:27:36 AM UTC, comment #12:

Hi,

I made a further width class for medium-width characters.

Still thinking about the nukta issue.

As to the original issue, it seems to me that candrabindu makes sense together with a vowel mark. I just don't know how it should interact with them graphically. I strongly doubt it would appear in conjunction with a reph (on phonetic grounds.)

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Fri 21 Apr 2017 03:49:48 PM UTC, comment #11:

Okay, ⟨ર્ઙિ⟩ might not be wrong in isolation, but it is inconsistent with the rest of the font.

⟨ક ખ જ⟩ are normal-width, wider, and wider respectively. Therefore, ⟨કિ ખિ જિ⟩ use i_guj, guj_i_wide, and guj_i_wider. Also therefore, ⟨ર્કિ ર્ખિ ર્જિ⟩ use guj_ir, guj_ir_wide, and guj_ir_wider. This is as it should be.

⟨ઙ⟩ is a normal-width letter, so it, like ⟨ક⟩, should use guj_ir. However, it doesn’t. This is because the substitutions "'pres' i+-reph+-anusvara pre-base chain in Gujarati" and "'pres' i+-reph pre-base chain in Gujarati" omit various consonant glyphs including nga_guj. The effect of this omission is that the connections between the i matra and the reph of ⟨ર્કિ⟩ and ⟨ર્ઙિ⟩ look different.

> The combination was not intended to use guj_ir: I made these auxiliaries for wider base glyphs


I don’t know what you mean. guj_ir is not for wider base glyphs. You’re thinking of guj_ir_wide and guj_ir_wider.

David Corbett <dscorbett>
Fri 21 Apr 2017 12:02:17 PM UTC, comment #10:

Hi,

I guess I just saw what you meant about the nukta: it isn't the placement of the nukta or the substitution of the wider vowel mark, it's the substitution of the vowel+reph. I'll have to think about that.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Fri 21 Apr 2017 11:49:00 AM UTC, comment #9:

David, we must be misunderstanding one another.

In what respect does ર્ઙિ look wrong to you? Could you provide an image?

The combination was not intended to use guj_ir: I made these auxiliaries for wider base glyphs, and to my eye, this isn't a very wide base glyphs. Do you mean, I should have treated ર્ઙ as a wider glyph?

On my system, I see the nutka placed as I expected. See attachment. Should it be somewhere else?

(file #40464)

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Thu 20 Apr 2017 04:18:31 PM UTC, comment #8:

⟨ર્ઙિ⟩ looks wrong: it does not use guj_ir. This is because the substitutions "'pres' i+-reph+-anusvara pre-base chain in Gujarati" and "'pres' i+-reph pre-base chain in Gujarati" omit various consonant glyphs including nga_guj.

The substitutions fail when there is a nukta, e.g. ⟨ર્જ઼િ⟩.

David Corbett <dscorbett>
Wed 19 Apr 2017 11:00:15 PM UTC, comment #7:

Check these out
ર્કિ ર્ચિ ર્છિ ર્ઙિ ર્જિ ર્કિં ર્ચિં ર્છિં ર્ઙિં ર્જિં

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Wed 19 Apr 2017 10:57:48 AM UTC, comment #6:

Technical note: The reph attached to the i mark is tricky. I havn't sorted out how to do it. The mark is moved in front of the consonant early on in the shaping process. If the glyphs are ligated before that point, the rearrangement won't happen. But after, a consonant intervenes between the mark and the reph. Glyph substitution tables are very limited: they can either replace a string of glyphs with a single one, or the other way around.

One idea --
In csse of [i + cons + reph], replace the i glyph with the ir-ligature.
when [ir-lig + cons + reph] is found, replace [cons + reph] with [cons].
Should work.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Wed 19 Apr 2017 07:22:23 AM UTC, comment #5:

I agree with your points about the reph. I'll work on that.

About the raising and lowering... I'm not sure quite what you're referring to. Originally there was no anchor point on those vowels, I'll put one on to handle the anusvara -- just in case the combination really occurs.

I will make an SVN commit presently.

The main puzzle here is, how to handle vowel+canrabindu when the vowel is very high. I saw one example on the MS Typography site, but that was already implemented in FreeSerif. I just don't know where it should be placed, or if perhaps the candrabindu should be transformed somehow.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Tue 18 Apr 2017 06:05:28 PM UTC, comment #4:

Reph + i, e.g. ⟨ર્કિ ર્ઙિ ર્જિ⟩: The two marks should connect such that the reph is a hook on the right end of the matra.

Reph + ii, e.g. ⟨ર્ઙી⟩: The reph should protrude from the top of the vertical stroke of the matra.

Reph + anusvara, e.g. ⟨ર્ઙં⟩: The anusvara should nestle inside the reph. This may require making the reph bigger or the anusvara smaller.

Candra e/o + anusvara, e.g. ⟨ઙૅં ઙૉં⟩: The reph/anusvara should be raised a bit. The matra should perhaps be lowered a bit.

The combinations of candra e/o and candrabindu are probably unattested, as you say; though not because it would be too many candras, but because candrabindu is only used in Sanskrit and candra e/o are never used in Sanskrit.

David Corbett <dscorbett>
Tue 18 Apr 2017 04:23:30 PM UTC, comment #3:

I see what you mean. I'm not sure what should be done about it.

Direction in the Unicode Standard is very thin.

I did web searches for some of them, and got hits, in what appeared to be bits of Gujarati text.

I have seen a reference to a document that seems to say that candrabindu becomes a dot after high vowel letters. Unfortunately the document itself isn't accessible.

Some of the combinations may not occur: particularly the vowels with a candra (U+0A8D, U+0A91) probably can't take a further one.

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Tue 18 Apr 2017 02:47:45 PM UTC, comment #2:

I came up this set of Gujarati clusters with ascenders: ⟨ઉઁ ઉં ઊઁ ઊં ઍઁ ઍં એઁ એં ઐઁ ઐં ઑઁ ઑં ઓઁ ઓં ઔઁ ઔં કિઁ કિં ઙિઁ ઙિં ઙીઁ ઙીં ઙૅઁ ઙૅં ઙેઁ ઙેં ઙૈઁ ઙૈં ઙૉઁ ઙૉં ઙોઁ ઙોં ઙૌઁ ઙૌં જિઁ જિં ર્કિ ર્કિઁ ર્કિં ર્ઙઁ ર્ઙં ર્ઙિ ર્ઙિઁ ર્ઙિં ર્ઙી ર્ઙીઁ ર્ઙીં ર્ઙૅ ર્ઙૅઁ ર્ઙૅં ર્ઙે ર્ઙેઁ ર્ઙેં ર્ઙૈ ર્ઙૈઁ ર્ઙૈં ર્ઙૉ ર્ઙૉઁ ર્ઙૉં ર્ઙો ર્ઙોઁ ર્ઙોં ર્ઙૌ ર્ઙૌઁ ર્ઙૌં ર્જિ ર્જિઁ ર્જિં⟩.

Of those, the following seem wrong to me in FreeSerif: ⟨ઉઁ ઍઁ એઁ એં ઐઁ ઐં ઑઁ ઓઁ ઓં ઔઁ ઔં કિઁ કિં ઙિઁ ઙિં ઙીઁ ઙીં ઙૅઁ ઙૅં ઙેઁ ઙૈઁ ઙૉઁ ઙોઁ ઙૌઁ ર્કિ ર્કિઁ ર્કિં ર્ઙઁ ર્ઙં ર્ઙિ ર્ઙિઁ ર્ઙિં ર્ઙી ર્ઙીઁ ર્ઙીં ર્ઙૅ ર્ઙૅઁ ર્ઙૅં ર્ઙેઁ ર્ઙૈઁ ર્ઙૉ ર્ઙૉઁ ર્ઙૉં ર્ઙોઁ ર્ઙૌઁ ર્ઙૌં ર્જિ ર્જિઁ ર્જિં⟩.

David Corbett <dscorbett>
Mon 17 Apr 2017 08:32:41 PM UTC, comment #1:

Hi David,

I did indeed find an incorrect language tag. This is already fixed in SVN.

Could you provide examples of combinations that seem wrong to you>

Steve White <Stevan_White>
Project AdministratorIn charge of this item.
Mon 17 Apr 2017 06:45:53 PM UTC, original submission:

Various Gujarati glyphs ascend above the hanging baseline. In FreeSerif, they overlap each other. The affected glyphs include:

  • candrabindu_guj: U+0A81 GUJARATI SIGN CANDRABINDU
  • anusvara_guj: U+0A82 GUJARATI SIGN ANUSVARA
  • U_guj: U+0A89 GUJARATI LETTER U
  • UU_guj: U+0A8A GUJARATI LETTER UU
  • Ecandra_guj: U+0A8D GUJARATI VOWEL CANDRA E
  • E_guj: U+0A8F GUJARATI LETTER E
  • AI_guj: U+0A90 GUJARATI LETTER AI
  • Ocandra_guj: U+0A91 GUJARATI VOWEL CANDRA O
  • O_guj: U+0A93 GUJARATI LETTER O
  • AU_guj: U+0A94 GUJARATI LETTER AU
  • i_guj: U+0ABF GUJARATI VOWEL SIGN I
  • ii_guj: U+0AC0 GUJARATI VOWEL SIGN II
  • ecandra_guj: U+0AC5 GUJARATI VOWEL SIGN CANDRA E
  • e_guj: U+0AC7 GUJARATI VOWEL SIGN E
  • ai_guj: U+0AC8 GUJARATI VOWEL SIGN AI
  • ocandra_guj: U+0AC9 GUJARATI VOWEL SIGN CANDRA O
  • o_guj: U+0ACB GUJARATI VOWEL SIGN O
  • au_guj: U+0ACC GUJARATI VOWEL SIGN AU
  • guj_ra.reph: U+0AB0 GUJARATI LETTER RA + U+0ACD GUJARATI SIGN VIRAMA
  • guj_i_wide: U+0ABF GUJARATI VOWEL SIGN I
  • guj_i_wider: U+0ABF GUJARATI VOWEL SIGN I

Valid combinations are (vowel-sign? reph? | vowel-letter)? (candrabindu | anusvara)?.

FreeSerif contains some glyphs for combinations like guj_o_reph.abvs that would help fix this bug, but they are not used because the Gujarati subtables use the script tag 'gur2', which is a typo for 'guj2'.

David Corbett <dscorbett>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #40464:  ir-nukta.png added by Stevan_White (2KiB - image/png)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by Stevan_White (Posted a comment)
  • -unavailable- added by dscorbett (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 4 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 28 Jul 2017 10:20:49 PM UTCStevan_WhiteStatusNeed info=>Fix posted
    Fri 21 Apr 2017 11:49:00 AM UTCStevan_WhiteAttached File-=>Added ir-nukta.png, #40464
    Mon 17 Apr 2017 08:32:41 PM UTCStevan_WhiteStatusNone=>Need info
      Assigned toNone=>Stevan_White

    Back to the top


    Powered by Savane 3.1-cleanup1