| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2005, 2008, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2005, 2008, 2010 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2006 Alexey Proskuryakov | 3 * Copyright (C) 2006 Alexey Proskuryakov |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 338 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 349 const FontDescription& fontDescription) const { | 349 const FontDescription& fontDescription) const { |
| 350 if (!m_derivedFontData) | 350 if (!m_derivedFontData) |
| 351 m_derivedFontData = DerivedFontData::create(isCustomFont()); | 351 m_derivedFontData = DerivedFontData::create(isCustomFont()); |
| 352 if (!m_derivedFontData->emphasisMark) | 352 if (!m_derivedFontData->emphasisMark) |
| 353 m_derivedFontData->emphasisMark = | 353 m_derivedFontData->emphasisMark = |
| 354 createScaledFontData(fontDescription, emphasisMarkFontSizeMultiplier); | 354 createScaledFontData(fontDescription, emphasisMarkFontSizeMultiplier); |
| 355 | 355 |
| 356 return m_derivedFontData->emphasisMark; | 356 return m_derivedFontData->emphasisMark; |
| 357 } | 357 } |
| 358 | 358 |
| 359 PassRefPtr<SimpleFontData> SimpleFontData::subpixelAscentDescentFontData() |
| 360 const { |
| 361 return SimpleFontData::create(m_platformData, m_customFontData, |
| 362 m_isTextOrientationFallback, true); |
| 363 } |
| 364 |
| 359 bool SimpleFontData::isTextOrientationFallbackOf( | 365 bool SimpleFontData::isTextOrientationFallbackOf( |
| 360 const SimpleFontData* fontData) const { | 366 const SimpleFontData* fontData) const { |
| 361 if (!isTextOrientationFallback() || !fontData->m_derivedFontData) | 367 if (!isTextOrientationFallback() || !fontData->m_derivedFontData) |
| 362 return false; | 368 return false; |
| 363 return fontData->m_derivedFontData->uprightOrientation == this || | 369 return fontData->m_derivedFontData->uprightOrientation == this || |
| 364 fontData->m_derivedFontData->verticalRightOrientation == this; | 370 fontData->m_derivedFontData->verticalRightOrientation == this; |
| 365 } | 371 } |
| 366 | 372 |
| 367 std::unique_ptr<SimpleFontData::DerivedFontData> | 373 std::unique_ptr<SimpleFontData::DerivedFontData> |
| 368 SimpleFontData::DerivedFontData::create(bool forCustomFont) { | 374 SimpleFontData::DerivedFontData::create(bool forCustomFont) { |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 438 if (glyphs[i]) { | 444 if (glyphs[i]) { |
| 439 pageToFill->setGlyphDataForIndex(offset + i, glyphs[i], this); | 445 pageToFill->setGlyphDataForIndex(offset + i, glyphs[i], this); |
| 440 haveGlyphs = true; | 446 haveGlyphs = true; |
| 441 } | 447 } |
| 442 } | 448 } |
| 443 | 449 |
| 444 return haveGlyphs; | 450 return haveGlyphs; |
| 445 } | 451 } |
| 446 | 452 |
| 447 } // namespace blink | 453 } // namespace blink |
| OLD | NEW |