Welcome to SparkyLinux forums
Zapraszamy również na polsko-języczne Forum https://forum.linuxiarze.pl

Bengali / Bangla / Indic Ligature Rendering Problem

Started by duststuff, April 07, 2024, 08:56:18 AM

Previous topic - Next topic

duststuff

With a Sparky 7.3 Xfce system, I've run into a problem of some Bangla ligatures* not rendering correctly when using a non-Bangla font like 'Liberation Sans'. From what I can tell, it's possible there are a variety of reasons for this type of font rendering problem and also a variety of solutions. Probably the easiest solution for some use cases is to just use a Bangla font. However, my use case is typing both English and Bangla in the same file. Thus, it is more efficient to be able to use the same font for both languages, and so far I've found that this works best with non-Bangla fonts. While using Linux Mint Debian Edition (LMDE) 6 (Xfce) (based on Debian 12 like Sparky 7) I had settled on the Liberation Sans font as the best solution I knew of. However, I'm migrating from LMDE 6 to Sparky 7, and I've noticed that for some reason this font does not work in the same way with Sparky -- it's broken in the sense of some ligatures not appearing correctly or appearing as just representations of the individual keystrokes rather than converting into the appropriate ligature. I am using the same input method (ibus) and keyboard layout (Bangla m17n 'Unijoy') on both systems.

* Ligatures are sometimes referred to as conjunct letters or combined letters, and are a one-character representation produced by two or more keystrokes (eg. a single character for the 'English' consonant cluster 'spr').

One idea I had is that perhaps there are one or more packages installed in LMDE that are not installed in Sparky. So I did some searches to try to come up with a list of all the relevant packages I could think of, but when I compared them, each system had them all installed. Here's the list I came up with: gir1.2-ibus-1.0 ibus ibus-data ibus-gtk ibus-gtk3 ibus-gtk4 ibus-m17n im-config libibus-1.0-5 python3-ibus-1.0 libgraphite2-3 libgraphite2-dev libm17n-0 m17n-db gir1.2-pango-1.0 libotf1 libpango-1.0-0 libpango1.0-dev libpangocairo-1.0-0 libpangoft2-1.0-0 libpangoxft-1.0-0 . Any ideas on other packages that might be relevant that I should check out? (I installed 'task-bengali', but that didn't help with this. I'm pretty sure 'task-bengali-desktop' wouldn't help either.)

The other idea I had is that the two systems have different settings related to languages, fonts, etc. In LMDE 6 (and other Ubuntu-based distros I've used) there is often a Region & Language settings section in the apps menu and this often prompts you to install extra language-related packages, if necessary, and might also have some options related to other types of language / fonts settings. However, I haven't been able to find any type of language-related settings in Sparky. Any ideas on where I could find and potentially edit these types of settings?

For now, because the need is time-sensitive, I'll probably look for another font that might be able to handle both English and Bangla without this problem, and if that fails, will revert back to using a Bangla font. But I thought I'd go ahead and post this on here in case anyone has any ideas about what I'm missing in regards to trouble-shooting this.

AxL

Quote from: duststuff on April 07, 2024, 08:56:18 AMWith a Sparky 7.3 Xfce system, I've run into a problem of some Bangla ligatures* not rendering correctly when using a non-Bangla font like 'Liberation Sans'. From what I can tell, it's possible there are a variety of reasons for this type of font rendering problem and also a variety of solutions. Probably the easiest solution for some use cases is to just use a Bangla font. However, my use case is typing both English and Bangla in the same file. Thus, it is more efficient to be able to use the same font for both languages, and so far I've found that this works best with non-Bangla fonts. While using Linux Mint Debian Edition (LMDE) 6 (Xfce) (based on Debian 12 like Sparky 7) I had settled on the Liberation Sans font as the best solution I knew of. However, I'm migrating from LMDE 6 to Sparky 7, and I've noticed that for some reason this font does not work in the same way with Sparky -- it's broken in the sense of some ligatures not appearing correctly or appearing as just representations of the individual keystrokes rather than converting into the appropriate ligature. I am using the same input method (ibus) and keyboard layout (Bangla m17n 'Unijoy') on both systems.

* Ligatures are sometimes referred to as conjunct letters or combined letters, and are a one-character representation produced by two or more keystrokes (eg. a single character for the 'English' consonant cluster 'spr').
[....]

Check this link, to see if it helps you to solve the problem you are suffering from:

➤ Want to know how you can use a program you have never used before? "man" will be your best new friend! Type "man <pkg-name>" in a shell.
➤ Or, point your browser to "manpages.debian.org/<pkg-name>" .... RTFM !!!

AxL

BTW just out of curiosity, I searched the internet to see what the 'Bangla' font looked like. And surprisingly, I was able to see it without any apparent problem.



In this case using SeaMonkey. And you can see it, in this image:







And finally, these are most of the fonts that I have installed on my system












➤ Want to know how you can use a program you have never used before? "man" will be your best new friend! Type "man <pkg-name>" in a shell.
➤ Or, point your browser to "manpages.debian.org/<pkg-name>" .... RTFM !!!

duststuff

Quote from: AxL on April 10, 2024, 04:59:16 PM Check this link, to see if it helps you to solve the problem you are suffering from:


Thanks, AxL. Yeah, I had seen that page in my searching and the accepted answer there is what I referred to as probably the easiest solution -- just use a different font that doesn't have that issue. The thing I'm curious about though and what prompted me to start this topic is why a font like Liberation Sans (as well as default system fonts, and probably others that I didn't test) has this issue in Sparky 7 but doesn't have it in Linux Mint Debian 6, since they are both based on Debian 12. My best guess is that it has to do with what packages are installed or one or more language-related settings, but I have no idea what those would be.

duststuff

Quote from: AxL on April 10, 2024, 05:24:13 PMBTW just out of curiosity, I searched the internet to see what the 'Bangla' font looked like. And surprisingly, I was able to see it without any apparent problem.

Actually, I'm not surprised since most modern Unicode fonts would be able to handle displaying Bangla script (although sometimes broken here or there if they weren't specifically created for Bangla), plus lots of other non-Roman languages' scripts as well -- that's one of the advantages of Unicode, that so many more glyphs (characters) can be included in a font.

And to make it practical for my use case, I find it curious that the problems I've faced will show up in my email client (Claws Mail) as well as the default text editor of Sparky 7 (Mousepad), but everything works fine in the same email client on LMDE 6 and in its default text editor (xed), once again noting that both of these distros are based on Debian 12.

Also, not sure why, but I'm not able to see the images (other than emojis) you included in your post.

duststuff

BTW, practically speaking, I've 'solved' my problem by switching to using the font 'Tiro Bangla', which so far seems to be working other than a few odd-looking things in its Latin / Roman (i.e. English) characters. It also has the added bonus of having its Bangla script and English script on the same point scale as far as size, whereas other fonts I've used were often off by about two points, so you could spend a lot of time adjusting the size of the text depending on how mixed the two languages were in what you were composing.

All that being said, I just mention it in case others find it helpful, but I'm not going to mark this as solved yet, since my actual questions are related to what packages and/or settings and/or anything else would cause this difference of behavior between two OS's based on the same distro.

duststuff

Quote from: duststuff on April 10, 2024, 05:56:44 PMAlso, not sure why, but I'm not able to see the images (other than emojis) you included in your post.

In the email notification of your reply that I got, I saw that there were 'imgur' links for the images, so I tried clicking on those in the email. However, for some reason (I remember it happening before too), I'm not able to access the imgur image-sharing site, so that's probably why they aren't showing up for me on the forum website. If I really needed to see them, I guess I could try a VPN with a U.S. IP address, but I think I'll pass on that for now. :-)

AxL

Quote from: duststuff on April 10, 2024, 05:47:51 PMThanks, AxL.   [....]



Quote from: duststuff on April 10, 2024, 05:56:44 PM[....]  Also, not sure why, but I'm not able to see the images (other than emojis) you included in your post.

Well, I don't know what could be the problem for you not to be able to see the attached images. They are simple images in .png format, and hosted in imgur (.... anyway, I leave you the urls of the two images):

https://i.imgur.com/bjJE7Cf.png

https://i.imgur.com/yuNvAVb.png


Edit: I just saw your comments in your last post, clarifying a bit the problem you are having.

However, I have uploaded the same images to a different site. I hope this time you won't have any problems viewing them:

















Cheers !! 


➤ Want to know how you can use a program you have never used before? "man" will be your best new friend! Type "man <pkg-name>" in a shell.
➤ Or, point your browser to "manpages.debian.org/<pkg-name>" .... RTFM !!!

duststuff

Thanks, AxL, using that second site allows the images to come through fine for me now, and I appreciate your effort in re-posting those. I've heard from others here and there on various lists / forums that they also sometimes / always have a problem accessing imgur, but I don't know how common it is or what the reasons for it are -- I'm guessing it's likely intentional or unintentional effects of the site's security policies or how it's set up, maintained, etc.

AxL

Quote from: duststuff on April 11, 2024, 06:52:24 AMThanks, AxL, using that second site allows the images to come through fine for me now, and I appreciate your effort in re-posting those.
[....]

No problem at all. You're welcome !! 


➤ Want to know how you can use a program you have never used before? "man" will be your best new friend! Type "man <pkg-name>" in a shell.
➤ Or, point your browser to "manpages.debian.org/<pkg-name>" .... RTFM !!!

duststuff

By the way, I did check out the 'solution' / workaround of deleting the 'FreeSans' and 'FreeSerif' font families, and that seems to have resolved the problem, at least based on my initial limited testing. I wasn't sure that I wanted to totally delete them from my system, so I thought about trying to just rename them or move them so that the system wouldn't try to use them. While looking into this, I found the 'font-manager' package (available in repo), which provides a handy GUI for viewing / managing fonts ('Font Manager' in the apps menu of Sparky 7.3 Xfce), including the ability to disable fonts. When using this, the changes happen immediately, and the only additional step you need to do is restart any affected programs if they are already open at the time.

(Still not marking this as solved though, for reasons stated earlier.)

View the most recent posts on the forum