<div dir="auto"><div>Hello Rakesh,<div dir="auto"><br></div><div dir="auto">Thanks for the reply.</div><div dir="auto"><br></div><div dir="auto">Is there any implementation in "c" or python for this complex text layout in Malayalam so that I can port to Go ?</div><div dir="auto"><br></div><div dir="auto">Thanks</div><div dir="auto">Jeffrey</div><br><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, 4 Feb 2020, 12:51 Rajeesh K V, <<a href="mailto:rajeeshknambiar@gmail.com">rajeeshknambiar@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><br><div>I am trying to generate a PDF document with Malayalam text using go language.<br>For this I am using the go pdf library <a href="https://github.com/signintech/gopdf" target="_blank" rel="noreferrer">https://github.com/signintech/gopdf</a><br>The issue is that the malayalam text is not displayed properly.<br><br>Good Text (as you all know) <img src="https://i.stack.imgur.com/KN5m1.png" style="margin:auto"></div><div><a href="https://i.stack.imgur.com/KN5m1.png" target="_blank" rel="noreferrer">https://i.stack.imgur.com/KN5m1.png</a><br></div><div><br></div>Obtained Text from gopdf (Improper Text) <img style="margin:auto" src="https://i.stack.imgur.com/xLN8r.png"><div><a href="https://i.stack.imgur.com/xLN8r.png" target="_blank" rel="noreferrer">https://i.stack.imgur.com/xLN8r.png</a></div></div></blockquote><div><br></div><div>Well, the ‘text’ is proper (in the sense that Unicode code points are correct). The PDF generating library is missing ‘Complex Text Layout’ support, which is required to shape Malayalam script properly.<br></div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div></div>Does anyone know how to fix the issue ?<br></div></blockquote><div><br></div><div>You’d need to ‘shape’ the text either before passing to the library or the library should internally handle it. I doubt if there’s a Go library which does CTL shaping. PDF document only deals with ‘glyph ids’, so you’d need to have proper glyph ids in place correctly.<br></div><div> </div><br clear="all"></div>-- <br><div dir="ltr"><div dir="ltr"><div><div dir="ltr">Rajeesh<br></div><div><a href="https://rajeeshknambiar.wordpress.com" target="_blank" rel="noreferrer">https://rajeeshknambiar.wordpress.com</a></div><div><br></div></div></div></div></div>
_______________________________________________<br>
Swathanthra Malayalam Computing discuss Mailing List<br>
Project: <a href="https://savannah.nongnu.org/projects/smc" rel="noreferrer noreferrer" target="_blank">https://savannah.nongnu.org/projects/smc</a><br>
Web: <a href="http://smc.org.in" rel="noreferrer noreferrer" target="_blank">http://smc.org.in</a> | IRC : #smc-project @ freenode<br>
<a href="mailto:discuss@lists.smc.org.in" target="_blank" rel="noreferrer">discuss@lists.smc.org.in</a><br>
<a href="http://lists.smc.org.in/listinfo.cgi/discuss-smc.org.in" rel="noreferrer noreferrer" target="_blank">http://lists.smc.org.in/listinfo.cgi/discuss-smc.org.in</a><br>
<br>
</blockquote></div></div></div>