Bug 97208 - CJK FORMATTING: Indent is set to "2 characters" but paragraph is not indent as two characters
Summary: CJK FORMATTING: Indent is set to "2 characters" but paragraph is not indent a...
Status: RESOLVED DUPLICATE of bug 36709
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-01-17 12:46 UTC by Kevin Suo
Modified: 2016-02-12 01:22 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments
Screenshot (301.07 KB, image/png)
2016-01-17 12:53 UTC, Kevin Suo
Details
Manual indent against 2 ch indent (12.65 KB, application/vnd.oasis.opendocument.text)
2016-01-17 15:02 UTC, Usama
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin Suo 2016-01-17 12:46:04 UTC
For Chinese language, if you set the paragraph indent to "2 characters", the actually paragraph format is not shown as two characters indent. It is shown as two characters indent only if the font size is the default (in my system it's 10.5).

-----

Steps To Reproduce:

1. Make sure character unit is enabled in Settings -> LibreOffice Writer -> General.

2. Copy the following chinese paragraphs into Writer:
'''
关于首行缩进2个汉字的问题:LibreOffice是支持首行以字符缩进的,但是缩进并不是真的按照真的字符,他会把字符强行换算成厘米。只有字体大小是五号的时候才是缩进了两个字符。
举个例子,当字体是小四号的时候,经过测试,当字体是小四的时候,需要把缩进设置成 2.29字符 才会与下一行的第三个字对齐。
'''

3. In paragraph settings, set 'Indent -> First line' to '2.00 ch', OK.
--> Result: Paragraph first line indent is correctly 2 characters only when the font size is 10.5. The indent is not 2 chars when font size is not 10.5.

-------

Reproducible in
Version: 5.1.0.2 (x64)
Build ID: ecd3574d51754b043f865cf5bafee286d24db7cc
CPU Threads: 4; OS Version: Windows 6.19; UI Render: GL; 
Locale: zh-CN (zh_CN)
Win10 x64
Bug also exists in prior versions. May be inheritated from OOo.

The related code may be:
http://cgit.freedesktop.org/libreoffice/core/tree/sw/source/core/text/itrcrsr.cxx

There is a related discussion in the Chinese LibreOffice Discussion Forum:
http://www.libreofficechina.org/thread-1440-1-1.html
Comment 1 Kevin Suo 2016-01-17 12:53:39 UTC
Created attachment 122026 [details]
Screenshot
Comment 2 Kevin Suo 2016-01-17 12:56:00 UTC
Adding bug 64975 as see-also.
The fix of bug 64975 makes *auto* first line indent works as expected, no matter what the font size is.
Comment 3 Usama 2016-01-17 14:38:55 UTC
I've tested it on LO 5.1.0.1 on Ubuntu 15.04.

It seems like the indent is converted from characters "2.00 ch" to "inches" directly after applying. That makes me think that that character indenting is just a mask.

And it's not just with Chinese language.
Comment 4 Usama 2016-01-17 15:02:30 UTC
Created attachment 122034 [details]
Manual indent against 2 ch indent

I've tested the indenting with size 20 font of the T character. When indent is done manually by adding two blank spaces it's perfectly working and looking good. When it's done by the paragraph indent it's not accurate.
Comment 5 Mark Hung 2016-02-11 14:24:58 UTC
Does this duplicate tdf#36709?
Comment 6 Kevin Suo 2016-02-12 01:22:58 UTC

*** This bug has been marked as a duplicate of bug 36709 ***