Index: LayoutTests/css3/fonts/font-style-matching.html |
diff --git a/LayoutTests/css3/fonts/font-style-matching.html b/LayoutTests/css3/fonts/font-style-matching.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..bd99ae8f2f31ca5daf5f80b708910a2bb55e6a13 |
--- /dev/null |
+++ b/LayoutTests/css3/fonts/font-style-matching.html |
@@ -0,0 +1,95 @@ |
+<!DOCTYPE html> |
+<html> |
+<meta charset="UTF-8"> |
+<head> |
+ <script type="text/javascript" src="../../http/tests/inspector-protocol/inspector-protocol-test.js"></script> |
+ <script type="text/javascript" src="../../http/tests/inspector-protocol/css-protocol-test.js"></script> |
+ <script type="text/javascript" src="../../http/tests/inspector-protocol/dom-protocol-test.js"></script> |
+ <script type="text/javascript" src="resources/style-matching-test.js"></script> |
+ <!-- available fonts ---> |
+ <style type="text/css"> |
+ </style> |
+ <!-- Applied styles --> |
+ <style type="text/css"> |
+ body { |
+ font-size: 24px; |
+ line-height: 110%; |
+ text-rendering: optimizeLegibility; |
+ font-feature-settings: "liga" 1; |
+ } |
+ |
+ #condensed_normal_100 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: condensed; |
+ font-style: normal; |
+ font-weight: 100; |
+ } |
+ |
+ #condensed_normal_900 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: condensed; |
+ font-style: normal; |
+ font-weight: 900; |
+ } |
+ |
+ #condensed_italic_100 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: condensed; |
+ font-style: italic; |
+ font-weight: 100; |
+ } |
+ |
+ #condensed_italic_900 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: condensed; |
+ font-style: italic; |
+ font-weight: 900; |
+ } |
+ |
+ #expanded_normal_100 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: expanded; |
+ font-style: normal; |
+ font-weight: 100; |
+ } |
+ |
+ #expanded_normal_900 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: expanded; |
+ font-style: normal; |
+ font-weight: 900; |
+ } |
+ |
+ #expanded_italic_100 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: expanded; |
+ font-style: italic; |
+ font-weight: 100; |
+ } |
+ |
+ #expanded_italic_900 { |
+ font-family: CSSMatchingTest; |
+ font-stretch: expanded; |
+ font-style: italic; |
+ font-weight: 900; |
+ } |
+ </style> |
+</head> |
+<body> |
+<pre>According to the CSS3 Fonts Module, Step 4 or the Font Style Matching Algorithm |
+( https://drafts.csswg.org/css-fonts-3/#font-style-matching ) must narrow down the |
+available font faces by finding the nearest match in the following order of |
+precedence: stretch, style, weight. |
+</pre> |
+ <div class="test"> |
+ <div id="condensed_normal_100">abcdefg</div> |
+ <div id="condensed_normal_900">abcdefg</div> |
+ <div id="condensed_italic_100">abcdefg</div> |
+ <div id="condensed_italic_900">abcdefg</div> |
+ <div id="expanded_normal_100">abcdefg</div> |
+ <div id="expanded_normal_900">abcdefg</div> |
+ <div id="expanded_italic_100">abcdefg</div> |
+ <div id="expanded_italic_900">abcdefg</div> |
+ </div> |
+</body> |
+</html> |