Skip to content

Commit 1d6e793

Browse files
committed
[css-shapes] change basic shape syntax description to prose
1 parent 4d106d9 commit 1d6e793

File tree

2 files changed

+67
-53
lines changed

2 files changed

+67
-53
lines changed

css-shapes/Overview.html

+39-36
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
rel=dcterms.rights>
1313
<meta content="CSS Shapes Module Level 1" name=dcterms.title>
1414
<meta content=text name=dcterms.type>
15-
<meta content=2013-09-24 name=dcterms.date>
15+
<meta content=2013-09-27 name=dcterms.date>
1616
<meta content="Vincent Hardy" name=dcterms.creator>
1717
<meta content="Rossen Atanassov" name=dcterms.creator>
1818
<meta content="Alan Stearns" name=dcterms.creator>
@@ -51,7 +51,7 @@
5151

5252
<h1 id=css-shapes-module>CSS Shapes Module Level 1</h1>
5353

54-
<h2 class="no-num no-toc" id=longstatus-date>Editor's Draft 24 September
54+
<h2 class="no-num no-toc" id=longstatus-date>Editor's Draft 27 September
5555
2013</h2>
5656

5757
<dl>
@@ -435,69 +435,72 @@ <h3 id=basic-shapes-from-svg-syntax><span class=secno>3.2. </span>Basic
435435
<h4 id=supported-basic-shapes><span class=secno>3.2.1. </span>Supported
436436
Shapes</h4>
437437

438-
<p>The following basic shapes are supported.
438+
<p>The following basic shapes are supported. All basic shapes use
439+
functional notation following the rules defined in <a
440+
href="http://www.w3.org/TR/css3-values/#functional-notation">CSS Values
441+
and Units</a> <a href="#CSS3VAL"
442+
rel=biblioentry>[CSS3VAL]<!--{{CSS3VAL}}--></a>.
439443

440444
<dl>
441-
<dt><dfn
442-
id=rectangle>rectangle</dfn>([&lt;length&gt;|&lt;percentage&gt;][,
443-
[&lt;length&gt;|&lt;percentage&gt;]]{3,5})
445+
<dt><dfn id=rectangle>rectangle</dfn>() takes either four or six arguments
446+
of &lt;length&gt; or &lt;percentage&gt;
444447

445448
<dd>
446449
<ul>
447-
<li> The first four values represent <strong>x, y, width</strong> and
450+
<li> The first four arguments represent <strong>x, y, width</strong> and
448451
<strong>height</strong> of the rectangle. Negative values for width and
449452
height are invalid.
450453

451-
<li> The last two optional values represent <strong> rx</strong> and
454+
<li> The last two optional arguments represent <strong> rx</strong> and
452455
<strong>ry</strong>. For rounded rectangles they define the x-axis
453456
radius and y-axis radius of the ellipse used to round off the corners
454457
of the rectangle. Negative values for rx and ry are invalid. See notes
455-
below on edge cases for these values.
458+
below on edge cases for these arguments.
456459
</ul>
457460

458-
<dt><dfn
459-
id=inset-rectangle>inset-rectangle</dfn>([&lt;length&gt;|&lt;percentage&gt;][,
460-
[&lt;length&gt;|&lt;percentage&gt;]]{3,5})
461+
<dt><dfn id=inset-rectangle>inset-rectangle</dfn>() takes either four or
462+
six arguments of &lt;length&gt; or &lt;percentage&gt;
461463

462464
<dd>
463465
<ul>
464-
<li> The first four values represent the <strong>top, right,
465-
bottom</strong> and <strong>left</strong> offsets from the content
466-
rectangle inward that define the positions of the edges of the inset
467-
rectangle. Negative values for any of these insets are invalid.
466+
<li> The first four arguments represent the <strong>top, right,
467+
bottom</strong> and <strong>left</strong> offsets from the relevant box
468+
inward that define the positions of the edges of the inset rectangle.
469+
Negative values for any of these insets are invalid.
468470

469-
<li> The last two optional values represent <strong> rx</strong> and
471+
<li> The last two optional arguments represent <strong> rx</strong> and
470472
<strong>ry</strong>. For rounded inset rectangles they define the
471473
x-axis radius and y-axis radius of the ellipse used to round off the
472474
corners of the inset rectangle. Negative values for rx and ry are
473-
invalid. See notes below on edge cases for these values.
475+
invalid. See notes below on edge cases for these arguments.
474476
</ul>
475477

476-
<dt><dfn id=circle>circle</dfn>([&lt;length&gt;|&lt;percentage&gt;][,
477-
[&lt;length&gt;|&lt;percentage&gt;]]{2})
478+
<dt><dfn id=circle>circle</dfn>() takes three arguments of &lt;length&gt;
479+
or &lt;percentage&gt;
478480

479481
<dd>
480482
<ul>
481-
<li> The three values values represent <strong>cx</strong>,
483+
<li> The three arguments represent <strong>cx</strong>,
482484
<strong>cy</strong>, and <strong>r</strong>. They define the x-axis and
483485
y-axis coordinates of the center of the circle and the radius of the
484486
circle. A negative value for r is invalid.
485487
</ul>
486488

487-
<dt><dfn id=ellipse>ellipse</dfn>([&lt;length&gt;|&lt;percentage&gt;][,
488-
[&lt;length&gt;|&lt;percentage&gt;]]{3})
489+
<dt><dfn id=ellipse>ellipse</dfn>() takes four arguments of &lt;length&gt;
490+
or &lt;percentage&gt;
489491

490492
<dd>
491493
<ul>
492-
<li> The four values represent <strong>cx</strong>, <strong>cy</strong>,
493-
<strong>rx</strong>, and <strong>ry</strong>. They define the x-axis
494-
and y-axis coordinates of the center of the ellipse and the x-axis and
495-
y-axis radius of the ellipse. Negative values for rx and ry are
496-
invalid.
494+
<li> The four arguments represent <strong>cx</strong>,
495+
<strong>cy</strong>, <strong>rx</strong>, and <strong>ry</strong>. They
496+
define the x-axis and y-axis coordinates of the center of the ellipse
497+
and the x-axis and y-axis radius of the ellipse. Negative values for rx
498+
and ry are invalid.
497499
</ul>
498500

499-
<dt><dfn
500-
id=polygon>polygon</dfn>([&lt;fill-rule&gt;,]?[&lt;length&gt;|&lt;percentage&gt;]{2}#)
501+
<dt><dfn id=polygon>polygon</dfn>() starts with an optional
502+
&lt;fill-rule&gt; argument, followed by a list of arguments consisting of
503+
&lt;length&gt; or &lt;percentage&gt; pairs.
501504

502505
<dd>
503506
<ul>
@@ -507,7 +510,7 @@ <h4 id=supported-basic-shapes><span class=secno>3.2.1. </span>Supported
507510
property in SVG for details. Possible values are nonzero or evenodd.
508511
Default value when omitted is nonzero.
509512

510-
<li> The two length values represent <strong>xi</strong> and
513+
<li> Each pair argument in the list represents <strong>xi</strong> and
511514
<strong>yi</strong> - the <strong>x</strong> and <strong>y</strong>
512515
axis coordinates of the i-th vertex of the polygon.
513516
</ul>
@@ -518,11 +521,11 @@ <h4 id=supported-basic-shapes><span class=secno>3.2.1. </span>Supported
518521
</dl>
519522

520523
<p>The values for corner radii on rectangle or inset-rectangle are
521-
determined implicitly if either the rx or ry values are not specified, or
522-
are specified but with invalid values. If neither rx nor ry are properly
523-
specified, the values are 0 for both. If only one value is properly
524-
specified, that value is used for both. And if the values cause any of the
525-
curves to overlap, the solution for <a
524+
determined implicitly if either the rx or ry arguments are not specified,
525+
or are specified but with invalid values. If neither rx nor ry are
526+
properly specified, the values are 0 for both. If only one value is
527+
properly specified, that value is used for both. And if the values cause
528+
any of the curves to overlap, the solution for <a
526529
href="http://www.w3.org/TR/css3-background/#corner-overlap">overlapping
527530
curves</a> from CSS Backgrounds and Borders <a href="#CSS3BG"
528531
rel=biblioentry>[CSS3BG]<!--{{!CSS3BG}}--></a> is used to avoid the

css-shapes/Overview.src.html

+28-17
Original file line numberDiff line numberDiff line change
@@ -337,61 +337,67 @@ <h3 id="basic-shapes-from-svg-syntax">Basic Shapes</h3>
337337

338338

339339
<h4 id="supported-basic-shapes">Supported Shapes</h4>
340-
<p>The following basic shapes are supported.
340+
<p>The following basic shapes are supported. All basic shapes use functional notation following the rules defined in <a href="http://www.w3.org/TR/css3-values/#functional-notation">CSS Values and Units</a> [[CSS3VAL]].
341341
<dl>
342-
<dt><dfn id="rectangle">rectangle</dfn>([&lt;length&gt;|&lt;percentage&gt;][, [&lt;length&gt;|&lt;percentage&gt;]]{3,5})</dt>
342+
<dt><dfn id="rectangle">rectangle</dfn>()
343+
takes either four or six arguments
344+
of &lt;length&gt; or &lt;percentage&gt;</dt>
343345
<dd>
344346
<ul>
345347
<li>
346-
The first four values represent
348+
The first four arguments represent
347349
<strong>x, y, width</strong> and
348350
<strong>height</strong>
349351
of the rectangle.
350352
Negative values for width and height are invalid.
351353
</li>
352354
<li>
353-
The last two optional values represent
355+
The last two optional arguments represent
354356
<strong> rx</strong> and <strong>ry</strong>.
355357
For rounded rectangles they define
356358
the x-axis radius and y-axis radius
357359
of the ellipse used to round off
358360
the corners of the rectangle.
359361
Negative values for rx and ry are invalid.
360-
See notes below on edge cases for these values.
362+
See notes below on edge cases for these arguments.
361363
</li>
362364
</ul>
363365
</dd>
364-
<dt><dfn id="inset-rectangle">inset-rectangle</dfn>([&lt;length&gt;|&lt;percentage&gt;][, [&lt;length&gt;|&lt;percentage&gt;]]{3,5})</dt>
366+
<dt><dfn id="inset-rectangle">inset-rectangle</dfn>()
367+
takes either four or six arguments
368+
of &lt;length&gt; or &lt;percentage&gt;</dt>
365369
<dd>
366370
<ul>
367371
<li>
368-
The first four values represent the
372+
The first four arguments represent the
369373
<strong>top, right, bottom</strong> and
370374
<strong>left</strong> offsets
371-
from the content rectangle inward
375+
from the relevant box inward
372376
that define the positions
373377
of the edges
374378
of the inset rectangle.
375379
Negative values for any
376380
of these insets are invalid.
377381
</li>
378382
<li>
379-
The last two optional values represent
383+
The last two optional arguments represent
380384
<strong> rx</strong> and <strong>ry</strong>.
381385
For rounded inset rectangles they define
382386
the x-axis radius and y-axis radius
383387
of the ellipse used to round off
384388
the corners of the inset rectangle.
385389
Negative values for rx and ry are invalid.
386-
See notes below on edge cases for these values.
390+
See notes below on edge cases for these arguments.
387391
</li>
388392
</ul>
389393
</dd>
390-
<dt><dfn id="circle">circle</dfn>([&lt;length&gt;|&lt;percentage&gt;][, [&lt;length&gt;|&lt;percentage&gt;]]{2})</dt>
394+
<dt><dfn id="circle">circle</dfn>()
395+
takes three arguments
396+
of &lt;length&gt; or &lt;percentage&gt;</dt>
391397
<dd>
392398
<ul>
393399
<li>
394-
The three values values represent
400+
The three arguments represent
395401
<strong>cx</strong>,
396402
<strong>cy</strong>,
397403
and <strong>r</strong>.
@@ -402,11 +408,13 @@ <h4 id="supported-basic-shapes">Supported Shapes</h4>
402408
</li>
403409
</ul>
404410
</dd>
405-
<dt><dfn id="ellipse">ellipse</dfn>([&lt;length&gt;|&lt;percentage&gt;][, [&lt;length&gt;|&lt;percentage&gt;]]{3})</dt>
411+
<dt><dfn id="ellipse">ellipse</dfn>()
412+
takes four arguments
413+
of &lt;length&gt; or &lt;percentage&gt;</dt>
406414
<dd>
407415
<ul>
408416
<li>
409-
The four values represent
417+
The four arguments represent
410418
<strong>cx</strong>,
411419
<strong>cy</strong>,
412420
<strong>rx</strong>, and
@@ -419,14 +427,17 @@ <h4 id="supported-basic-shapes">Supported Shapes</h4>
419427
</li>
420428
</ul>
421429
</dd>
422-
<dt><dfn id="polygon">polygon</dfn>([&lt;fill-rule&gt;,]?[&lt;length&gt;|&lt;percentage&gt;]{2}#)</dt>
430+
<dt><dfn id="polygon">polygon</dfn>()
431+
starts with an optional &lt;fill-rule&gt; argument,
432+
followed by a list of arguments consisting of
433+
&lt;length&gt; or &lt;percentage&gt; pairs.</dt>
423434
<dd>
424435
<ul>
425436
<li><strong>fill-rule</strong> - The filling rule used to determine the interior of the
426437
polygon. See <a href="http://www.w3.org/TR/SVG/painting.html#FillRuleProperty">fill-rule</a> property in SVG for details. Possible values are nonzero
427438
or evenodd. Default value when omitted is nonzero.</li>
428439
<li>
429-
The two length values represent <strong>xi</strong> and <strong>yi</strong> -
440+
Each pair argument in the list represents <strong>xi</strong> and <strong>yi</strong> -
430441
the <strong>x</strong> and <strong>y</strong> axis coordinates of the i-th vertex of the polygon.
431442
</li>
432443
</ul>
@@ -440,7 +451,7 @@ <h4 id="supported-basic-shapes">Supported Shapes</h4>
440451
<p>The values for corner radii
441452
on rectangle or inset-rectangle
442453
are determined implicitly
443-
if either the rx or ry values
454+
if either the rx or ry arguments
444455
are not specified,
445456
or are specified but with invalid values.
446457
If neither rx nor ry are properly specified,

0 commit comments

Comments
 (0)