Changeset 183673 in webkit
- Timestamp:
- May 1, 2015 9:00:13 AM (9 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r183672 r183673 1 2015-05-01 Martin Robinson <mrobinson@igalia.com> 2 3 [Freetype] Add support for the font-synthesis property 4 https://bugs.webkit.org/show_bug.cgi?id=144472 5 6 Reviewed by Sergio Villar Senin. 7 8 No new tests. This causes fast/css3-text/font-synthesis.html to pass 9 for WebKitGTK+. 10 11 * platform/graphics/freetype/FontPlatformDataFreeType.cpp: 12 (WebCore::FontPlatformData::FontPlatformData): Only use synthetic bold when the font description allows it. 13 (WebCore::FontPlatformData::initializeWithFontFace): Ditto for synthetic oblique. 14 1 15 2015-05-01 Martin Robinson <mrobinson@igalia.com> 2 16 -
trunk/Source/WebCore/platform/graphics/freetype/FontPlatformDataFreeType.cpp
r180675 r183673 162 162 m_fixedWidth = true; 163 163 164 if (fontDescription.weight() >= FontWeightBold) { 164 bool descriptionAllowsSyntheticBold = fontDescription.fontSynthesis() & FontSynthesisWeight; 165 if (descriptionAllowsSyntheticBold && fontDescription.weight() >= FontWeightBold) { 165 166 // The FC_EMBOLDEN property instructs us to fake the boldness of the font. 166 167 FcBool fontConfigEmbolden = FcFalse; … … 328 329 // We requested an italic font, but Fontconfig gave us one that was neither oblique nor italic. 329 330 int actualFontSlant; 330 if (fontDescription.italic() && FcPatternGetInteger(optionsPattern, FC_SLANT, 0, &actualFontSlant) == FcResultMatch) 331 bool descriptionAllowsSyntheticOblique = fontDescription.fontSynthesis() & FontSynthesisStyle; 332 if (descriptionAllowsSyntheticOblique && fontDescription.italic() 333 && FcPatternGetInteger(optionsPattern, FC_SLANT, 0, &actualFontSlant) == FcResultMatch) { 331 334 m_syntheticOblique = actualFontSlant == FC_SLANT_ROMAN; 335 } 332 336 333 337 // The matrix from FontConfig does not include the scale.
Note: See TracChangeset
for help on using the changeset viewer.