[HarfBuzz] vertical text for indic script ( Devnagri )

Vishal Gautam 15vishal15 at gmail.com
Fri Jul 17 07:25:40 UTC 2020


Hi All ,

After shaping and rendering latin and CJK script in TTB vertical direction
using harfbuzz shaping , now i want to render devnagri script , where
multiple glyphs  , most of the time , form a cluster . If i send devnagari
text via harfbuzz and set direction "TTB" then advances ( see the
highlighted portion in output ) returned by harfbuzz for all glyphs in a
cluster indicate that harfbuzz is shaping each glyph for standalone
rendering  and ignoring the fact that glyph could form a cluster with
another .

See the output of devnagri script codepoints in TTB direction .
Input command :

./hb-shape --font-file="/Users/vgautam/Downloads/DevanagariMT.ttc"
--unicodes="हिंदी
टायपिंग" --direction=ttb
--show-unicode --no-glyph-names


Output Value :


<U+0939,U+093F,U+0902,U+0926,U+0940,U+091F,U+093E,U+092F,U+092A,U+093F,U+0902,U+0917>
[398=0 at -327,-2547+0,*-3293*|99=0 at -558,-2026+0,*-3293*|83=3 at -545,-2255+0,
*-3293*|102=3 at -327,-2543+0,*-3293*|76=5 at -514,-2309+0,-3293|100=5@
-327,-2252+0,-3293|91=7 at -599,-2252+0,-3293|398=8 at -327,-2547+0,-3293|86=8@
-578,-2252+0,-3293|68=11 at -607,-2254+0,-3293]



How should I shape indic text with harfbuzz for TTB direction . Should i
shape devnagri as LTR text and then render cluster after cluster in
vertical .

Thanks
Vishal Gautam
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/harfbuzz/attachments/20200717/70ecded4/attachment.htm>


More information about the HarfBuzz mailing list