Closed
Bug 752459
Opened 12 years ago
Closed 12 years ago
word-wrap:break-word should not break up base+diacritic clusters or surrogate pairs
Categories
(Core :: Layout: Text and Fonts, defect)
Tracking
()
RESOLVED
FIXED
mozilla15
People
(Reporter: jfkthame, Assigned: jfkthame)
Details
Attachments
(2 files)
1.31 KB,
patch
|
smontagu
:
review+
|
Details | Diff | Splinter Review |
2.17 KB,
patch
|
smontagu
:
review+
|
Details | Diff | Splinter Review |
The word-wrap:break-word property (being renamed to overflow-wrap in CSS3 Text) inappropriately causes breaks between a base character and its applied diacritics, and (even worse) breaks between the two code units of a surrogate pair. Testcase: data:text/html;charset=utf-8, <div style="width:0px;word-wrap:break-word">abc d̥e̕f̣
Assignee | ||
Comment 1•12 years ago
|
||
Argh, I forgot bugzilla would truncate my text as soon as it encountered a surrogate codepoint. Trying again.... data:text/html;charset=utf-8, <div style="width:0px;word-wrap:break-word">abc d̥e̕f̣ %F0%90%90%80%F0%90%90%81%F0%90%90%82 Note the "blank" lines between the Deseret letters, because internally we split the low surrogate onto a separate line. (The fact that they're split across lines can be demonstrated by drag-selecting one of the Deseret glyphs (or hexboxes), *or* one of the invisible blanks in between them, and copy-pasting it into the search box - you get just the single, unpaired surrogate codepoint.)
Assignee | ||
Comment 2•12 years ago
|
||
It looks like this can be trivially fixed, actually - we just need to check whether the current character is a cluster start when considering a possible breakpoint for word-wrap:break-word.
Assignee: nobody → jfkthame
Attachment #621571 -
Flags: review?(smontagu)
Assignee | ||
Comment 3•12 years ago
|
||
Attachment #621572 -
Flags: review?(smontagu)
Updated•12 years ago
|
Attachment #621571 -
Flags: review?(smontagu) → review+
Updated•12 years ago
|
Attachment #621572 -
Flags: review?(smontagu) → review+
Assignee | ||
Comment 4•12 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/9b57d5c5a713 https://hg.mozilla.org/integration/mozilla-inbound/rev/88c5fc8ffd6c
Target Milestone: --- → mozilla15
Comment 5•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/9b57d5c5a713 https://hg.mozilla.org/mozilla-central/rev/88c5fc8ffd6c
Status: NEW → RESOLVED
Closed: 12 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•