<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - font-variation-settings at or beyond axis extremes result in the axis reverting to default"
href="https://bugs.webkit.org/show_bug.cgi?id=163790">163790</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>font-variation-settings at or beyond axis extremes result in the axis reverting to default
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr>
<tr>
<th>Product</th>
<td>WebKit
</td>
</tr>
<tr>
<th>Version</th>
<td>WebKit Nightly Build
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Macintosh
</td>
</tr>
<tr>
<th>OS</th>
<td>macOS 10.12
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>Normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P2
</td>
</tr>
<tr>
<th>Component</th>
<td>Text
</td>
</tr>
<tr>
<th>Assignee</th>
<td>webkit-unassigned@lists.webkit.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>lorp@lorp.org
</td>
</tr>
<tr>
<th>CC</th>
<td>mmaxfield@apple.com
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=292357" name="attach_292357" title="HTML (with a bit of PHP) to show how some values close to axis extremes revert to default. The $makesafe variable is a toggle which ensure values are within the range">attachment 292357</a> <a href="attachment.cgi?id=292357&action=edit" title="HTML (with a bit of PHP) to show how some values close to axis extremes revert to default. The $makesafe variable is a toggle which ensure values are within the range">[details]</a></span>
HTML (with a bit of PHP) to show how some values close to axis extremes revert to default. The $makesafe variable is a toggle which ensure values are within the range
Using font-variation-settings beyond axis extremes results in the axis reverting to its default. Sometimes using font-variation-settings *at* axis extremes results in the same undesirable behaviour. Settings at or beyond the extremes should (surely?) be clamped to that extreme.
To replicate the bug, try Skia, which contains the following raw data in the fvar table (min, default, max):
wght: 00007AE1, 00010000, 00033333 = 31457, 65536, 209715
wdth: 00009EB7, 00010000, 00014CCC = 40631, 65536, 85196
These correspond to the extremes, expressed in CSS:
font-variation-settings: 'wght' 0.47999572753906, 'wdth' 0.61997985839844;
font-variation-settings: 'wght' 3.1999969482422, 'wdth' 1.2999877929688;
These settings do not result in expected behaviour. In particular the 'wght' seems to become default. Subtracting 0.0001 from the max weight does not fix the problem, however subtracting 0.01 does fix it. See the difference by using the $makesafe toggle in the attached PHP file.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>