Skip to content

Commit 3911bf2

Browse files
author
litherum
committed
[css-fonts-4] Automatic optical size/style selection
#807 (comment)
1 parent 209b750 commit 3911bf2

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

css-fonts-4/Overview.bs

+4
Original file line numberDiff line numberDiff line change
@@ -1715,6 +1715,10 @@ at least as dark as its predecessor. Only values between 1 - 999 are valid, and
17151715

17161716
<div id="optical-size-example" class="figure"><img alt="text with different optical sizes, normalized to similar physical sizes" src="Century_Expanded-a-normalized.jpg" /><p class="caption">Each size of Century Expanded as it existed in analog metal form. The different optical sizes, normalized here to the same physical size, have design variations to maintain stylistic traits and improve readability.</p></div>
17171717

1718+
'font-size' must be considered when selection a variation value for the 'opsz' axis, but other signals may also be considered.
1719+
1720+
Note: User Agents are expected to supply a value for the 'opsz' axis which is close to the used value for 'font-size'. However, User Agents may wish to consider other factors such as pixel density of the screen, or the solid angle the text subtends in the viewer's retina. <a href="https://github.com/w3c/csswg-drafts/issues/807#issue-195683688">Experiments have shown</a>, however, that disregarding these other ancillary factors and using only 'font-size' may be the best way for a User Agent to select this value.
1721+
17181722
Pixel density as well as visual size of the text may influence the variation value chosen for 'font-optical-sizing'. When either pixel density or visual size of the text changes in response to a user operation or style change, user agents may choose a new value for this variation value only if the change is layout-causing. User agents are free to determine which changes are layout-causing.
17191723

17201724
Note: Some user operations, such as pinch-zoom, may be considered not-layout-causing if they do not cause text to reflow. However, other user operations, such as increasing text size for accessiblity purposes, may be considered layout-causing because they cause text to reflow. Similarly, the 'transform' property may be considered not-layout-causing because transforms generally do not cause text to reflow. Each user-agent is free to decide whether or not each operation is layout-changing or not.

0 commit comments

Comments
 (0)