Title: [220746] trunk
- Revision
- 220746
- Author
- commit-qu...@webkit.org
- Date
- 2017-08-15 10:15:47 -0700 (Tue, 15 Aug 2017)
Log Message
Unreviewed, rolling out r219504.
https://bugs.webkit.org/show_bug.cgi?id=175580
Broke Arabic text shaping (Requested by mcatanzaro on
#webkit).
Reverted changeset:
"[HarfBuzz] Decomposed Vietnamese characters are rendered
incorrectly"
https://bugs.webkit.org/show_bug.cgi?id=174418
http://trac.webkit.org/changeset/219504
Modified Paths
Removed Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (220745 => 220746)
--- trunk/LayoutTests/ChangeLog 2017-08-15 17:05:22 UTC (rev 220745)
+++ trunk/LayoutTests/ChangeLog 2017-08-15 17:15:47 UTC (rev 220746)
@@ -1,3 +1,18 @@
+2017-08-15 Commit Queue <commit-qu...@webkit.org>
+
+ Unreviewed, rolling out r219504.
+ https://bugs.webkit.org/show_bug.cgi?id=175580
+
+ Broke Arabic text shaping (Requested by mcatanzaro on
+ #webkit).
+
+ Reverted changeset:
+
+ "[HarfBuzz] Decomposed Vietnamese characters are rendered
+ incorrectly"
+ https://bugs.webkit.org/show_bug.cgi?id=174418
+ http://trac.webkit.org/changeset/219504
+
2017-08-14 Simon Fraser <simon.fra...@apple.com>
Remove Proximity Events and related code
Deleted: trunk/LayoutTests/fast/text/international/vietnamese-nfd-expected.html (220745 => 220746)
--- trunk/LayoutTests/fast/text/international/vietnamese-nfd-expected.html 2017-08-15 17:05:22 UTC (rev 220745)
+++ trunk/LayoutTests/fast/text/international/vietnamese-nfd-expected.html 2017-08-15 17:15:47 UTC (rev 220746)
@@ -1,15 +0,0 @@
-<!DOCTYPE html>
-<html>
-<meta charset="utf-8">
-<style>
- body {
- font-size: 30px;
- font-family: Helvetica, sans;
- }
-</style>
-<body>
- ã ẫ ẵ ẽ ễ ĩ õ ỗ ỡ ũ ữ ỹ<br>
- ạ ậ ặ ẹ ệ ị ọ ộ ợ ụ ự ỵ<br>
- ả ẩ ẳ ẻ ể ỉ ỏ ổ ở ủ ử ỷ<br>
-</body>
-</html>
Deleted: trunk/LayoutTests/fast/text/international/vietnamese-nfd.html (220745 => 220746)
--- trunk/LayoutTests/fast/text/international/vietnamese-nfd.html 2017-08-15 17:05:22 UTC (rev 220745)
+++ trunk/LayoutTests/fast/text/international/vietnamese-nfd.html 2017-08-15 17:15:47 UTC (rev 220746)
@@ -1,15 +0,0 @@
-<!DOCTYPE html>
-<html>
-<meta charset="utf-8">
-<style>
- body {
- font-size: 30px;
- font-family: Helvetica, sans;
- }
-</style>
-<body>
- ã ẫ ẵ ẽ ễ ĩ õ ỗ ỡ ũ ữ ỹ<br>
- ạ ậ ặ ẹ ệ ị ọ ộ ợ ụ ự ỵ<br>
- ả ẩ ẳ ẻ ể ỉ ỏ ổ ở ủ ử ỷ<br>
-</body>
-</html>
Modified: trunk/Source/WebCore/ChangeLog (220745 => 220746)
--- trunk/Source/WebCore/ChangeLog 2017-08-15 17:05:22 UTC (rev 220745)
+++ trunk/Source/WebCore/ChangeLog 2017-08-15 17:15:47 UTC (rev 220746)
@@ -1,3 +1,18 @@
+2017-08-15 Commit Queue <commit-qu...@webkit.org>
+
+ Unreviewed, rolling out r219504.
+ https://bugs.webkit.org/show_bug.cgi?id=175580
+
+ Broke Arabic text shaping (Requested by mcatanzaro on
+ #webkit).
+
+ Reverted changeset:
+
+ "[HarfBuzz] Decomposed Vietnamese characters are rendered
+ incorrectly"
+ https://bugs.webkit.org/show_bug.cgi?id=174418
+ http://trac.webkit.org/changeset/219504
+
2017-08-14 Carlos Garcia Campos <cgar...@igalia.com>
WebDriver: handle click events on option elements
Modified: trunk/Source/WebCore/platform/graphics/harfbuzz/HarfBuzzShaper.cpp (220745 => 220746)
--- trunk/Source/WebCore/platform/graphics/harfbuzz/HarfBuzzShaper.cpp 2017-08-15 17:05:22 UTC (rev 220745)
+++ trunk/Source/WebCore/platform/graphics/harfbuzz/HarfBuzzShaper.cpp 2017-08-15 17:15:47 UTC (rev 220746)
@@ -160,6 +160,33 @@
return position;
}
+static void normalizeCharacters(const TextRun& run, UChar* destination, unsigned length)
+{
+ unsigned position = 0;
+ bool error = false;
+ const UChar* source;
+ String stringFor8BitRun;
+ if (run.is8Bit()) {
+ stringFor8BitRun = String::make16BitFrom8BitSource(run.characters8(), run.length());
+ source = stringFor8BitRun.characters16();
+ } else
+ source = run.characters16();
+
+ while (position < length) {
+ UChar32 character;
+ unsigned nextPosition = position;
+ U16_NEXT(source, nextPosition, length, character);
+ // Don't normalize tabs as they are not treated as spaces for word-end.
+ if (FontCascade::treatAsSpace(character) && character != '\t')
+ character = ' ';
+ else if (FontCascade::treatAsZeroWidthSpaceInComplexScript(character))
+ character = zeroWidthSpace;
+ U16_APPEND(destination, position, length, character, error);
+ ASSERT_UNUSED(error, !error);
+ position = nextPosition;
+ }
+}
+
HarfBuzzShaper::HarfBuzzShaper(const FontCascade* font, const TextRun& run)
: m_font(font)
, m_normalizedBufferLength(0)
@@ -170,7 +197,9 @@
, m_padError(0)
, m_letterSpacing(font->letterSpacing())
{
- setNormalizedBuffer();
+ m_normalizedBuffer = std::make_unique<UChar[]>(m_run.length() + 1);
+ m_normalizedBufferLength = m_run.length();
+ normalizeCharacters(m_run, m_normalizedBuffer.get(), m_normalizedBufferLength);
setPadding(m_run.expansion());
setFontFeatures();
}
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes