New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 623158 link

Starred by 17 users

Issue metadata

Status: Fixed
Owner:
Closed: Sep 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Launch-OWP
Launch-Accessibility: ----
Launch-Exp-Leadership: ----
Launch-Leadership: ----
Launch-Legal: ----
Launch-M-Approved: ----
Launch-M-Target: ----
Launch-Privacy: ----
Launch-Security: ----
Launch-Test: ----
Launch-UI: ----
Rollout-Type: ----



Sign in to add a comment

Add the text-size-adjust CSS property

Project Member Reported by pdr@chromium.org, Jun 24 2016

Issue description

Change description:
Add the text-size-adjust (and -webkit-text-size-adjust) property which lets authors control the text autosizing feature on mobile. This previously existed in Chrome but was removed around M27, likely by accident.

Changes to API surface:
Two new CSS properties:
1) text-size-adjust
2) -webkit-text-size-adjust

Links:
https://drafts.csswg.org/css-size-adjust
https://compat.spec.whatwg.org/#css-prefixed-aliases

Support in other browsers:
Internet Explorer: Yes
Firefox: Yes
Safari: Yes
 

Comment 1 by pdr@chromium.org, Jun 25 2016

Cc: e...@chromium.org msrchandra@chromium.org kojii@chromium.org pdr@chromium.org
 Issue 233056  has been merged into this issue.
Project Member

Comment 2 by bugdroid1@chromium.org, Jun 29 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea

commit 5365b8ad85c2f5cee6034b8baea3c764ed78e1ea
Author: pdr <pdr@chromium.org>
Date: Wed Jun 29 20:06:40 2016

Implement the new text-size-adjust CSS property

This patch adds a new CSS property for controlling text autosizing:
text-size-adjust (https://drafts.csswg.org/css-size-adjust).

Intent to implement and ship:
https://groups.google.com/a/chromium.org/d/msg/blink-dev/-vHFK4g93jA/JW9wAJyKAQAJ

At a high level, this patch adds a new CSS property and plumbs it to
storage on the rare inherited style data. The new datatype for this is
"TextSizeAdjust" which just wraps a float with logic for storing both
a floating point adjustment value, and whether 'auto' should be used.
The text autosizer itself has been modified to read this new property.

A few changes were needed to allow the text autosizer to use
multipliers less than 1 (see: TextAutosizer::computeAutosizedFontSize
and callers to that function).

The simple-paragraph.html layouttest has been switched to a unit test
to prove the unit test infrastructure works, and many new tests have
been added for the text-size-adjust feature.

BUG= 623158 

Review-Url: https://codereview.chromium.org/2100013002
Cr-Commit-Position: refs/heads/master@{#402916}

[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/LayoutTests/fast/css/getComputedStyle/computed-style-listing-expected.txt
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/LayoutTests/fast/css/getComputedStyle/computed-style-without-renderer-listing-expected.txt
[delete] https://crrev.com/d1fd1e19c9e51b06b2a8199391bdc9a37a8ca2b0/third_party/WebKit/LayoutTests/fast/text-autosizing/simple-paragraph-expected.html
[delete] https://crrev.com/d1fd1e19c9e51b06b2a8199391bdc9a37a8ca2b0/third_party/WebKit/LayoutTests/fast/text-autosizing/simple-paragraph.html
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/LayoutTests/svg/css/getComputedStyle-listing-expected.txt
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/LayoutTests/virtual/stable/webexposed/css-properties-as-js-properties-expected.txt
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/LayoutTests/webexposed/css-properties-as-js-properties-expected.txt
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/core.gypi
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/css/CSSComputedStyleDeclaration.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/css/CSSProperties.in
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/css/parser/CSSPropertyParser.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/css/resolver/FontBuilder.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.h
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/frame/UseCounter.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/layout/TextAutosizer.cpp
[add] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/layout/TextAutosizerTest.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/style/ComputedStyle.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/style/ComputedStyle.h
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/style/StyleRareInheritedData.cpp
[modify] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/style/StyleRareInheritedData.h
[add] https://crrev.com/5365b8ad85c2f5cee6034b8baea3c764ed78e1ea/third_party/WebKit/Source/core/style/TextSizeAdjust.h

Comment 3 by pdr@chromium.org, Jun 30 2016

Cc: gov...@chromium.org
Labels: -M-54 M-53
@govind, can you help me with the approvals on this?

Comment 4 by gov...@chromium.org, Jun 30 2016

M53 is not branched yet. So no approval is needed. 

Comment 5 by pdr@chromium.org, Jun 30 2016

Cc: kojih@chromium.org
 Issue 602520  has been merged into this issue.

Comment 6 by pdr@chromium.org, Jun 30 2016

Issue 135808 has been merged into this issue.

Comment 9 by pdr@chromium.org, Sep 15 2016

Labels: -M-53 M-54 Merge-Request-54
Unfortunately we had a last-minute regression and had to roll this out of M53, see  https://crbug.com/645269  for details.

This has been fixed again. Requesting a merge of https://crrev.com/1229b1414d64c314666d2fb3bf47706f2b5e947b into M54 to re-enable this feature.

Comment 10 by dimu@chromium.org, Sep 15 2016

Labels: -Merge-Request-54 Merge-Review-54 Hotlist-Merge-Review
[Automated comment] Commit may have occurred before M54 branch point (8/25/2016), needs manual review.
Labels: -Merge-Review-54 Merge-Approved-54
Approved for branch 2840.

Comment 12 by pdr@chromium.org, Sep 20 2016

Labels: -Merge-Approved-54 merge-merged-2840
Status: Fixed (was: Assigned)
Merged as https://chromium.googlesource.com/chromium/src/+/d25ac697753f02ac5c923d65402d75b4211cab28

Sign in to add a comment