Bug 95836 - Vertical text punctuation position is wrong in Japanese (only on Windows 7)
Summary: Vertical text punctuation position is wrong in Japanese (only on Windows 7)
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: graphics stack (show other bugs)
Version:
(earliest affected)
5.0.0.2 rc
Hardware: All Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:5.3.0
Keywords: bibisected, bisected, regression
Depends on: HarfBuzz
Blocks: CJK
  Show dependency treegraph
 
Reported: 2015-11-15 14:59 UTC by Jun Nogata
Modified: 2016-11-06 18:34 UTC (History)
9 users (show)

See Also:
Crash report or crash signature:


Attachments
Screenshot LibO 5.0.3.2 (104.17 KB, image/png)
2015-11-15 14:59 UTC, Jun Nogata
Details
Screenshot LibO 5.0.1 (104.41 KB, image/png)
2015-11-15 15:00 UTC, Jun Nogata
Details
Vertical Text Sample (8.78 KB, application/vnd.oasis.opendocument.text)
2015-11-15 15:01 UTC, Jun Nogata
Details
Screenshot of a fresh master build, with additional fonts installed. (68.54 KB, image/png)
2015-12-03 10:25 UTC, How can I remove my account?
Details
Screenshot of a 5.0.1 branch build, with additional fonts installed. (64.88 KB, image/png)
2015-12-03 10:26 UTC, How can I remove my account?
Details
Screenshot LibreOffice master on Windows 7 (96.39 KB, image/png)
2015-12-05 02:36 UTC, Tomofumi Yagi
Details
Screenshot LibreOffice master on Windows 10 (96.40 KB, image/png)
2015-12-05 02:38 UTC, Tomofumi Yagi
Details
Another sample with Chinese brackets. (19.47 KB, application/vnd.oasis.opendocument.text)
2015-12-14 15:35 UTC, Mark Hung
Details
Side by side comparison of LO4.4 and LO5.0.3.2 (44.98 KB, image/png)
2015-12-14 15:44 UTC, Mark Hung
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Jun Nogata 2015-11-15 14:59:36 UTC
Created attachment 120557 [details]
Screenshot LibO 5.0.3.2

Problem:
Vertical text punctuation position should be in the upper right corner. However, it is at the lower left. In all the Japanese font.

Steps:

Set Locale options (tools->option)
* Language of
  * Locale setting: Japanese
* Default Languages for Documents
  * Asian: Enable and Japanese

1) Set Text direction horizontal to vertical

Open Menu Format->Page, Select Page Tab
Change Text direction "Left-to-right(horizontal)" to "Right-to-left(vertical)"

2) Copy "今日は、晴れだった。" and paste it (or open sample.odt)

Actual results:

Punctuation is displayed in the lower left.

Reference:
* http://www.slideshare.net/naruoga/vertical-writing-typical-usecases-and-current-status-in-libreoffice/13
* http://www.w3.org/TR/jlreq/#positioning_of_punctuation_marks

Environment:
* Windows 7 64bit (only on Windows 7, does not Windows 8.1 or later.)
* Version: 5.0.2.2 or later. (5.0.3.2 / 5.1.0.0 alpha1)
Comment 1 Jun Nogata 2015-11-15 15:00:24 UTC
Created attachment 120558 [details]
Screenshot LibO 5.0.1
Comment 2 Jun Nogata 2015-11-15 15:01:04 UTC
Created attachment 120559 [details]
Vertical Text Sample
Comment 3 Buovjaga 2015-11-15 18:39:38 UTC
Yep, it's ok in 4.3 for me.

Win 7 Pro 64-bit, Version: 5.0.3.2 (x64)
Build ID: e5f16313668ac592c1bfb310f4390624e3dbfb75
Locale: fi-FI (fi_FI)

Version: 5.1.0.0.alpha1+
Build ID: b216cc1b8096eb60c27f67e8c27b7cd756c75e38
TinderBox: Win-x86@62-merge-TDF, Branch:MASTER, Time: 2015-11-12_00:06:20
Locale: fi-FI (fi_FI)
Comment 4 raal 2015-11-18 14:01:03 UTC
This seems to have begun at the below commit.
Adding Cc: to Tor Lillqvist ; Could you possibly take a look at this one? Thanks
 7f0371ad242095657660bb4862bcdfa4a28b4e2c is the first bad commit
commit 7f0371ad242095657660bb4862bcdfa4a28b4e2c
Author: Norbert Thiebaud <nthiebaud@gmail.com>
Date:   Tue Aug 11 23:27:51 2015 -0700

    source 4667db065d34193d99bce82f7e8f3b20a03ecade

    source 4667db065d34193d99bce82f7e8f3b20a03ecade
author	Tor Lillqvist <tml@collabora.com>	2015-08-12 05:18:50 (GMT)
committer	Tor Lillqvist <tml@collabora.com>	2015-08-12 06:14:20 (GMT)
commit 4667db065d34193d99bce82f7e8f3b20a03ecade (patch)
Drop SimpleWinLayout

bibisect-win32-5.1
$ git bisect log
# bad: [7af0dacdc70e7e8bd0785ab0be6e6ca64b64d08d] source 8bde421ccec9c10fe1382ad68485852889dd4c74
# good: [c1efd324c6ad448ac9edb030dc9738b9e6899e4d] source ab465b90f6c6da5595393a0ba73f33a1e71a2b65
git bisect start '7af0dacdc70e7e8bd0785ab0be6e6ca64b64d08d' 'c1efd324c6ad448ac9edb030dc9738b9e6899e4d'
# good: [3f6a85ce123f4e0c065f1c28b02f66dc7734cc04] source 647b5aecd4c3facc302df33386451dda732aab98
git bisect good 3f6a85ce123f4e0c065f1c28b02f66dc7734cc04
# bad: [ef24bd27bb60c92140bf2f76403298d08f668abb] source f7dc03f666954b741b90c5021704249a4f76ed7b
git bisect bad ef24bd27bb60c92140bf2f76403298d08f668abb
# bad: [1074e6af309c093868bbf5caf9cf297a5b48d166] source df7fbad544679999c9635fc441571a0b52826d60
git bisect bad 1074e6af309c093868bbf5caf9cf297a5b48d166
# bad: [2a7daa76d03d68368b39c1709728c1e4fd6e01d8] source 79fb61efb847405fa47235002b52ee8efad5e339
git bisect bad 2a7daa76d03d68368b39c1709728c1e4fd6e01d8
# bad: [24e237f925572f95026b6b80a3f8a3f8b81455f5] source 7985e5245a57b284e370faccffcaab47ba137f3f
git bisect bad 24e237f925572f95026b6b80a3f8a3f8b81455f5
# bad: [1a8003c2229ad845320d5dad411a91972ad5bd42] source 8aaee352aa39e624d2386d9b483855cd8069bff5
git bisect bad 1a8003c2229ad845320d5dad411a91972ad5bd42
# bad: [b3df4d951824fa01f9ef5ee4bce6a9a15c494666] source 2d4edd7de2e67db5bd17e7a89e2496611ebcc165
git bisect bad b3df4d951824fa01f9ef5ee4bce6a9a15c494666
# bad: [404b6fbf05583252758261abc7ef328ef283ea14] source 59b5e3faeb0564023e99f4e7298eb9cbb0bdc75f
git bisect bad 404b6fbf05583252758261abc7ef328ef283ea14
# good: [b51adb834fc032eed77270683e8035d402f6932a] source f6595f0b3389ffeefa10035d915a884b02d26c0e
git bisect good b51adb834fc032eed77270683e8035d402f6932a
# bad: [c09504d6242d5c16aa8cc4bd0169788ef7b6d5d9] source 5975874141148e9f7199eca3a82735fccd7cf150
git bisect bad c09504d6242d5c16aa8cc4bd0169788ef7b6d5d9
# good: [4c1f4b142e3895f02567094986b0b57ad7df0e50] source 1e4b29e1ad16e908f550eae035c3fae8e56831dd
git bisect good 4c1f4b142e3895f02567094986b0b57ad7df0e50
# bad: [7f0371ad242095657660bb4862bcdfa4a28b4e2c] source 4667db065d34193d99bce82f7e8f3b20a03ecade
git bisect bad 7f0371ad242095657660bb4862bcdfa4a28b4e2c
# good: [f8f8bdf24f7fc2f76810d36c4e1ce0e808c9509e] source 695cec87d73d56617e1cdc62621971ab35ac67eb
git bisect good f8f8bdf24f7fc2f76810d36c4e1ce0e808c9509e
# first bad commit: [7f0371ad242095657660bb4862bcdfa4a28b4e2c] source 4667db065d34193d99bce82f7e8f3b20a03ecade
Comment 5 How can I remove my account? 2015-12-01 15:49:40 UTC
This seems to be fixed now in the master, 5.1 and 5.0 branches? Can anybody reproduce with a fresh build?
Comment 6 raal 2015-12-01 21:06:21 UTC
(In reply to Tor Lillqvist from comment #5)
> This seems to be fixed now in the master, 5.1 and 5.0 branches? Can anybody
> reproduce with a fresh build?

Hello, it's correct on linux Version: 5.2.0.0.alpha0+
Build ID: e963e4788d4d4a493e02d3f6c4b1024f3091c502
Threads 4; Ver: 4.2; Render: default; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2015-11-28_00:26:06
but I can still repro on windows7 Version: 5.2.0.0.alpha0+ (x64)
Build ID: e7c78e67292ad93c6a4a0772d8b06a0e6e7d26c8
Threads 1; Ver: Windows 6.1; Render: default; 
TinderBox: Win-x86_64@62-TDF, Branch:MASTER, Time: 2015-11-30_22:37:14
Comment 7 How can I remove my account? 2015-12-01 21:09:22 UTC
I know it is correct on Linux. This was/is a Windows-only problem.
Comment 8 How can I remove my account? 2015-12-02 14:11:09 UTC
Actually, when I test a very fresh master build in Linux myself, I see the problem. The full stop character is in the bottom left corner of the character cell.
Comment 9 How can I remove my account? 2015-12-02 14:14:03 UTC
Also, I definitely do see the problem also on Windows 8.1 and Windows 10. (I don't have any Windows 7.)
Comment 10 How can I remove my account? 2015-12-02 15:52:04 UTC
The symptoms are the same on Windows, Linux and OS X, but as the underlaying text layout code is different for each platform, and that likely is where the bug(s) are, should separate bug reports be filed for each? After all, it is very likely that three separate fixes are needed.
Comment 11 How can I remove my account? 2015-12-02 19:12:46 UTC
By the way, what did the bug reporter mean, exactly, with "does not Windows 8.1 or later"? Did the bug not show up with the same LibreOffice version on Windows 8.1?
Comment 12 How can I remove my account? 2015-12-03 09:59:13 UTC
I built LO from the 5.0.1 branch, and I see the bug. Weird.
Comment 13 How can I remove my account? 2015-12-03 10:17:11 UTC
Ha, but after installing additional fonts for CJK languages, I realise that whether I see the bug or not depends on what fonts I have installed. So could we actually resolve this as WORKSFORME?
Comment 14 How can I remove my account? 2015-12-03 10:25:50 UTC
Created attachment 120986 [details]
Screenshot of a fresh master build, with additional fonts installed.
Comment 15 How can I remove my account? 2015-12-03 10:26:33 UTC
Created attachment 120987 [details]
Screenshot of a 5.0.1 branch build, with additional fonts installed.
Comment 16 How can I remove my account? 2015-12-03 14:01:59 UTC
And also in the 5.0 and 5.1 branches I see it working fine now that I have more fonts installed.
Comment 17 Tomofumi Yagi 2015-12-05 02:33:55 UTC
I've reproduced this problem on Windows 7(x86_64) with latest master build.
Build ID: a027ed9573858f3ec6361577ff541d7f2495bd32
Locale: ja-JP (ja.UTF-8)

But I couldn't reproduced this problem on Windows 10(x86_64) .
Build ID: a027ed9573858f3ec6361577ff541d7f2495bd32
Locale: ja-JP (ja.UTF-8)
Comment 18 Tomofumi Yagi 2015-12-05 02:36:35 UTC
Created attachment 121028 [details]
Screenshot LibreOffice master on Windows 7
Comment 19 Tomofumi Yagi 2015-12-05 02:38:25 UTC
Created attachment 121029 [details]
Screenshot LibreOffice master on Windows 10
Comment 20 Buovjaga 2015-12-05 11:42:21 UTC
Tomofumi: so did you install more fonts like Tor?
Btw. this shouldn't be kept in REOPENED in any case as it is reserved for when FIXED issues didn't get fixed.
Comment 21 Tomofumi Yagi 2015-12-05 13:18:52 UTC
(In reply to Beluga from comment #20)
> Tomofumi: so did you install more fonts like Tor?

No. 
Because I use Windows 7 Japanese version.
That has many preinstalled fonts for Japanese language(MS P明朝, MS明朝, MS Pゴシック, MSゴシック, メイリオ,etc.).
I've reproduced this bug with those fonts.


> Btw. this shouldn't be kept in REOPENED in any case as it is reserved for
> when FIXED issues didn't get fixed.

Sorry for my mistake.
Which status should I set?
Comment 22 Buovjaga 2015-12-05 13:23:14 UTC
(In reply to Tomofumi Yagi from comment #21)
> (In reply to Beluga from comment #20)
> > Tomofumi: so did you install more fonts like Tor?
> 
> No. 
> Because I use Windows 7 Japanese version.
> That has many preinstalled fonts for Japanese language(MS P明朝, MS明朝, MS
> Pゴシック, MSゴシック, メイリオ,etc.).
> I've reproduced this bug with those fonts.
> 
> 
> > Btw. this shouldn't be kept in REOPENED in any case as it is reserved for
> > when FIXED issues didn't get fixed.
> 
> Sorry for my mistake.
> Which status should I set?

NEW, but let's wait for Tor's opinion.
Comment 23 Tomofumi Yagi 2015-12-05 13:44:09 UTC
(In reply to Beluga from comment #22)
> > Which status should I set?
> 
> NEW, but let's wait for Tor's opinion.

Thanks.
Comment 24 Buovjaga 2015-12-06 09:20:08 UTC
Tor said on IRC to set this to NEW after all :)
Comment 25 How can I remove my account? 2015-12-06 09:56:47 UTC
But note that that doesn't imply I would have any time allocated to work on it any more.
Comment 26 Robinson Tryon (qubit) 2015-12-13 11:14:25 UTC Comment hidden (obsolete)
Comment 27 Mark Hung 2015-12-14 15:35:28 UTC
Created attachment 121296 [details]
Another sample with Chinese brackets.
Comment 28 Mark Hung 2015-12-14 15:44:04 UTC
Created attachment 121297 [details]
Side by side comparison of LO4.4 and LO5.0.3.2

From uploaded image, you can observe that in LO5.0.3.2 it simply put what is in horizontal into vertical. However vertical substitution of the glyph should have been used.

Note I only use default fonts in the sample (Microsoft JhengHei,DFKai-SB,MingLiU,PMingLiU for Chinese and MS Gothic, MS Mincho, MS P Gothic, and MS P Mincho for Japanese ).  Since it work properly in LO4.4 without more fonts installed, I don't think "Install more fonts" are right solution.
Comment 29 Björn Michaelsen 2016-03-26 10:55:06 UTC
see also bugs 94597, 95194: regressions caused by the same commit.
Comment 30 Tomofumi Yagi 2016-03-28 16:04:44 UTC
I seem that this bug was fixed.
I can't reproduce this bug in LibreOffice 5.1.1.3 on Windows 7.

But I can reproduce this bug in LibreOffice 5.1.0.3 and 5.0.5.2.
Comment 31 Tomofumi Yagi 2016-03-29 14:57:10 UTC
(In reply to Tomofumi Yagi from comment #30)
> I seem that this bug was fixed.
> I can't reproduce this bug in LibreOffice 5.1.1.3 on Windows 7.
> 
> But I can reproduce this bug in LibreOffice 5.1.0.3 and 5.0.5.2.

This commit had resolved the problem.

https://gerrit.libreoffice.org/gitweb?p=core.git;a=commit;h=4622689fad7ddff72cd08da9611ccfacdb0aa7bd

tdf#96420: Re-introduce SimpleWinLayout
Comment 32 Buovjaga 2016-03-29 15:10:36 UTC
Ok, marking as FIXED as we know the commit.
Comment 33 Mark Hung 2016-11-04 16:50:30 UTC
Khaled,

Check attachment #8, now it rotated incorrectly again.
Comment 34 V Stuart Foote 2016-11-04 17:44:57 UTC
(In reply to Mark Hung from comment #33)
> Khaled,
> 
> Check attachment #8, now it rotated incorrectly again.

@Mark, a new bug would have been better. Resetting version here to 5.0.0.2, and closing.
Comment 35 V Stuart Foote 2016-11-04 17:53:05 UTC
@Mark H. submitted bug 103710, please comment there with any additional details about your build of LO.