Thank you for reporting the bug. Unfortunately without clear steps to reproduce it, we cannot track down the origin of the problem. Please provide a clearer set of step-by-step instructions on how to reproduce the problem. I have set the bug's status to 'NEEDINFO'. Please change it back to 'UNCONFIRMED' once the steps are provided
Created attachment 194179 [details] a sample Persian document, its font, and screenshots illustrating the text before and after the insertion of the tashdid character
ّIn some cases, inserting a tashdid character (Unicode 0651) in a Persian text breaks it or causes the text to be rendered in a bad way. Since Arabic and Persian writing systems are very similar, this may also affect Arabic texts. I have also observed instances where inserting this character does not cause any problems. I am not certain about the specific conditions that lead to this issue; however, it appears to be font-dependent. Thus far, I have encountered this problem in Writer 7.3.7.2 (on Xubuntu 22.04) and Writer 24.2.2.2 (on Ubuntu 24.04). When this occurs, pressing Ctrl+Z does not restore the text to its normal appearance, necessitating a document reload. The attached file (example.zip) contains a sample Persian document, the font I have used, and screenshots illustrating the text before and after the insertion of the tashdid character. This font is widely used for Persian script, and we do not encounter this issue in Microsoft Word. I am willing to conduct any tests you suggest and provide any additional information required. Thank you for your excellent work!
I tested too with B Nazanin font and other Persian font (B Mitra) and confirm this bug.
When I change the font of the same document to "Noto Sans Arabic" in Ubuntu, the tashdid character is always displayed perfectly. So this seems to be a font-dependent issue.
Persian fonts of the IR series for example "IR Nazanin" also have no problem in displaying the tashdid character.
On v7.6.6.3 on Ubuntu I have no issue with any font I tried.
This is my finding. I could reproduce the issue on the shared document. The issue is observed only when editing that document, meaning that if the user types the same text in another document (no copy/paste) there is no issue. Someone needs to check for hidden characters in the document, otherwise in normal situation, there is no issue even with B Nazanin.
(In reply to ahangarha from comment #8) > This is my finding. > > I could reproduce the issue on the shared document. The issue is observed > only when editing that document, meaning that if the user types the same > text in another document (no copy/paste) there is no issue. > > Someone needs to check for hidden characters in the document, otherwise in > normal situation, there is no issue even with B Nazanin. The issue may be related to the presence of diacritics (kasreh, fatheh, etc) in text. In any text with B Nazanin font and possibly similar fonts, if a sentence contains a diacritic such as kasreh, inserting a tashdid in the sentence, at least displaces the diacritic to a wrong position.
This is a duplicate of the tdf#135778, which is essentially a problem with the "B Nazanin" font itself. Please read Khaled's note in tdf#135778 comment 7: "These fonts are essentially broken and depend on undocumented quirks of Windows OpenType implementation. The issue might be fixed in HarfBuzz, but there is nothing to fix in LibreOffice itself." It may be possible to provide a workaround in HarfBuzz itself. You can follow the bug report for HarfBuzz here: https://github.com/harfbuzz/harfbuzz/issues/2647 Meanwhile, you may use a fixed "B Nazanin" font created by Khaled: https://github.com/harfbuzz/harfbuzz/files/5093421/BNazanin.2.zip *** This bug has been marked as a duplicate of bug 135778 ***