Wednesday, May 28, 2014

Interesting dilemma of Devanagari script fonts

I am sure after reading this post all font developers of well know Devanagari script fonts will start looking at there fonts again and start thinking there font is for which language?

Either they have developed font for Devanagari script or is it font for some specific language or it is simply a mess ?

As most of you know Devanagari script is widely used for number of languages. Major languages in this list are Hindi, Marathi, Nepali, Konkani, Sanskrit, Maithili, Kashmiri and Sindhi and some more languages.

Each language has some specific requirements from Devanagari script as follows.

    Characters requirement from Devanagari script block:
        Kashmiri, Marathi, Sindhi and Sanskrit has specific characters defined in Unicode Devanagari code page[1]. This is bit easy to identify, since Unicode has mentioned  it clearly for codepoints.

    Ligatures/Conjuncts requirement from Devanagari script:
        This one is bit tricky and one must go through each language standard documents from Governments or standardization organizations. I would like to mention some important differences here.

        1. Locale specific shapes for Unicode characters

Different shapes of same characters required in particular language.  Few examples of these are in Marathi "ल" (U+0932) and "श" (U+0936) are different than Unicode code block characters, same way Nepali language also has few different shapes for numerals. (Refer Lohit fonts for more information [2])

       2. Different behaviour of conjuncts across language. 

      This one is really painful, since there are not 3-4 but lots of conjuncts characters are different in widely used languages like Hindi and Marathi. Hindi language mostly prefers horizontal ligature (i.e. simply half form of characters) while language like Marathi, Sanskrit requires ligature form of conjunct which is used to be stacked.

After considering above points:
when you see, download or use any Devanagari font, you will definitely start thinking this font is for which language exactly?
Font for Hindi language with horizontal ligatures?
Font for Marathi language with Stacked ligature?
Pan Devanagari fonts supporting all language?
Even though its pan devanagari fonts, what it renders in en_US/en_IN locale?

       Lohit2 is one of the best example of how to handle this effectively. Still it needs some fixes for default behaviour of Lohit Devanagari font. Since Devanagari is widely used for Hindi language, i am in fever of making default behaviour of Lohit Devanagari to match with Hindi language and for other languages one should either download Lohit fonts for specific language (lohit-marathi, lohit-nepali)  or select appropriate locale while using Lohit Devanagari.

      Still question arises if default behaviour matches Hindi then, why it is called Devanagari, but i think answer is since it supporting other languages as well it is called Lohit Devanagari.


Monday, March 10, 2014

Lohit2: Next one is Lohit Assamese and Bengali fonts improvement

  In last six month we have completed Devanagari (Marathi and Nepali), Gujarati, Gurmukhi and Malayalam under lohit2 project [1]. We have done significant improvement in these fonts not only from technical perspective but also from standards perspective. I am confident enough to say Lohit follows all standards around fonts and Indian languages and scripts guidelines.

  I attended [2] conference in last weekend and talked with people around on lohit2. Happy to see number of people in fonts domain  are aware regarding Lohit fonts. Few people even used Lohit fonts during the workshop to demonstrate some points. Few people proposed enhancement for adding more ligature, so we all are going good :)

  This is time to do improvements in Lohit Assamese and Bengali. Followings are improvements we are looking for..

  • Removing not required ligatures.
  • Rewriting efficient open type tables.
  • Support to the "beng" and "bng2" open type script tags.
  • Building fonts through feature file (.fea)
  • Following AGL specification syntax.
  • Testing on Harfbuzz NG, Uniscribe(W8). 
  • Automated Testing Tool utilization

    One of the important task prior to development is to identify guidelines, specifications for Assamese and Bengali script. We do have TDIL documents available and will see if there is any other. With these improvements i am sure Lohit Assamese and Bengali can become standard reference font for upcoming Bengali fonts project.

    Need help from Assamese and Bengali language expert. I know few already and will ping them for more input during the developments. Development activity is going to happen in lohit2 [3] git.


Tuesday, February 11, 2014

Review of Kannada fonts released by Karnataka Government

I just did a quick review of fonts released by Karnataka Government [a]. This is not from rendering perspective but from technical aspects of the fonts.

All fonts has following issues:

1. Font is specified as a Serif in PFM family.    Fonts is sans-serif still style is incorrectly given in true type fonts.

2. Version should not contain wording like "Initial Beta release".
    Presently given versions are like:- "1.000 2013 initial Beta release"
    Please refer [b] for version guidelines.

3. Font Embedding Permissions should be more relax.
    Presently it is only Editable embedding. It should Installable fonts so even receiver of document can use it.
    Refer font embedding permissions [c]

4. Incorrect License url of TTF names not working

5. Some glyphs does not follows AGL guidelines
    Font has some glyph names starts with "_".
    Example: _uni0C96_uni0CCD  there is also glyph name uni0C96_uni0CCD. When two glyphs has same component one should be with name .alternate or .alt
    In above case it should be
    uni0C96_uni0CCD and uni0C96_uni0CCD.alt
    Please refer: [d]
    "If multiple glyphs in a font represent the same character in the Unicode standard, such as "A" and "A.swash," they can be differentiated by using the same base name with different suffixes. The suffix (the part of glyph name that follows the first period) does not participate in the computation of a character sequence. It can be used by font designers to indicate special characteristics of the glyph. The suffix may contain periods or any other permitted characters. For example, small cap "A" could thus be named "" or """

6. This is not a bug but font contains 1478 glyphs. 
I am sure one can make same quality font with less number of glyphs by using Open type GSUB and GPOS tables.

7. Normal and Bold version of font should have same family name.

Following are the fonts in release tarball
  • Kar Chandrashekhara Kambara.ttf 
  • Kar Girish Karnad.ttf         (Bold:-  Looks like bold version of Kar Chandrashekhara Kambara.ttf   )
  • Kar Puthina.ttf
  • Kar Gopalakrishna Adiga.ttf   (Bold: Looks like bold version of Puthina)
  • Kar Puchamthe.ttf  
  • Kar U R Ananthamurthy.ttf
  • Kar K S Narasimhaswamy.ttf  (Bold)
  • Kar Maasthi.ttf     (Bold)
  • Kar Kuvempu.ttf              (Bold)
  • Kar Shivarama Karantha.ttf  (Bold)
  • Kar Vi Kru Gokak.ttf  (Bold)

  • Kar Da Raa Bendre.ttf

      Above mentioned bugs should be fix before the purchase and release of the fonts from Government. One should test rendering of these fonts with latest stable version of Harfbuzz-NG included in most of the key projects including Libreoffice, Gnome, Android and so on. These rendering issues must be fixed before the release of the fonts.


Tags: #kannada, #fonts, #agl, #harfbuzz, #opentype

Thursday, January 30, 2014

Announcing alpha release of lohit-malayalam 2.91.0 from lohit2 project

   Glad to announce alpha release of lohit-malayalam 2.91.0 from lohit2 project[1]. As we planned earlier [2] indeed this is lightest Malayalam modern script font around with just 214 glyphs and 11 open type table.

    We have done following improvements in Alpha version over the 2.5.4 release.

  • Reduced number of glyphs nearly by 25%
  • Open type Looksup are reduced by 45%
  • Supporting mlm2 and mlym specifications.
  • Testing on Harfbuzz NG and Uniscribe (W8)
  • Followed AGL syntax with User friendly glyph names.
  • Improved GASP table (grid-fitting)
  • TTF build from feature file.
    Updated lohit project page [3] for download details. Source tarball link [4], TTF tarball link [5] and webfonts format for Lohit is at [6].

    I would like to say thanks to Ani for her help in testing stuff, Shriramana for reporting important bugs from standard perspective and Sneha for making this happen :)

    As this is alpha release need your help for testing it and making it more perfect. I am still doubtful that we might have missed some important exceptions of Malayalam script so looking forward to fix them in coming releases.

    By next week this release will be available in Fedora 20 and Rawhide.


Thursday, December 26, 2013

Malayalam moderns script and Lohit Mayalam

As you know we started working on Lohit Mayalam this month under the lohit2 project with planning number of improvement from standards, efficiency and effectiveness purpose. [1]

Sneha in between blogged regarding how we started working on Lohit Malayalam. [2]

After getting initial basic work done we got stuck on standard perspective. How the ligatures should be and what is attestation for same.

Earlier Lohit Malayalam was behaving bit different, cross checked with some modern script Malayalam fonts around like NotoSans, RaghuMalayalam. Gone through utrrs but still attestation was lacking.

Finally after bit searching remembered Govt. of India has Vishwabharat(विश्वभारत) [3] series where they write regarding each script of India.

 And we got good documentation for Malayalam modern orthography. We will refer to this and cross check with things around before the Alpha release of lohit-malayalam.


Thursday, December 12, 2013

Lohit2: Lohit Malayalam development plans

    I am sure now everyone should be happy with Lohit Devanagari and Lohit
Gujarati releases. While looking back i see we have achieved objectives
planned [1] during the start of project. Its time to move towards other
scripts. Though Bengali, Gurumukhi, Tamil looks low hanging fruits we
want to fix bit more challenging scripts as well.

    We started thinking on what we can do in Lohit Malayalam in last
month. After couple of weeks of analyisis we found there is good scope
for improvement in Lohit Malayalam.

    Basic improvements as we done in Devanagari and Gujarati
    1. Following AGL. [2]
    2. Supporting points provided in Unicode chapter 9 for Malayalam script.
    3. Feature file separate for flexibility and reusability.
    4. Complete cleanup of existing Open type tables
    5. Supporting both "mlym" and "mlm2" open type specifications.
    6. Thorough testing with Harfbuzz and Uniscribe (WinXp, W7 and W8)

    Other fonts specific improvement.
    7. Presently Malayalam font has 281 shapes out of that we figure out
71 (+5/6) shapes are irrelevant. We can achieve these shapes with glyph
positioning and intelligent glyph substitution rules without affecting
fonts aesthetics and quality.
    8. We have some pending bugs on bugzilla [3] as well

    As we planned earlier making Lohit fonts most efficient and
effective is our primary objective. [1]

    Bit ambitious to say right now but i want make Lohit as a lightest
Malayalam modern script fonts.

    Sneha has already started working on lohit2 [4] git repo for
Malayalam font development.

   If you are looking any other suggestions or improvement in Lohit,
feel free to propose here.


Tuesday, November 19, 2013

Points on Open source language summit 2013 second day

As my first tweet in the morning said, this is lohitise and ibus-typing-booster day
 we indeed had great day around this project.

Lohit-ising fonts:

Demonstrated lohit-ise concept with Samyak Devanagari fonts due to time restriction we only modified the single combination of Samyak Devanagari but i hope that was sufficient for understanding concept.

I hope Sneha [1] will do further blogging with nice images on how we actually done this demonstration. Steps are already available on my earlier blog.[2]

Looking forward this to make good impact on some of the available fonts around. But i think still people will take time understanding usefulness of this. So we need to provide clear details on what things got improved and how it will help in longterm after lohit-ising fonts.

Ibus typing booster [3]
This project is around now for 2+ years and number of feature developed considering users requirement.
Anish started nicely with the need behind this project with me presenting on feature of typing booster.

Thanks a lot to Vasudev again for trying installing ibus-typing-booster on Debian. I am hoping he liked the project and will give some more inputs and contribute more.

I tried last two time test day of itb and this is first time when all participants appreciated project and said the need of more intense testing of this may be for couple of hours. This is really motivating.

I am setting up project page for it.


How to Lohit-ise open type fonts not updated or new development

These are steps we followed in session for lohitising open type fonts.

1. git clone
2. cd (devanagari or malayalam etc as per your fonts script requirement)
3. cp "yourfont.ttf" .
4. yourfont.ttf open with fontforge and save as a yourfont.sfd
5. open yourfonts .sfd and update glyphs names as per lohit fonts.
6. python ../scripts/ yourfont.sfd Lohit-.fea  

   Things to note here only import gsub of lohit project, it will keep gpos tables intact.

There are number of benefits of lohitising open type fonts, i will write separate blog on it with proper implementation example.