Closed Bug 1011369 Opened 11 years ago Closed 6 years ago

Implement line-break property of CSS3 Text

Categories

(Core :: Layout: Text and Fonts, enhancement, P3)

enhancement

Tracking

()

RESOLVED FIXED
mozilla69
Tracking Status
firefox69 --- fixed

People

(Reporter: m_kato, Assigned: jfkthame)

References

(Blocks 2 open bugs, )

Details

(Keywords: css3, dev-doc-needed, Whiteboard: [layout:backlog:2019q3:69][wptsync upstream])

Attachments

(6 files)

WebKit/Blink and Trindent are implemented, but it has no property in Gecko.
Keywords: css3
(Bugs about implementing new CSS properties are usually filed in "CSS Parsing and Computation", so moving it there for consistency.)
Severity: normal → enhancement
Component: Layout: Text → CSS Parsing and Computation
(In reply to Mats Palmgren (:mats) from comment #1) > (Bugs about implementing new CSS properties are usually filed in "CSS > Parsing and Computation", so moving it there for consistency.) Really? I'd keep it in the component where the bulk of the code would live. And the CSS side here is trivial.
Component: CSS Parsing and Computation → Layout: Text
My mistake then; I thought it was the established practice for bugs that adds new CSS properties.
Blocks: css3test
Although, I am migrating ICU into m-c (by some bugs for ECMA-402 support), ICU has this line-break rule now http://www.icu-project.org/trac/changeset/37037
FYI, Blink is going to unprefix 'line-break' property (actually, we had, accidentally, now trying to be official.) mkwst@ suggested we should update our status here, hope this info can be any help for you. Intent to Ship: Unprefix CSS 'line-break' property https://groups.google.com/a/chromium.org/d/msg/blink-dev/RHeWSxMIVK8/g5NJgZo9AQAJ
It would be good to not have this random incompatibility. Makoto-san, do you happen to have an idea of how much work this is to implement?
Flags: needinfo?(m_kato)
(In reply to Boris Zbarsky [:bz] (vacation until 7/7) from comment #6) > It would be good to not have this random incompatibility. > > Makoto-san, do you happen to have an idea of how much work this is to > implement? If we can keep our current line breaker rule that isn't same as UAX#14, it isn't difficult. If line-break property need additional rule again our rule. If we require this on 57 or 58, I will start the implementation. If we have to change it to UAX#14 based, it isn't easy. One is file size (+3MB with ICU's rule), and others are compatibility against old Gecko. File size is critical for mobile team and we don't use ICU on Fennec's release channel yet.
Flags: needinfo?(m_kato)
> If we require this on 57 or 58, I will start the implementation I don't know that we have a target for this yet. 57 is probably not realistic no matter what, but "sometime in the nearish future" might be nice if everyone else is shipping this....
I wonder if it's possible to base this on the xi-unicode library that Servo is also using to implement line breaking. Looks like bug 1290022 is investigating the possibility.
Priority: -- → P3
Blocks: 1358019

Depends on D30788

Whiteboard: [layout:backlog:2019q3:69]

Just FTR, I plan to land this (along with bug 1531715) after the mozilla-68 soft freeze is over.

Assignee: nobody → jfkthame
Pushed by jkew@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e7b525e15531 Add parsing of the loose|normal|strict values of the CSS line-break property. r=emilio https://hg.mozilla.org/integration/autoland/rev/f339909acbc3 Pass word-break and line-break properties to the line-breaker as two distinct enum class parameters. r=m_kato https://hg.mozilla.org/integration/autoland/rev/436e3199c386 Implement loose|normal|strict line-break values by remapping the linebreak class of affected characters. r=m_kato https://hg.mozilla.org/integration/autoland/rev/2607e7773ed5 Restrict some line-break behaviors to Chinese and Japanese contexts, as per spec. r=m_kato https://hg.mozilla.org/integration/autoland/rev/b695489a68c4 Reduce the available width slightly in line-break-loose-017a because a couple of the target characters may be less then .2em wide. r=m_kato https://hg.mozilla.org/integration/autoland/rev/43952b7f9de8 Update metadata for WPT tests that now pass. r=m_kato
Created web-platform-tests PR https://github.com/web-platform-tests/wpt/pull/16924 for changes under testing/web-platform/tests
Whiteboard: [layout:backlog:2019q3:69] → [layout:backlog:2019q3:69][wptsync upstream]
Upstream web-platform-tests status checks passed, PR will merge once commit reaches central.

WPT lacked a number of tests for this feature. The coverage has now been completed, and firefox fails some of them.

New tests introduced by: https://github.com/web-platform-tests/wpt/pull/18000

I filed bug 1568219 to track those failures.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: