Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion css-shapes-2/Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -147,13 +147,17 @@ The ''shape()'' Function</h4>
and inherits a number of limitations from SVG,
such as implicitly only allowing the ''px'' unit.

The ''shape()'' function uses a set of commands equivalent to the ones used by ''path()'',
The ''shape()'' function uses a set of commands roughly equivalent to the ones used by ''path()'',
but does so with more standard CSS syntax,
and allows the full range of CSS functionality,
such as additional units and math functions.
The commands used by ''shape()'' are dynamically turned into path segments when it is used for rendering,
e.g., when computing the rendered 'clip-path'.

In that sense, ''shape()'' is a superset of ''path()''. A ''path()'' can be easily converted to a ''shape()'',
but to convert a ''shape()'' back to a ''path()'' or to SVG requires information about the CSS environment (e.g.
current values of CSS custom properties, current font size for ''em'' units, etc).

<pre class=prod>
<dfn>shape()</dfn> = shape( <<'fill-rule'>>? from <<position>>, <<shape-command>>#)
</pre>
Expand Down