Closed
Bug 1336266
Opened 7 years ago
Closed 9 months ago
Firefox fails to break lines for latin words joined by fullwidth comma
Categories
(Core :: Layout: Text and Fonts, defect, P3)
Tracking
()
RESOLVED
DUPLICATE
of bug 1719535
People
(Reporter: arthur200126, Unassigned)
References
()
Details
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:53.0) Gecko/20100101 Firefox/53.0 Build ID: 20170131004003 Steps to reproduce: <div style="width:5em;background:lightgreen;color:black"> <p>XA111,XA5,XA23 <p>你,我蛤,好 </div> Actual results: Firefox is unable to break lines at fullwidth commas. (And lang="zh" doesn't help.) Expected results: Firefox should have considered these line-break opportunities.
Component: Activity Streams: General → Layout: Text
OS: Unspecified → Windows 10
Product: Firefox → Core
Hardware: Unspecified → x86_64
Updated•7 years ago
|
Priority: -- → P3
Comment 1•7 years ago
|
||
:masayuki, would you agree fullwidth punctuation like this should be treated as a line-break opportunity? It seems reasonable to me but I'm not sure offhand if there are any rules/standards that we should check...
Flags: needinfo?(masayuki)
Reporter | ||
Comment 2•7 years ago
|
||
Not masayuki here, but I believe line-breaking at punctuations is fine and actually preferred as long as Firefox follows the prohibition rules (don't leave an open paren hanging at the end; don't start a line with a comma, this kind of stuff).
Comment 3•7 years ago
|
||
Unicode defines "," and "." as: FF0C;FULLWIDTH COMMA;Po;0;CS;<wide> 002C;;;;N;;;;; FF0E;FULLWIDTH FULL STOP;Po;0;CS;<wide> 002E;;;;N;FULLWIDTH PERIOD;;;; I think that it's reasonable to treated "," and "." as "Punctuation that prohibits break before" since glyph for them typically includes enough space at left-half of the em-square. (I'm not sure about the other full-width punctuation line ")", "?", etc. https://searchfox.org/mozilla-central/rev/1a4a26905f923458679a59a4be1e455ebc53c333/intl/lwbrk/nsJISx4051LineBreaker.cpp#317 https://www.unicode.org/charts/PDF/UFF00.pdf So, perhaps, treating them as ", " and ". " (i.e., followed by ASCII whitespace) shows better result. Kimura-san and Makoto-san, if you have some opinions, let us know. (Although, it might be not enough to treat them as "Punctuation that prohibits break before" in conservative mode (like the test case). See https://searchfox.org/mozilla-central/rev/1a4a26905f923458679a59a4be1e455ebc53c333/intl/lwbrk/nsJISx4051LineBreaker.cpp#254 )
Flags: needinfo?(masayuki)
Comment 4•7 years ago
|
||
FYI: Currently, some full width characters (less than U+FF60) are treated as ASCII characters: https://searchfox.org/mozilla-central/rev/1a4a26905f923458679a59a4be1e455ebc53c333/intl/lwbrk/nsJISx4051LineBreaker.cpp#438-440 (Although, I guess it should be less than U+FF5F?) So, currently, they must be treated as "Close parenthese (or punctuations) like Character".
Comment 5•7 years ago
|
||
Per <https://www.unicode.org/Public/UNIDATA/LineBreak.txt>, > FF0C;CL # Po FULLWIDTH COMMA > FF0E;CL # Po FULLWIDTH FULL STOP And per <http://www.unicode.org/reports/tr14/>, > CL Close Punctuation “}”, “❳”, “⟫” etc. Prohibit line breaks before
Updated•2 years ago
|
Severity: normal → S3
Comment 6•9 months ago
|
||
This is fixed by bug 1719535.
Status: UNCONFIRMED → RESOLVED
Closed: 9 months ago
Duplicate of bug: 1719535
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•