Bug 65124 - EDITING: Hebrew text with commas is misplaced when using Hebrew-only fonts
Summary: EDITING: Hebrew text with commas is misplaced when using Hebrew-only fonts
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: Other Windows (All)
: high major
Assignee: Maxim Monastirsky
URL:
Whiteboard: BSA target:4.2.0
Keywords:
Depends on:
Blocks: RTL-Hebrew
  Show dependency treegraph
 
Reported: 2013-05-29 10:57 UTC by Maxim Monastirsky
Modified: 2017-11-29 22:46 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments
test document + screenshot (96.84 KB, application/zip)
2013-05-29 10:57 UTC, Maxim Monastirsky
Details
Second test-case (8.00 KB, application/vnd.oasis.opendocument.text)
2013-07-30 05:24 UTC, Maxim Monastirsky
Details
Screenshot of the second test-case, that shows the bug (87.21 KB, image/png)
2013-07-30 05:25 UTC, Maxim Monastirsky
Details
Screenshot from Linux (This is how it should be) (54.42 KB, image/png)
2013-07-30 05:30 UTC, Maxim Monastirsky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Maxim Monastirsky 2013-05-29 10:57:29 UTC
Created attachment 79951 [details]
test document + screenshot

Problem description: Adding a comma into Hebrew text with diacritics causes display corruption. The same happens when opening previously saved document with such content (doesn't matter in which format it was saved).

It's a Windows-only bug, and not a recent one - I remember this happening back in early OOo 3.x days.

After some research I've found that this happens only with fonts which don't contain the letter 'b' (LATIN SMALL LETTER B) (In fact they don't contain any Latin letters, because they're Hebrew-only fonts). So it's seems that LO have a check for that letter anywhere in the code.

After adding that letter to the font (even an empty one), this bug goes away. You can add an empty character to a font using FontForge by selecting the letter 'b' and going through Metrics->Set Both Bearing. Unfortunately this can't be done with non-free fonts due to legal restrictions, making them unusable with LO.

I'm attaching a test document + screenshot of the bug. You can get the font that used from: http://culmus.sourceforge.net/fancy/dorian.tar.gz
Operating System: Windows 7
Version: 4.0.3.3 release
Comment 1 Maxim Monastirsky 2013-07-30 05:22:41 UTC
Changed Summary to a more descriptive one. Also it reflects my latest finding, that actually there is no need to add diacritics in order to trigger this bug, only Hebrew text with commas needed (don't know how I missed that...). I'll attach a second (simpler) test case that reflects that.

By the way, the latest Apache OO release (4.0) doesn't suffer from this issue (verified on Windows 7 32-bit), as opposite to previous releases that behave like the current LO, so it might be helpful to check their code and see what they changed.
Comment 2 Maxim Monastirsky 2013-07-30 05:24:02 UTC
Created attachment 83266 [details]
Second test-case
Comment 3 Maxim Monastirsky 2013-07-30 05:25:56 UTC
Created attachment 83267 [details]
Screenshot of the second test-case, that shows the bug
Comment 4 Maxim Monastirsky 2013-07-30 05:30:55 UTC
Created attachment 83268 [details]
Screenshot from Linux (This is how it should be)
Comment 5 dehcjam 2013-10-22 12:08:24 UTC
The bug is still there in version 4.1.2.3 (Windows version)
Comment 6 Maxim Monastirsky 2013-10-22 12:21:58 UTC
(In reply to comment #5)
> The bug is still there in version 4.1.2.3 (Windows version)
Indeed, and also in Version: 4.2.0.0.alpha0+
Build ID: cc2a405915e82c4b332dd25457f76704dc536d7f
TinderBox: Win-x86@39, Branch:master, Time: 2013-10-15_15:51:52
Comment 7 Commit Notification 2013-11-18 19:24:02 UTC
Maxim Monastirsky committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=7cbf4629eadfe0f3da611ee0430a3ab6f2bd33ff

fdo#65124 define HAVE_FMERGENEUTRALITEMS for MSVC build



The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds
Affected users are encouraged to test the fix and report feedback.
Comment 8 Maxim Monastirsky 2013-11-20 11:51:43 UTC
Reopening since the above commit fixes the bug only for Windows 7, while Windows XP is still affected. Probably because fMergeNeutralItems introduced in Vista.
Comment 9 Joel Madero 2014-11-02 16:22:34 UTC
Maxim - can we assign this bug to you? Else it would be nice to close this as FIXED and open a new bug report for Windows XP only. We only use REOPENED for bugs that are currently assigned to developers.
Comment 10 Maxim Monastirsky 2014-11-02 18:10:51 UTC
(In reply to Joel Madero from comment #9)
> Maxim - can we assign this bug to you? Else it would be nice to close this
> as FIXED and open a new bug report for Windows XP only.
Let's close this one, since I'm probably not going to work on it anymore. I don't even know whether it's still reproducible under XP.