Bug Hunting Session
Bug 72641 - [ALL_INDIC] Improper rendering when user enters input(INDIC) in search box in LibO applications
Summary: [ALL_INDIC] Improper rendering when user enters input(INDIC) in search box in...
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Localization (show other bugs)
(earliest affected) release
Hardware: All All
: medium normal
Assignee: Not Assigned
Depends on:
Blocks: Find-Search Languages
  Show dependency treegraph
Reported: 2013-12-12 13:02 UTC by bbarve
Modified: 2019-08-26 21:12 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:

mr_IN oowriter rendering issue. (78.91 KB, image/png)
2013-12-12 13:02 UTC, bbarve
Screenshot of finding marathi text (50.78 KB, image/png)
2014-10-26 12:40 UTC, Buovjaga
mr_IN rendering in oowriter (35.56 KB, image/png)
2014-10-27 11:22 UTC, bbarve
mr_IN_actual_rendering_f25 (29.71 KB, image/png)
2017-07-07 09:20 UTC, bbarve
mr_IN_expected_rendering (82.83 KB, image/png)
2017-07-07 09:20 UTC, bbarve
Incorrect rendering of devanagari text in Find box (136.14 KB, image/png)
2017-11-30 18:48 UTC, G Karunakar
Hindi text sample for previous image attached (36.75 KB, application/vnd.oasis.opendocument.text)
2018-02-16 13:40 UTC, G Karunakar

Note You need to log in before you can comment on or make changes to this bug.
Description bbarve 2013-12-12 13:02:22 UTC
Created attachment 90664 [details]
mr_IN oowriter rendering issue.

Description of problem:
When user enters marathi input in search box in libre office applications like oowriter, oocalc, the rendering of the same is improper.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1.select input language as marathi.
2.open oowriter
3.enter marathi input in search box
4.observe the rendering of marathi input.

Actual results:
marathi input rendering is improper.

Expected results:
marathi input rendering should be proper.
Comment 1 bbarve 2013-12-13 06:38:07 UTC
This issue is observed in all indic locales. Hence updating the summary accordingly.
Comment 2 Buovjaga 2014-10-26 12:40:29 UTC
Created attachment 108447 [details]
Screenshot of finding marathi text

I observe no problem.
Please test with latest stable and provide a sample document so I can test.
Comment 3 bbarve 2014-10-27 11:22:34 UTC
Created attachment 108503 [details]
mr_IN rendering in oowriter

Tested with following build at Fedora 21 using mr_IN locale. (VM environment)

बिल्ड ID:

Still observing the same issue. Please see attached latest screen-shot.
There is nothing specific about the input in mr_IN used here but some random input of 8-10 characters in the search text field. For e.g. ीावनूलेूीलेगवूीेूवै.

Copying these characters as it is would work fine. However if you add some more characters at succeeding places or select the whole string, the issue can be seen clearly.
Comment 4 Buovjaga 2014-10-27 11:47:15 UTC
(In reply to bbarve from comment #3)
> There is nothing specific about the input in mr_IN used here but some random
> input of 8-10 characters in the search text field. For e.g.
> ीावनूलेूीलेगवूीेूवै.
> Copying these characters as it is would work fine. However if you add some
> more characters at succeeding places or select the whole string, the issue
> can be seen clearly.

Tried again with the characters you provided and it's fine. Maybe this is a Linux-only issue? Can you try on some Windows machine?
Comment 5 Jean-Baptiste Faure 2016-01-24 09:25:02 UTC
Not reproducible for me with LO built at home under Ubuntu 15.10 x86-64. As the reporter did, I used Lohit Devanagari font to do my tests.

Best regards. JBF
Comment 6 tommy27 2016-12-21 21:03:10 UTC
please give an update of this bug status using latest LibO

if bug is still there revert status to UNCONFIRMED
if bug is gone change it to RESOLVED WORKSFORME

status NEEINFO until then
Comment 7 QA Administrators 2017-06-28 12:36:21 UTC Comment hidden (obsolete)
Comment 8 bbarve 2017-07-07 09:19:01 UTC
Checked again with f25-

[bbarve@dhcp223-127 ~]$ rpm -qa libreoffice-core

Following were the repro steps-

1. Launch oowriter
2. input following text in mr_IN in search bar - 'वाढदिवसाच्या हार्दिक शुभेच्छा'
3. select the last word i.e 'शुभेच्छा' by double-clicking it.
4. Observe the rest of the words in the search bar.

Actual result:
The rendering of the Marathi characters is affected as long as they are selected.

Expected result:
The rendering should be proper. 

The issue is clearly reproducible. Please refer attached screenshots.
Comment 9 bbarve 2017-07-07 09:20:13 UTC
Created attachment 134526 [details]
Comment 10 bbarve 2017-07-07 09:20:57 UTC
Created attachment 134527 [details]
Comment 11 tommy27 2017-07-22 09:54:32 UTC
reproducible under Win7 x64 using LibO
Build ID: d7a2fd3e8262b8897ad06f01f25f46330e050e0c
CPU threads: 8; OS: Windows 6.1; UI render: GL; 
TinderBox: Win-x86@42, Branch:master, Time: 2017-07-20_08:26:15
Locale: it-IT (it_IT); Calc: group

status -> NEW
hardware -> All
Comment 12 G Karunakar 2017-11-30 18:48:42 UTC
Created attachment 138155 [details]
Incorrect rendering of devanagari text in Find box

Verified on Devuan Jessie
Build ID: 92a7159f7e4af62137622921e809f8546db437e5
CPU threads: 2; OS: Linux 3.16; UI render: default; VCL: gtk2; 
Locale: en-US (en_IN); Calc: group

Issue seems to happen with Short I vowel sign ि , which combines with consonant preceding it. Though certain other sequences also dont render properly - like the second word in search box (Browser written in Hindi)

Search box contains following text.
कंप्यूटिंग ब्राउज़र उद्धारक समर्थन हिंदी
Comment 13 Pranav Kant 2018-02-16 13:21:09 UTC
This is not just about the search box. This happens with all the text boxes in LibreOffice. SO something to do with the selection overlays in general.
Comment 14 G Karunakar 2018-02-16 13:40:22 UTC
Created attachment 139946 [details]
Hindi text sample for previous image attached

Hindi text sample for previous image attached by me.
Comment 15 Pranav Kant 2018-02-16 14:42:08 UTC
So, we looked at this in a local LibreOffice Hackathon and have found the relevant piece of code responsible for this. The selection offsets for consonants with a negative vowel offset are not being calculated correctly. Just dumping the notes here, so that even if we are not able to make it by the end of the hackathon, I or somebody else can pick it up sometime later.

I was testing this for Hindi word: प्रसारित which consists of 8 characters.

When this is selected in searchbox, the second last character is not selected.

The code is in Edit::ImplRepaint() in vcl/source/control/edit.cxx

Look for this loop:

        // selection is highlighted
        for(sal_Int32 i = 0; i < nLen; ++i)
            tools::Rectangle aRect(aPos, Size(10, nTH));
            aRect.Left() = pDX[2 * i] + mnXOffset + ImplGetExtraXOffset();
            aRect.Right() = pDX[2 * i + 1] + mnXOffset + ImplGetExtraXOffset();
            SAL_DEBUG("i : " << i << ", rect: " << aRect);

The loop gives following output:

debug:2909:2909: i : 0, rect: 7x17@(2,4)
debug:2909:2909: i : 1, rect: 0x17@(9,4)
debug:2909:2909: i : 2, rect: 0x17@(9,4)
debug:2909:2909: i : 3, rect: 10x17@(9,4)
debug:2909:2909: i : 4, rect: 3x17@(19,4)
debug:2909:2909: i : 5, rect: 3x17@(22,4)
debug:2909:2909: i : 6, rect: 0x17@(25,4)
debug:2909:2909: i : 7, rect: 8x17@(32,4)

As one can see, there's a rectangle of 0x17 for i = 6. And there's a gap from 25 to 32. If we explicitly set it such that there's no gap, things work as expected.

Surely this is not the right solution but atleast something.
Comment 16 G Karunakar 2018-02-16 14:43:40 UTC
Character U+093F Devanagari Vowel Sign I is where it breaks.
In visual order the glyph for this character shows before the consonant it is placed after.

हिंदी   ह ि ं द ी
Comment 17 QA Administrators 2019-02-17 03:44:11 UTC
** Please read this message in its entirety before responding **

To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year.

There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present.

If you have time, please do the following:

Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/

If the bug is present, please leave a comment that includes the information from Help - About LibreOffice.
If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice.

Please DO NOT

Update the version field
Reply via email (please reply directly on the bug tracker)
Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not 
appropriate in this case)

If you want to do more to help you can test to see if your issue is a REGRESSION. To do so:
1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from http://downloadarchive.documentfoundation.org/libreoffice/old/

2. Test your bug
3. Leave a comment with your results.
4a. If the bug was present with 3.3 - set version to 'inherited from OOo';
4b. If the bug was not present in 3.3 - add 'regression' to keyword

Feel free to come ask questions or to say hello in our QA chat: https://kiwiirc.com/nextclient/irc.freenode.net/#libreoffice-qa

Thank you for helping us make LibreOffice even better for everyone!

Warm Regards,
QA Team