Title: [131375] trunk/Source/WebCore
- Revision
- 131375
- Author
- m...@apple.com
- Date
- 2012-10-15 15:52:35 -0700 (Mon, 15 Oct 2012)
Log Message
Try to fix assertion failures on ports that do not support kerning and ligatures on the fast
code path after r131365.
* platform/graphics/WidthIterator.cpp:
(WebCore::applyFontTransforms): Changed the early return condition to not bother with 1-glyph
sequences.
* platform/graphics/WidthIterator.h:
(WebCore::WidthIterator::shouldApplyFontTransforms): Changed to return false if the run is
shorter than 2 characters.
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (131374 => 131375)
--- trunk/Source/WebCore/ChangeLog 2012-10-15 22:36:14 UTC (rev 131374)
+++ trunk/Source/WebCore/ChangeLog 2012-10-15 22:52:35 UTC (rev 131375)
@@ -1,5 +1,17 @@
2012-10-15 Dan Bernstein <m...@apple.com>
+ Try to fix assertion failures on ports that do not support kerning and ligatures on the fast
+ code path after r131365.
+
+ * platform/graphics/WidthIterator.cpp:
+ (WebCore::applyFontTransforms): Changed the early return condition to not bother with 1-glyph
+ sequences.
+ * platform/graphics/WidthIterator.h:
+ (WebCore::WidthIterator::shouldApplyFontTransforms): Changed to return false if the run is
+ shorter than 2 characters.
+
+2012-10-15 Dan Bernstein <m...@apple.com>
+
Try to fix the Chromium Mac build after r131365.
* platform/graphics/GlyphBuffer.h:
Modified: trunk/Source/WebCore/platform/graphics/WidthIterator.cpp (131374 => 131375)
--- trunk/Source/WebCore/platform/graphics/WidthIterator.cpp 2012-10-15 22:36:14 UTC (rev 131374)
+++ trunk/Source/WebCore/platform/graphics/WidthIterator.cpp 2012-10-15 22:52:35 UTC (rev 131375)
@@ -109,7 +109,7 @@
return 0;
int glyphBufferSize = glyphBuffer->size();
- if (glyphBuffer->size() <= lastGlyphCount)
+ if (glyphBuffer->size() <= lastGlyphCount + 1)
return 0;
GlyphBufferAdvance* advances = glyphBuffer->advances(0);
Modified: trunk/Source/WebCore/platform/graphics/WidthIterator.h (131374 => 131375)
--- trunk/Source/WebCore/platform/graphics/WidthIterator.h 2012-10-15 22:36:14 UTC (rev 131374)
+++ trunk/Source/WebCore/platform/graphics/WidthIterator.h 2012-10-15 22:52:35 UTC (rev 131375)
@@ -91,7 +91,7 @@
template <typename TextIterator>
inline unsigned advanceInternal(TextIterator&, GlyphBuffer*);
- bool shouldApplyFontTransforms() const { return m_typesettingFeatures & (Kerning | Ligatures); }
+ bool shouldApplyFontTransforms() const { return m_run.length() > 1 && (m_typesettingFeatures & (Kerning | Ligatures)); }
TypesettingFeatures m_typesettingFeatures;
HashSet<const SimpleFontData*>* m_fallbackFonts;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo/webkit-changes