Incorrect CTL font rendering by LibreOffice 4

This issue has been raised before and
looks like we have an accepted answer. But the answer does not actually solve the problem. It tries to blame some font.


(UPDATE: Further discussion shows that the particular (blamed) font, SutonnyMJ is actually broken. But that font is not part of my following discussion. SutonnyMJ is a non-Unicode font and hence obsolete with its own inherent problems. The fonts, SolaimanLipi and
SutonnyOMJ, mentioned in the following discussion are both Unicode fonts.)


The issue is, it appears that LibreOffice 4 is rendering CTL (Bangla/Bengali) fonts incorrectly.

Please see the following Bengali/Bangla text as rendered in LibreOffice 3. The interword spaces are fine. This documents uses two fonts,
SolaimanLipi and
SutonnyOMJ

I have using the first font for a quite a long time. In fact this is the most popular font used the newspapers and websites in Bangladesh. Moreover, this font, along with the second one, has been chosen (gazetted) as one of the standard fonts to be used in all government documents.

Anyway, when the same file in opened in LibreOffice 4, we find that the inter word spaces are garbled, bottom part of characters are missing and some characters are shown as empty boxes.

But when we open the same document in OpenOffice, there is no problem at all. Please see below,

Even more, when the same text is displayed in Google Chrome using SolaimanLipi font, there is no problem at all. Please see below,

image description

As my experience goes over all these years, I can unequivocally confirm that the above mentioned problem is solely due to LibreOffice 4. This problem occurs irrespective of the input method, be it keyboard or cut-and-paste. Moreover, these fonts present absolutely no problem in the commercial word processing software.

I have correctly set the CTL language and CTL font in all the cases.

I find that two bugs, with insufficient or misdirected attention, have been lodged here (one, two). Please see the comment in the first one, which is absolutely incorrect.

Please let me know if you any observation or advice. Also, please let me know how do I bring more attention to the bugs already reported.

You can find the .odt file which has been used for test purpose over here.

What version of LibreOffice 4 are you using? If it is 4.1, then this might be the same issue as (this bug)[https://bugs.freedesktop.org/show_bug.cgi?id=70968] which will be fixed in the next 4.1.4 release (unless you are using Fedora, then it should be fixed in 4.1.3 as they backported the fix).

It is in another machine from the one I am answering (this one contains LibreOffice 3). As far as I remember that machine has LibreOffice 4.1. I will let you know the minor version as soon as I can reach there. I use Ubuntu. Thanks.

The version is Version: 4.1.3.2, Build ID: 410m0 (Build:2). So, I need to wait for sometime before version 4.1.4 comes out in late December 2013. I am using PPA.

As Khaled has indicated this may be a bug (fdo#70968) that has now been fixed. I would still however like to point out that the linked fonts are not valid Unicode.

The fonts, SolaimanLipi and SutonnyOMJ, mentioned in the following discussion are both Unicode fonts.

Where does this information come from? What does “Unicode” mean in this context? Neither font encode glyphs in an entirely valid manner. When I examine the two fonts linked to there are many non-Unicode glyphs evident. SutonnyBanglaOMJ.ttf contains 354 while SolaimanLipi_20-04-07.ttf contains 300. The glyphs commence at code point U+10000 (the Linear B range) and these positions are referred to in the various lookup tables (e.g., init, nukt, rphf, etc.) FontForge also indicates other warnings related to horizontal and vertical device metrics, but it is not clear to me to what extent this may effect on-screen rendering.

Again, to be clear, this may not be indicative of the problem being experienced, but it does not help if the font is not a good one when trying to determine an exact cause.