[HarfBuzz] harfbuzz-ng: Branch 'master' - 2 commits

Behdad Esfahbod behdad at kemper.freedesktop.org
Wed Jul 25 16:31:45 PDT 2012


 src/hb-old.cc                  |   15 ++++++++-------
 src/hb-old/harfbuzz-shaper.cpp |    2 +-
 2 files changed, 9 insertions(+), 8 deletions(-)

New commits:
commit 2e7f223054d310695bdb3498b2b2b5d17b6cce78
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Wed Jul 25 19:30:15 2012 -0400

    [hb-old] Fix Arabic cursive positioning
    
    Backporting from upstream:
    
    commit b847f24ce855d24f6822bcd9c0006905e81b94d8
    Author: Behdad Esfahbod <behdad at behdad.org>
    Date:   Wed Jul 25 19:29:16 2012 -0400
    
        [arabic] Fix Arabic cursive positioning
    
        This was clearly broken in testing.  Who knows...  Fixes for me.
        Test with a Nastaleeq font, or with Arabic Typesetting.
    
        Backporting from Chromium.

diff --git a/src/hb-old/harfbuzz-shaper.cpp b/src/hb-old/harfbuzz-shaper.cpp
index 5baf971..62886f3 100644
--- a/src/hb-old/harfbuzz-shaper.cpp
+++ b/src/hb-old/harfbuzz-shaper.cpp
@@ -923,7 +923,7 @@ HB_Bool HB_OpenTypePosition(HB_ShaperItem *item, int availableGlyphs, HB_Bool do
                 adjustment = HB_FIXED_ROUND(adjustment);
 
             if (positions[i].new_advance) {
-                advances[i] = adjustment;
+                ; //advances[i] = adjustment;
             } else {
                 advances[i] += adjustment;
             }
commit 9550a8c4e8b4e28be60d38c27d59253846ff9569
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Wed Jul 25 19:22:57 2012 -0400

    [hb-old] Fixup not-enough-space handling

diff --git a/src/hb-old.cc b/src/hb-old.cc
index e828ca8..be0187f 100644
--- a/src/hb-old.cc
+++ b/src/hb-old.cc
@@ -329,14 +329,15 @@ retry:
 #undef ALLOCATE_ARRAY
 
   if (!HB_ShapeItem (&item))
-    return false;
-
-  if (unlikely (item.num_glyphs > num_glyphs))
   {
-    buffer->ensure (buffer->allocated * 2);
-    if (buffer->in_error)
-      FAIL ("Buffer resize failed");
-    goto retry;
+    if (unlikely (item.num_glyphs > num_glyphs))
+    {
+      buffer->ensure (buffer->allocated * 2);
+      if (buffer->in_error)
+	FAIL ("Buffer resize failed");
+      goto retry;
+    }
+    return false;
   }
   num_glyphs = item.num_glyphs;
 



More information about the HarfBuzz mailing list