Skip to content

Commit 6c34507

Browse files
author
litherum
committed
[css-fonts-4] "font" shorthand must be updated to incorporate new variation font values
#515
1 parent 1852749 commit 6c34507

1 file changed

Lines changed: 10 additions & 2 deletions

File tree

css-fonts-4/Overview.bs

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -867,7 +867,7 @@ at least as dark as its predecessor. Only values between 1 - 999 are valid, and
867867

868868
<pre class="propdef">
869869
Name: font
870-
Value: [ [ 'font-style' || 'font-variant-css21' || 'font-weight' || 'font-stretch' ]? 'font-size' [ / 'line-height' ]? 'font-family' ] | caption | icon | menu | message-box | small-caption | status-bar
870+
Value: [ [ 'font-style' || 'font-variant-css21' || 'font-weight' || 'font-stretch-css3' ]? 'font-size' [ / 'line-height' ]? 'font-family' ] | caption | icon | menu | message-box | small-caption | status-bar
871871
Initial: see individual properties
872872
Applies to: all elements
873873
Inherited: yes
@@ -884,6 +884,11 @@ at least as dark as its predecessor. Only values between 1 - 999 are valid, and
884884

885885
<pre class="prod"><dfn id="font-variant-css21-values"><var>&lt;font-variant-css21&gt;</var></dfn> = [normal | small-caps]</pre>
886886

887+
Values for the 'font-stretch' property may also be included but only those supported in
888+
CSS Fonts level 3, none of the 'font-stretch' values added in this specification can be used in the 'font' shorthand:
889+
890+
<pre class="prod"><dfn id="font-stretch-css3-values"><var>&lt;font-stretch-css3&gt;</var></dfn> = [normal | ultra-condensed | extra-condensed | condensed | semi-condensed | semi-expanded | expanded | extra-expanded | ultra-expanded]</pre>
891+
887892
The syntax of this property is based on a traditional typographical
888893
shorthand notation to set multiple properties related to fonts.
889894

@@ -905,6 +910,7 @@ at least as dark as its predecessor. Only values between 1 - 999 are valid, and
905910
p { font: bold italic large Palatino, serif }
906911
p { font: normal small-caps 120%/120% fantasy }
907912
p { font: condensed oblique 12pt &quot;Helvetica Neue&quot;, serif; }
913+
p { font: condensed oblique 25deg 753 12pt &quot;Helvetica Neue&quot;, serif; }
908914
</pre>
909915

910916
In the second rule, the font size percentage value ("80%") refers
@@ -923,9 +929,11 @@ at least as dark as its predecessor. Only values between 1 - 999 are valid, and
923929
('fantasy'). It follows that the keyword 'normal' applies to the two
924930
remaining properties: 'font-style' and 'font-weight'.
925931

926-
927932
The sixth rule sets the 'font-style', 'font-stretch', 'font-size', and 'font-family', the other font
928933
properties being set to their initial values.
934+
935+
The seventh rule sets 'font-style' to "oblique 25deg", 'font-weight' to "753", and 'font-stretch' to "condensed".
936+
Note that the "25deg" in this rule must be immediately following the "oblique" keyword.
929937
</div>
930938

931939
Since the 'font-stretch' property was not defined in CSS 2.1, when using 'font-stretch'

0 commit comments

Comments
 (0)