Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(127)

Unified Diff: Source/platform/fonts/harfbuzz/HarfBuzzShaper.cpp

Issue 613193002: Avoid drawing emphasis marks over ellipsis glyphs (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added antialiased test in TestExpectations Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/platform/fonts/harfbuzz/HarfBuzzShaper.cpp
diff --git a/Source/platform/fonts/harfbuzz/HarfBuzzShaper.cpp b/Source/platform/fonts/harfbuzz/HarfBuzzShaper.cpp
index a84b151747c66eb448ee6e00d5952e2049997bcc..96a0c81afcd7fa5f6c45b23db58ba8fd44231b6d 100644
--- a/Source/platform/fonts/harfbuzz/HarfBuzzShaper.cpp
+++ b/Source/platform/fonts/harfbuzz/HarfBuzzShaper.cpp
@@ -1023,6 +1023,8 @@ void HarfBuzzShaper::fillGlyphBufferForTextEmphasis(GlyphBuffer* glyphBuffer, Ha
for (unsigned j = 0; j < graphemesInCluster; ++j) {
// Do not put emphasis marks on space, separator, and control characters.
Glyph glyphToAdd = Character::canReceiveTextEmphasis(m_run[currentCharacterIndex]) ? 1 : 0;
+ if (m_run.rtl() && currentCharacterIndex >= m_toIndex)
+ glyphToAdd = 0;
Dominik Röttsches 2014/09/30 12:27:00 Can m_toIndex be factored into the clusterEnd comp
Habib Virji 2014/09/30 13:28:40 Reason to add special handling was returning befor
Dominik Röttsches 2014/09/30 13:48:24 Yes, I understood your analysis. Please take a loo
Dominik Röttsches 2014/10/01 07:35:35 I looked at this a bit more closely again - this f
glyphBuffer->add(glyphToAdd, currentRun->fontData(), glyphAdvanceX);
}
clusterStart = clusterEnd;

Powered by Google App Engine
This is Rietveld 408576698