Sinhala Unicode · Font engineering · Rendering engines

Cracking Sinhala Unicode font rendering

Harsha Wijayawardhana’s decisive contribution to the Sinhala language in computing

Harsha Wijayawardhana considers solving the practical problem of how to construct Sinhala Unicode fonts that worked correctly with rendering engines to be his greatest contribution to the Sinhala language.

The breakthrough

The characters had been encoded—but encoding alone did not make Sinhala display correctly. Harsha finally worked out how Sinhala glyphs, conjuncts and modifiers had to be controlled through OpenType font rules so that rendering engines could produce the correct written forms from Unicode character sequences.

Why encoding was not enough

Unicode assigns a code point to each encoded character. Sinhala writing, however, contains dependent vowel signs, consonant signs, reordered forms, touching letters and conjunct formations such as yansaya and rakaransaya. The stored character sequence and the visible glyph sequence are therefore not always identical.

A functional Sinhala Unicode font requires more than a collection of drawings. It needs an intelligent shaping layer: substitution rules that select the correct glyph or ligature, positioning rules that place marks accurately, and controlled interaction with the operating system’s rendering engine.

Working out the rendering rules

Through practical experimentation, Harsha tested how Sinhala character sequences were interpreted by rendering engines and translated the script’s writing behaviour into OpenType layout rules. He used Microsoft Visual OpenType Layout Tool—VOLT—for rule construction, together with FontLab, Fontographer and FontForge for font engineering.

This work addressed the central implementation question: how could a standards-compliant font preserve the underlying Unicode text while rendering the expected Sinhala visual form? The answer lay in separating characters from glyphs and using OpenType substitutions and positioning rather than assigning a separate character code to every visible conjunct.

Sarasavi Unicode and collaborative experimentation

Harsha applied and tested these principles while developing the rules for Sarasavi Unicode. The public ICT History record describes Sarasavi as the font in which he experimented with Unicode font rules. He also worked with Winnie Hettigoda, testing Sinhala font shapes and developing rules for Hettigoda’s font. These implementations converted the research from theory into fonts that could be examined across real software environments.

fonts.lk: turning research into public infrastructure

Harsha developed www.fonts.lk through the Software Development Unit of the University of Colombo School of Computing during 2004–2005. It was the first website devoted to Sinhala and Tamil Unicode implementation and became a focal point for standards-compliant fonts, keyboard resources, documentation, training material and practical guidance.

The site’s identity became closely associated with Sinhala and Tamil Unicode adoption. More importantly, fonts.lk provided a bridge between standards committees and everyday implementation: font developers could obtain guidance, users could obtain compliant resources, and the wider community could test and adopt Unicode instead of remaining dependent on mutually incompatible legacy font encodings.

From experiment to national guidance

Harsha served on the Sinhala font and language committees, the ICTA Local Language Working Group and the SLSI ICT Sectoral Committee. He participated in the second revision of SLS 1134 and edited its third revision. The lessons learned while implementing and testing fonts therefore flowed into Sri Lanka’s national guidance for Sinhala input, storage and rendering.

Cover of Guide to Creating Sinhala and Tamil Unicode Fonts

Documenting the method for others

Harsha did not retain the knowledge as a private technical solution. He authored the introductory font-engineering material and, with Aruni Goonetilleke, edited Guide to Creating Sinhala and Tamil Unicode Fonts. The ICTA publication explains characters and glyphs, font metrics, bitmap and outline technologies, TrueType and OpenType, font-development tools and the construction of standards-based Sinhala and Tamil fonts.

Read the ICTA publication →

Why this contribution matters

Correct rendering made Sinhala Unicode usable in documents, websites, databases and software applications while retaining searchable and interoperable text. The breakthrough helped move Sinhala computing away from isolated font-specific encodings and towards a standards-based ecosystem that could function across systems and applications.

For Harsha, this was not simply the creation of another typeface. It was the resolution of the engineering problem that connected encoded Sinhala characters to correct visible Sinhala writing—and the transfer of that knowledge to standards, tools, developers and the public.

Sources: ICT History of Sri Lanka — Harsha Wijayawardhana profile; ICT History — Language Technology; Theekshana technical profile and first-person project record; Unicode implementation and rendering history; ICTA font resources; and Guide to Creating Sinhala and Tamil Unicode Fonts.