[css-shapes-1] Implement rect() function
Categories
(Core :: CSS Parsing and Computation, enhancement)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox117 | --- | fixed |
People
(Reporter: sebo, Assigned: boris)
References
(Blocks 3 open bugs, )
Details
(Keywords: dev-doc-complete)
Attachments
(2 files)
The CSS Shapes 1 specification defines a rect() function to create a rectangular shape as insets from the reference box similar to the inset() function.
This bug is meant to implement that function.
Sebastian
| Assignee | ||
Updated•3 years ago
|
| Assignee | ||
Comment 1•3 years ago
|
||
Note that rect() computes to the equivalent inset() function as well.
i.e. Given rect(t r b l), the equivalent function is
inset(t calc(100% - r) calc(100% - b) l).
The implementation is straightforward, and we don't have to change
anything in cpp because it is always inset() when building the gfx::Path.
The tests for clip-path will be added in the following patch.
| Assignee | ||
Comment 2•3 years ago
|
||
Also, move the interpolation of xywh() into
clip-path-interpolation-xywh-rect.html.
Comment 5•3 years ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/014ccd272ac6
https://hg.mozilla.org/mozilla-central/rev/fbce1db481ca
Comment 7•3 years ago
|
||
| bugherder | ||
MDN doc updates for this feature can be tracked via this issue: https://github.com/mdn/content/issues/28287 (in review).
Thanks Boris for all your help!
Description
•