Diff
Modified: trunk/LayoutTests/ChangeLog (214723 => 214724)
--- trunk/LayoutTests/ChangeLog 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/LayoutTests/ChangeLog 2017-04-02 05:28:10 UTC (rev 214724)
@@ -1,3 +1,13 @@
+2017-04-01 Jon Lee <jon...@apple.com>
+
+ Add missing text styles
+ https://bugs.webkit.org/show_bug.cgi?id=170295
+ rdar://problem/30219503
+
+ Reviewed by Dean Jackson.
+
+ * platform/ios/ios/fast/text/opticalFontWithTextStyle.html: Update test to include title0 and title4.
+
2017-04-01 Chris Dumez <cdu...@apple.com>
We should pause silent WebAudio rendering in background tabs
Modified: trunk/LayoutTests/platform/ios/ios/fast/text/opticalFontWithTextStyle-expected.txt (214723 => 214724)
--- trunk/LayoutTests/platform/ios/ios/fast/text/opticalFontWithTextStyle-expected.txt 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/LayoutTests/platform/ios/ios/fast/text/opticalFontWithTextStyle-expected.txt 2017-04-02 05:28:10 UTC (rev 214724)
@@ -1,50 +1,56 @@
-layer at (0,0) size 800x600
+layer at (0,0) size 800x663
RenderView at (0,0) size 800x600
-layer at (0,0) size 800x600
- RenderBlock {HTML} at (0,0) size 800x600
- RenderBody {BODY} at (8,15) size 784x577
+layer at (0,0) size 800x663
+ RenderBlock {HTML} at (0,0) size 800x663
+ RenderBody {BODY} at (8,15) size 784x640
RenderBlock {DIV} at (0,0) size 784x24
RenderText {#text} at (0,1) size 106x22
text run at (0,1) width 106: "H1 / Headline"
- RenderBlock {DIV} at (0,39) size 784x35
+ RenderBlock {DIV} at (0,39) size 784x16
+ RenderText {#text} at (0,0) size 56x15
+ text run at (0,0) width 56: "T0 / Title0"
+ RenderBlock {DIV} at (0,70) size 784x35
RenderText {#text} at (0,0) size 113x34
text run at (0,0) width 113: "T1 / Title1"
- RenderBlock {DIV} at (0,89) size 784x29
+ RenderBlock {DIV} at (0,120) size 784x29
RenderText {#text} at (0,1) size 99x27
text run at (0,1) width 99: "T2 / Title2"
- RenderBlock {DIV} at (0,133) size 784x26
+ RenderBlock {DIV} at (0,164) size 784x26
RenderText {#text} at (0,0) size 92x25
text run at (0,0) width 92: "T3 / Title3"
- RenderBlock {DIV} at (0,174) size 784x24
+ RenderBlock {DIV} at (0,205) size 784x50
+ RenderText {#text} at (0,1) size 187x47
+ text run at (0,1) width 187: "T4 / Title4"
+ RenderBlock {DIV} at (0,270) size 784x24
RenderText {#text} at (0,1) size 707x22
text run at (0,1) width 707: "Body Text: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ornare ornare mi"
- RenderBlock {DIV} at (0,213) size 784x26
+ RenderBlock {DIV} at (0,309) size 784x26
RenderText {#text} at (0,2) size 737x22
text run at (0,2) width 737: "Tall Body Text: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ornare ornare mi"
- RenderBlock {DIV} at (0,254) size 784x22
+ RenderBlock {DIV} at (0,350) size 784x22
RenderText {#text} at (0,1) size 85x19
text run at (0,1) width 85: "Subheadline"
- RenderBlock {DIV} at (0,291) size 784x20
+ RenderBlock {DIV} at (0,387) size 784x20
RenderText {#text} at (0,1) size 83x17
text run at (0,1) width 83: "FN / Footnote"
- RenderBlock {DIV} at (0,326) size 784x17
+ RenderBlock {DIV} at (0,422) size 784x17
RenderText {#text} at (0,1) size 96x15
text run at (0,1) width 96: "Cap 1 / Caption 1"
- RenderBlock {DIV} at (0,358) size 784x14
+ RenderBlock {DIV} at (0,454) size 784x14
RenderText {#text} at (0,0) size 92x14
text run at (0,0) width 92: "Cap 2 / Caption 2"
- RenderBlock {DIV} at (0,387) size 784x22
+ RenderBlock {DIV} at (0,483) size 784x22
RenderText {#text} at (0,0) size 154x22
text run at (0,0) width 154: "Short H1 / Headline"
- RenderBlock {DIV} at (0,424) size 784x22
+ RenderBlock {DIV} at (0,520) size 784x22
RenderText {#text} at (0,0) size 753x22
text run at (0,0) width 753: "Short Body Text: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ornare ornare mi"
- RenderBlock {DIV} at (0,461) size 784x20
+ RenderBlock {DIV} at (0,557) size 784x20
RenderText {#text} at (0,0) size 127x19
text run at (0,0) width 127: "Short Subheadline"
- RenderBlock {DIV} at (0,496) size 784x18
+ RenderBlock {DIV} at (0,592) size 784x18
RenderText {#text} at (0,0) size 120x17
text run at (0,0) width 120: "Short FN / Footnote"
- RenderBlock {DIV} at (0,529) size 784x15
+ RenderBlock {DIV} at (0,625) size 784x15
RenderText {#text} at (0,0) size 130x15
text run at (0,0) width 130: "Short Cap 1 / Caption 1"
Modified: trunk/LayoutTests/platform/ios/ios/fast/text/opticalFontWithTextStyle.html (214723 => 214724)
--- trunk/LayoutTests/platform/ios/ios/fast/text/opticalFontWithTextStyle.html 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/LayoutTests/platform/ios/ios/fast/text/opticalFontWithTextStyle.html 2017-04-02 05:28:10 UTC (rev 214724)
@@ -5,9 +5,11 @@
</head>
<body>
<div style="margin-top: 15px; font: -apple-system-headline">H1 / Headline</div>
+ <div style="margin-top: 15px; font: -apple-system-title0">T0 / Title0</div>
<div style="margin-top: 15px; font: -apple-system-title1">T1 / Title1</div>
<div style="margin-top: 15px; font: -apple-system-title2">T2 / Title2</div>
<div style="margin-top: 15px; font: -apple-system-title3">T3 / Title3</div>
+ <div style="margin-top: 15px; font: -apple-system-title4">T4 / Title4</div>
<div style="margin-top: 15px; font: -apple-system-body">Body Text: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ornare ornare mi</div>
<div style="margin-top: 15px; font: -apple-system-tall-body">Tall Body Text: Lorem ipsum dolor sit amet, consectetur adipiscing elit. Quisque ornare ornare mi</div>
<div style="margin-top: 15px; font: -apple-system-subheadline">Subheadline</div>
Modified: trunk/Source/WebCore/ChangeLog (214723 => 214724)
--- trunk/Source/WebCore/ChangeLog 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/Source/WebCore/ChangeLog 2017-04-02 05:28:10 UTC (rev 214724)
@@ -1,3 +1,19 @@
+2017-04-01 Jon Lee <jon...@apple.com>
+
+ Add missing text styles
+ https://bugs.webkit.org/show_bug.cgi?id=170295
+ rdar://problem/30219503
+
+ Reviewed by Dean Jackson.
+
+ Updated existing test to include new text styles.
+
+ * css/CSSValueKeywords.in: Add title0 and title4.
+ * platform/spi/cocoa/CoreTextSPI.h:
+ * rendering/RenderThemeIOS.mm:
+ (WebCore::RenderThemeIOS::cachedSystemFontDescription):
+ (WebCore::RenderThemeIOS::updateCachedSystemFontDescription):
+
2017-04-01 Dan Bernstein <m...@apple.com>
[iOS] <input type=file> label should be specified using plural rules
Modified: trunk/Source/WebCore/css/CSSValueKeywords.in (214723 => 214724)
--- trunk/Source/WebCore/css/CSSValueKeywords.in 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/Source/WebCore/css/CSSValueKeywords.in 2017-04-02 05:28:10 UTC (rev 214724)
@@ -48,9 +48,11 @@
-apple-system-short-footnote
-apple-system-short-caption1
-apple-system-tall-body
+-apple-system-title0
-apple-system-title1
-apple-system-title2
-apple-system-title3
+-apple-system-title4
#endif
// This has to go after the -apple-system versions.
Modified: trunk/Source/WebCore/platform/spi/cocoa/CoreTextSPI.h (214723 => 214724)
--- trunk/Source/WebCore/platform/spi/cocoa/CoreTextSPI.h 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/Source/WebCore/platform/spi/cocoa/CoreTextSPI.h 2017-04-02 05:28:10 UTC (rev 214724)
@@ -119,9 +119,11 @@
extern const CGFloat kCTFontWeightHeavy;
extern const CGFloat kCTFontWeightBlack;
+extern const CFStringRef kCTUIFontTextStyleTitle0;
extern const CFStringRef kCTUIFontTextStyleTitle1;
extern const CFStringRef kCTUIFontTextStyleTitle2;
extern const CFStringRef kCTUIFontTextStyleTitle3;
+extern const CFStringRef kCTUIFontTextStyleTitle4;
CTFontDescriptorRef CTFontCreatePhysicalFontDescriptorForCharactersWithLanguage(CTFontRef currentFont, const UTF16Char* characters, CFIndex length, CFStringRef language, CFIndex* coveredLength);
CTFontRef CTFontCreatePhysicalFontForCharactersWithLanguage(CTFontRef, const UTF16Char* characters, CFIndex length, CFStringRef language, CFIndex* coveredLength);
Modified: trunk/Source/WebCore/rendering/RenderThemeIOS.mm (214723 => 214724)
--- trunk/Source/WebCore/rendering/RenderThemeIOS.mm 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/Source/WebCore/rendering/RenderThemeIOS.mm 2017-04-02 05:28:10 UTC (rev 214724)
@@ -1135,9 +1135,15 @@
static NeverDestroyed<FontCascadeDescription> shortFootnoteFont;
static NeverDestroyed<FontCascadeDescription> shortCaption1Font;
static NeverDestroyed<FontCascadeDescription> tallBodyFont;
+#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 110000
+ static NeverDestroyed<FontCascadeDescription> title0Font;
+#endif
static NeverDestroyed<FontCascadeDescription> title1Font;
static NeverDestroyed<FontCascadeDescription> title2Font;
static NeverDestroyed<FontCascadeDescription> title3Font;
+#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 100000
+ static NeverDestroyed<FontCascadeDescription> title4Font;
+#endif
static CFStringRef userTextSize = contentSizeCategory();
@@ -1163,6 +1169,10 @@
return headlineFont;
case CSSValueAppleSystemBody:
return bodyFont;
+#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 110000
+ case CSSValueAppleSystemTitle0:
+ return title0Font;
+#endif
case CSSValueAppleSystemTitle1:
return title1Font;
case CSSValueAppleSystemTitle2:
@@ -1169,6 +1179,10 @@
return title2Font;
case CSSValueAppleSystemTitle3:
return title3Font;
+#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 100000
+ case CSSValueAppleSystemTitle4:
+ return title4Font;
+#endif
case CSSValueAppleSystemSubheadline:
return subheadlineFont;
case CSSValueAppleSystemFootnote:
@@ -1209,6 +1223,12 @@
textStyle = kCTUIFontTextStyleBody;
fontDescriptor = adoptCF(CTFontDescriptorCreateWithTextStyle(textStyle, contentSizeCategory(), 0));
break;
+#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 110000
+ case CSSValueAppleSystemTitle0:
+ textStyle = kCTUIFontTextStyleTitle0;
+ fontDescriptor = adoptCF(CTFontDescriptorCreateWithTextStyle(textStyle, contentSizeCategory(), 0));
+ break;
+#endif
case CSSValueAppleSystemTitle1:
textStyle = kCTUIFontTextStyleTitle1;
fontDescriptor = adoptCF(CTFontDescriptorCreateWithTextStyle(textStyle, contentSizeCategory(), 0));
@@ -1221,6 +1241,12 @@
textStyle = kCTUIFontTextStyleTitle3;
fontDescriptor = adoptCF(CTFontDescriptorCreateWithTextStyle(textStyle, contentSizeCategory(), 0));
break;
+#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 100000
+ case CSSValueAppleSystemTitle4:
+ textStyle = kCTUIFontTextStyleTitle4;
+ fontDescriptor = adoptCF(CTFontDescriptorCreateWithTextStyle(textStyle, contentSizeCategory(), 0));
+ break;
+#endif
case CSSValueAppleSystemSubheadline:
textStyle = kCTUIFontTextStyleSubhead;
fontDescriptor = adoptCF(CTFontDescriptorCreateWithTextStyle(textStyle, contentSizeCategory(), 0));
Modified: trunk/Source/WebInspectorUI/ChangeLog (214723 => 214724)
--- trunk/Source/WebInspectorUI/ChangeLog 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/Source/WebInspectorUI/ChangeLog 2017-04-02 05:28:10 UTC (rev 214724)
@@ -1,3 +1,13 @@
+2017-04-01 Jon Lee <jon...@apple.com>
+
+ Add missing text styles
+ https://bugs.webkit.org/show_bug.cgi?id=170295
+ rdar://problem/30219503
+
+ Reviewed by Dean Jackson.
+
+ * UserInterface/Models/CSSKeywordCompletions.js: Update keyword completions
+
2017-04-01 Dan Bernstein <m...@apple.com>
Localizable strings files are out of date
Modified: trunk/Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js (214723 => 214724)
--- trunk/Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js 2017-04-02 04:53:39 UTC (rev 214723)
+++ trunk/Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js 2017-04-02 05:28:10 UTC (rev 214724)
@@ -391,7 +391,7 @@
"-apple-system-headline", "-apple-system-body", "-apple-system-subheadline", "-apple-system-footnote",
"-apple-system-caption1", "-apple-system-caption2", "-apple-system-short-headline", "-apple-system-short-body",
"-apple-system-short-subheadline", "-apple-system-short-footnote", "-apple-system-short-caption1",
- "-apple-system-tall-body", "-apple-system-title1", "-apple-system-title2", "-apple-system-title3", "system-ui"
+ "-apple-system-tall-body", "-apple-system-title0", "-apple-system-title1", "-apple-system-title2", "-apple-system-title3", "-apple-system-title4", "system-ui"
],
"dominant-baseline": [
"middle", "auto", "central", "text-before-edge", "text-after-edge", "ideographic", "alphabetic", "hanging",
@@ -500,7 +500,7 @@
"-apple-system-subheadline", "-apple-system-footnote", "-apple-system-caption1", "-apple-system-caption2",
"-apple-system-short-headline", "-apple-system-short-body", "-apple-system-short-subheadline",
"-apple-system-short-footnote", "-apple-system-short-caption1", "-apple-system-tall-body",
- "-apple-system-title1", "-apple-system-title2", "-apple-system-title3", "system-ui"
+ "-apple-system-title0", "-apple-system-title1", "-apple-system-title2", "-apple-system-title3", "-apple-system-title4", "system-ui"
],
"text-overflow-mode": [
"clip", "ellipsis"