[HarfBuzz] harfbuzz: Branch 'master' - 9 commits

Behdad Esfahbod behdad at kemper.freedesktop.org
Tue Jun 24 09:22:12 PDT 2014


 src/gen-arabic-table.py                 |   14 ++--
 src/gen-indic-table.py                  |   14 ++--
 src/hb-ot-layout.cc                     |   15 ++++
 src/hb-ot-layout.h                      |    7 ++
 src/hb-ot-shape-complex-arabic-table.hh |  106 +++++++++++++++++++++++++-------
 src/hb-ot-shape-complex-arabic.cc       |   34 +---------
 src/hb-ot-shape-complex-indic-table.cc  |   12 +--
 7 files changed, 133 insertions(+), 69 deletions(-)

New commits:
commit 911ca38645bd51764e7859bc482319e8f6d2f710
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Tue Jun 24 10:20:36 2014 -0600

    Add back API removed recently
    
    Add hb_ot_layout_language_get_required_feature_index() again, which
    is used in Pango.  This was removed in
    da132937989acb4d8ca9bd41c79f98750e7dda30 in favor of
    hb_ot_layout_language_get_required_feature().
    
    API changes:
    
      - Added hb_ot_layout_language_get_required_feature_index back.

diff --git a/src/hb-ot-layout.cc b/src/hb-ot-layout.cc
index e414ddc..661d90e 100644
--- a/src/hb-ot-layout.cc
+++ b/src/hb-ot-layout.cc
@@ -321,6 +321,21 @@ hb_ot_layout_script_find_language (hb_face_t    *face,
 }
 
 hb_bool_t
+hb_ot_layout_language_get_required_feature_index (hb_face_t    *face,
+						  hb_tag_t      table_tag,
+						  unsigned int  script_index,
+						  unsigned int  language_index,
+						  unsigned int *feature_index)
+{
+  return hb_ot_layout_language_get_required_feature (face,
+						     table_tag,
+						     script_index,
+						     language_index,
+						     feature_index,
+						     NULL);
+}
+
+hb_bool_t
 hb_ot_layout_language_get_required_feature (hb_face_t    *face,
 					    hb_tag_t      table_tag,
 					    unsigned int  script_index,
diff --git a/src/hb-ot-layout.h b/src/hb-ot-layout.h
index 32ce762..87171d7 100644
--- a/src/hb-ot-layout.h
+++ b/src/hb-ot-layout.h
@@ -140,6 +140,13 @@ hb_ot_layout_script_find_language (hb_face_t    *face,
 				   unsigned int *language_index);
 
 hb_bool_t
+hb_ot_layout_language_get_required_feature_index (hb_face_t    *face,
+						  hb_tag_t      table_tag,
+						  unsigned int  script_index,
+						  unsigned int  language_index,
+						  unsigned int *feature_index);
+
+hb_bool_t
 hb_ot_layout_language_get_required_feature (hb_face_t    *face,
 					    hb_tag_t      table_tag,
 					    unsigned int  script_index,
commit 89e4946929a8cd2359c7d76fa9272d5604243002
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sun Jun 22 11:32:13 2014 -0600

    Add new IndicSyllabicCategory short forms for Unicode 7.0

diff --git a/src/gen-indic-table.py b/src/gen-indic-table.py
index 2c87ccf..6891424 100755
--- a/src/gen-indic-table.py
+++ b/src/gen-indic-table.py
@@ -80,6 +80,10 @@ print
 # Shorten values
 short = [{
 	"Bindu":		'Bi',
+	"Cantillation_Mark":	'Ca',
+	"Joiner":		'ZWJ',
+	"Non_Joiner":		'ZWNJ',
+	"Number":		'Nd',
 	"Visarga":		'Vs',
 	"Vowel":		'Vo',
 	"Vowel_Dependent":	'M',
commit dcee838e89c2863c2fda4e8f098e720637e02335
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sun Jun 22 11:29:59 2014 -0600

    Minor

diff --git a/src/gen-arabic-table.py b/src/gen-arabic-table.py
index a5ec15a..c484708 100755
--- a/src/gen-arabic-table.py
+++ b/src/gen-arabic-table.py
@@ -73,7 +73,7 @@ def print_joining_table(f):
 	num = len(values)
 	all_blocks = set([blocks[u] for u in uu])
 
-	last = -1
+	last = -100000
 	ranges = []
 	for u in uu:
 		if u - last <= 1+16*5:
diff --git a/src/gen-indic-table.py b/src/gen-indic-table.py
index eea345f..2c87ccf 100755
--- a/src/gen-indic-table.py
+++ b/src/gen-indic-table.py
@@ -150,7 +150,7 @@ def print_block (block, start, end, data):
 uu = data.keys ()
 uu.sort ()
 
-last = -1
+last = -100000
 num = 0
 offset = 0
 starts = []
commit f2ad86e6053fa87ab188c36edc3d98c92324c049
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sat Jun 21 15:31:10 2014 -0600

    [indic-table-gen] Minor

diff --git a/src/gen-indic-table.py b/src/gen-indic-table.py
index e21b5e7..eea345f 100755
--- a/src/gen-indic-table.py
+++ b/src/gen-indic-table.py
@@ -87,14 +87,14 @@ short = [{
 },{
 	"Not_Applicable":	'x',
 }]
-all_shorts = [[],[]]
+all_shorts = [{},{}]
 
 # Add some of the values, to make them more readable, and to avoid duplicates
 
 
 for i in range (2):
 	for v,s in short[i].items ():
-		all_shorts[i].append (s)
+		all_shorts[i][s] = v
 
 what = ["INDIC_SYLLABIC_CATEGORY", "INDIC_MATRA_CATEGORY"]
 what_short = ["ISC", "IMC"]
@@ -109,8 +109,8 @@ for i in range (2):
 		else:
 			s = ''.join ([c for c in v_no_and if ord ('A') <= ord (c) <= ord ('Z')])
 			if s in all_shorts[i]:
-				raise Exception ("Duplicate short value alias", v, s)
-			all_shorts[i].append (s)
+				raise Exception ("Duplicate short value alias", v, all_shorts[i][s])
+			all_shorts[i][s] = v
 			short[i][v] = s
 		print "#define %s_%s	%s_%s	%s/* %3d chars; %s */" % \
 			(what_short[i], s, what[i], v.upper (), \
commit 2ec62279aab8c2263f17ffbc7c6f74304674f9a8
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sat Jun 21 15:25:59 2014 -0600

    [indic-table] Update to Unicode 6.3.0
    
    Was from 6.2.0.  It's a no-op.  Committing for the record.

diff --git a/src/hb-ot-shape-complex-indic-table.cc b/src/hb-ot-shape-complex-indic-table.cc
index a6d805e..14637fa 100644
--- a/src/hb-ot-shape-complex-indic-table.cc
+++ b/src/hb-ot-shape-complex-indic-table.cc
@@ -6,12 +6,12 @@
  *
  * on files with these headers:
  *
- * # IndicSyllabicCategory-6.2.0.txt
- * # Date: 2012-05-15, 21:12:00 GMT [KW]
- * # IndicMatraCategory-6.2.0.txt
- * # Date: 2012-05-15, 21:10:00 GMT [KW]
- * # Blocks-6.2.0.txt
- * # Date: 2012-05-14, 22:42:00 GMT [KW, LI]
+ * # IndicSyllabicCategory-6.3.0.txt
+ * # Date: 2013-08-01, 21:17:00 GMT [KW, LI]
+ * # IndicMatraCategory-6.3.0.txt
+ * # Date: 2013-01-02, 08:33:00 GMT [KW, LI]
+ * # Blocks-6.3.0.txt
+ * # Date: 2012-12-02, 09:45:00 GMT [KW, LI]
  */
 
 #include "hb-ot-shape-complex-indic-private.hh"
commit 5d4d7384efa97a30893ad28b9ad9a994722de12c
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sat Jun 21 14:53:21 2014 -0600

    Minor: format

diff --git a/src/hb-ot-shape-complex-arabic.cc b/src/hb-ot-shape-complex-arabic.cc
index 878f97f..b7aa694 100644
--- a/src/hb-ot-shape-complex-arabic.cc
+++ b/src/hb-ot-shape-complex-arabic.cc
@@ -61,8 +61,11 @@ static unsigned int get_joining_type (hb_codepoint_t u, hb_unicode_general_categ
   if (likely (j_type != JOINING_TYPE_X))
     return j_type;
 
-  return (FLAG(gen_cat) & (FLAG(HB_UNICODE_GENERAL_CATEGORY_NON_SPACING_MARK) | FLAG(HB_UNICODE_GENERAL_CATEGORY_ENCLOSING_MARK) | FLAG(HB_UNICODE_GENERAL_CATEGORY_FORMAT))) ?
-	 JOINING_TYPE_T : JOINING_TYPE_U;
+  return (FLAG(gen_cat) &
+	  (FLAG(HB_UNICODE_GENERAL_CATEGORY_NON_SPACING_MARK) |
+	   FLAG(HB_UNICODE_GENERAL_CATEGORY_ENCLOSING_MARK) |
+	   FLAG(HB_UNICODE_GENERAL_CATEGORY_FORMAT))
+	 ) ?  JOINING_TYPE_T : JOINING_TYPE_U;
 }
 
 static const hb_tag_t arabic_features[] =
commit 44243ae5902cc420e6bf6ec2fca2584ba93ff2fb
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sat Jun 21 14:19:34 2014 -0600

    [arabic-table] Update to Unicode 7.0
    
    Old table was from 6.2.  Remove hard-coded Mongolian and Phags-pa data.
    This completes support for new scripts Manichian and Psaltar Pahlavi.

diff --git a/src/hb-ot-shape-complex-arabic-table.hh b/src/hb-ot-shape-complex-arabic-table.hh
index 77dfc6e..ae7011a 100644
--- a/src/hb-ot-shape-complex-arabic-table.hh
+++ b/src/hb-ot-shape-complex-arabic-table.hh
@@ -6,10 +6,10 @@
  *
  * on files with these headers:
  *
- * # ArabicShaping-6.2.0.txt
- * # Date: 2012-05-15, 21:05:00 GMT [KW]
- * # Blocks-6.2.0.txt
- * # Date: 2012-05-14, 22:42:00 GMT [KW, LI]
+ * # ArabicShaping-7.0.0.txt
+ * # Date: 2014-02-14, 21:00:00 GMT [RP, KW, LI]
+ * # Blocks-7.0.0.txt
+ * # Date: 2014-04-03, 23:23:00 GMT [RP, KW]
  * UnicodeData.txt does not have a header.
  */
 
@@ -22,6 +22,7 @@
 #define U	JOINING_TYPE_U
 #define A	JOINING_GROUP_ALAPH
 #define DR	JOINING_GROUP_DALATH_RISH
+#define L	JOINING_TYPE_L
 #define C	JOINING_TYPE_C
 #define D	JOINING_TYPE_D
 
@@ -32,7 +33,7 @@ static const uint8_t joining_table[] =
 
   /* Arabic */
 
-  /* 0600 */ U,U,U,U,U,X,X,X,U,X,X,U,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
+  /* 0600 */ U,U,U,U,U,U,X,X,U,X,X,U,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
   /* 0620 */ D,U,R,R,R,R,D,R,D,R,D,D,D,D,D,R,R,R,R,D,D,D,D,D,D,D,D,D,D,D,D,D,
   /* 0640 */ C,D,D,D,D,D,D,D,R,D,D,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
   /* 0660 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,D,D,X,R,R,R,U,R,R,R,D,D,D,D,D,D,D,D,
@@ -75,15 +76,53 @@ static const uint8_t joining_table[] =
 
   /* Arabic Extended-A */
 
-  /* 08A0 */ D,X,D,D,D,D,D,D,D,D,R,R,R,
+  /* 08A0 */ D,D,D,D,D,D,D,D,D,D,R,R,R,U,R,D,D,R,R,
 
-#define joining_offset_0x200c 685
+#define joining_offset_0x1806 691
+
+  /* Mongolian */
+
+  /* 1800 */             U,D,X,X,C,X,X,X,U,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
+  /* 1820 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,
+  /* 1840 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,
+  /* 1860 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,X,X,X,X,X,X,X,X,
+  /* 1880 */ U,U,U,U,U,U,U,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,
+  /* 18A0 */ D,D,D,D,D,D,D,D,D,X,D,
+
+#define joining_offset_0x200c 856
 
   /* General Punctuation */
 
   /* 2000 */                         U,C,
 
-}; /* Table items: 687; occupancy: 45% */
+#define joining_offset_0x2066 858
+
+  /* General Punctuation */
+
+  /* 2060 */             U,U,U,U,
+
+#define joining_offset_0xa840 862
+
+  /* Phags-pa */
+
+  /* A840 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,
+  /* A860 */ D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,L,U,
+
+#define joining_offset_0x10ac0 914
+
+  /* Manichaean */
+
+  /* 10AC0 */ D,D,D,D,D,R,U,R,U,R,R,U,U,L,R,R,R,R,R,D,D,D,D,L,D,D,D,D,D,R,D,D,
+  /* 10AE0 */ D,R,U,U,R,X,X,X,X,X,X,D,D,D,D,R,
+
+#define joining_offset_0x10b80 962
+
+  /* Psalter Pahlavi */
+
+  /* 10B80 */ D,R,D,R,R,R,D,D,D,R,D,D,R,D,R,R,D,R,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
+  /* 10BA0 */ X,X,X,X,X,X,X,X,X,R,R,R,R,D,D,U,
+
+}; /* Table items: 1010; occupancy: 57% */
 
 
 static unsigned int
@@ -92,11 +131,25 @@ joining_type (hb_codepoint_t u)
   switch (u >> 12)
   {
     case 0x0:
-      if (0x0600 <= u && u <= 0x08AC) return joining_table[u - 0x0600 + joining_offset_0x0600];
+      if (0x0600 <= u && u <= 0x08B2) return joining_table[u - 0x0600 + joining_offset_0x0600];
+      break;
+
+    case 0x1:
+      if (0x1806 <= u && u <= 0x18AA) return joining_table[u - 0x1806 + joining_offset_0x1806];
       break;
 
     case 0x2:
       if (0x200C <= u && u <= 0x200D) return joining_table[u - 0x200C + joining_offset_0x200c];
+      if (0x2066 <= u && u <= 0x2069) return joining_table[u - 0x2066 + joining_offset_0x2066];
+      break;
+
+    case 0xA:
+      if (0xA840 <= u && u <= 0xA873) return joining_table[u - 0xA840 + joining_offset_0xa840];
+      break;
+
+    case 0x10:
+      if (0x10AC0 <= u && u <= 0x10AEF) return joining_table[u - 0x10AC0 + joining_offset_0x10ac0];
+      if (0x10B80 <= u && u <= 0x10BAF) return joining_table[u - 0x10B80 + joining_offset_0x10b80];
       break;
 
     default:
@@ -110,6 +163,7 @@ joining_type (hb_codepoint_t u)
 #undef U
 #undef A
 #undef DR
+#undef L
 #undef C
 #undef D
 
diff --git a/src/hb-ot-shape-complex-arabic.cc b/src/hb-ot-shape-complex-arabic.cc
index 4ce8478..878f97f 100644
--- a/src/hb-ot-shape-complex-arabic.cc
+++ b/src/hb-ot-shape-complex-arabic.cc
@@ -61,28 +61,6 @@ static unsigned int get_joining_type (hb_codepoint_t u, hb_unicode_general_categ
   if (likely (j_type != JOINING_TYPE_X))
     return j_type;
 
-  /* Mongolian joining data is not in ArabicJoining.txt yet. */
-  if (unlikely (hb_in_range<hb_codepoint_t> (u, 0x1800, 0x18AF)))
-  {
-    if (unlikely (hb_in_range<hb_codepoint_t> (u, 0x1880, 0x1886)))
-      return JOINING_TYPE_U;
-
-    /* All letters, SIBE SYLLABLE BOUNDARY MARKER, and NIRUGU are D */
-    if ((FLAG(gen_cat) & (FLAG (HB_UNICODE_GENERAL_CATEGORY_OTHER_LETTER) |
-			  FLAG (HB_UNICODE_GENERAL_CATEGORY_MODIFIER_LETTER)))
-	|| u == 0x1807 || u == 0x180A)
-      return JOINING_TYPE_D;
-  }
-
-  /* 'Phags-pa joining data is not in ArabicJoining.txt yet. */
-  if (unlikely (hb_in_range<hb_codepoint_t> (u, 0xA840, 0xA872)))
-  {
-      if (unlikely (u == 0xA872))
-	return JOINING_TYPE_L;
-
-      return JOINING_TYPE_D;
-  }
-
   return (FLAG(gen_cat) & (FLAG(HB_UNICODE_GENERAL_CATEGORY_NON_SPACING_MARK) | FLAG(HB_UNICODE_GENERAL_CATEGORY_ENCLOSING_MARK) | FLAG(HB_UNICODE_GENERAL_CATEGORY_FORMAT))) ?
 	 JOINING_TYPE_T : JOINING_TYPE_U;
 }
commit cd86ab9b4f4d7bd4f563be64a83714fc8fb395d7
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sat Jun 21 14:10:38 2014 -0600

    [arabic-table] Add ZWJ/ZWNJ now that table is segmented

diff --git a/src/gen-arabic-table.py b/src/gen-arabic-table.py
index ce80cc8..a5ec15a 100755
--- a/src/gen-arabic-table.py
+++ b/src/gen-arabic-table.py
@@ -52,8 +52,6 @@ def print_joining_table(f):
 			continue
 
 		u = int (fields[0], 16)
-		if u == 0x200C or u == 0x200D:
-			continue
 
 		if fields[3] in ["ALAPH", "DALATH RISH"]:
 			value = "JOINING_GROUP_" + fields[3].replace(' ', '_')
diff --git a/src/hb-ot-shape-complex-arabic-table.hh b/src/hb-ot-shape-complex-arabic-table.hh
index 0a61d8f..77dfc6e 100644
--- a/src/hb-ot-shape-complex-arabic-table.hh
+++ b/src/hb-ot-shape-complex-arabic-table.hh
@@ -77,7 +77,13 @@ static const uint8_t joining_table[] =
 
   /* 08A0 */ D,X,D,D,D,D,D,D,D,D,R,R,R,
 
-}; /* Table items: 685; occupancy: 45% */
+#define joining_offset_0x200c 685
+
+  /* General Punctuation */
+
+  /* 2000 */                         U,C,
+
+}; /* Table items: 687; occupancy: 45% */
 
 
 static unsigned int
@@ -89,6 +95,10 @@ joining_type (hb_codepoint_t u)
       if (0x0600 <= u && u <= 0x08AC) return joining_table[u - 0x0600 + joining_offset_0x0600];
       break;
 
+    case 0x2:
+      if (0x200C <= u && u <= 0x200D) return joining_table[u - 0x200C + joining_offset_0x200c];
+      break;
+
     default:
       break;
   }
diff --git a/src/hb-ot-shape-complex-arabic.cc b/src/hb-ot-shape-complex-arabic.cc
index 61a55ef..4ce8478 100644
--- a/src/hb-ot-shape-complex-arabic.cc
+++ b/src/hb-ot-shape-complex-arabic.cc
@@ -83,11 +83,6 @@ static unsigned int get_joining_type (hb_codepoint_t u, hb_unicode_general_categ
       return JOINING_TYPE_D;
   }
 
-  if (unlikely (hb_in_range<hb_codepoint_t> (u, 0x200C, 0x200D)))
-  {
-    return u == 0x200C ? JOINING_TYPE_U : JOINING_TYPE_C;
-  }
-
   return (FLAG(gen_cat) & (FLAG(HB_UNICODE_GENERAL_CATEGORY_NON_SPACING_MARK) | FLAG(HB_UNICODE_GENERAL_CATEGORY_ENCLOSING_MARK) | FLAG(HB_UNICODE_GENERAL_CATEGORY_FORMAT))) ?
 	 JOINING_TYPE_T : JOINING_TYPE_U;
 }
commit 2390d9b67e1dfeccd3f0850d1304c52b54817ca0
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sat Jun 21 14:07:00 2014 -0600

    [arabic-table] Further tune
    
    In anticipation of Unicode 7.0 data coming in the next commit.

diff --git a/src/gen-arabic-table.py b/src/gen-arabic-table.py
index 1596126..ce80cc8 100755
--- a/src/gen-arabic-table.py
+++ b/src/gen-arabic-table.py
@@ -73,11 +73,12 @@ def print_joining_table(f):
 
 	uu = sorted(values.keys())
 	num = len(values)
+	all_blocks = set([blocks[u] for u in uu])
 
 	last = -1
 	ranges = []
 	for u in uu:
-		if u - last <= 1+16*3:
+		if u - last <= 1+16*5:
 			ranges[-1][-1] = u
 		else:
 			ranges.append([u,u])
@@ -101,7 +102,10 @@ def print_joining_table(f):
 			if block != last_block or u == start:
 				if u != start:
 					print
-				print "\n  /* %s */" % block
+				if block in all_blocks:
+					print "\n  /* %s */" % block
+				else:
+					print "\n  /* FILLER */"
 				last_block = block
 				if u % 32 != 0:
 					print
@@ -119,7 +123,7 @@ def print_joining_table(f):
 	print "}; /* Table items: %d; occupancy: %d%% */" % (offset, occupancy)
 	print
 
-	page_bits = 8
+	page_bits = 12;
 	print
 	print "static unsigned int"
 	print "joining_type (hb_codepoint_t u)"
diff --git a/src/hb-ot-shape-complex-arabic-table.hh b/src/hb-ot-shape-complex-arabic-table.hh
index 877625a..0a61d8f 100644
--- a/src/hb-ot-shape-complex-arabic-table.hh
+++ b/src/hb-ot-shape-complex-arabic-table.hh
@@ -52,45 +52,41 @@ static const uint8_t joining_table[] =
   /* 0740 */                                 D,D,D,D,D,D,D,D,D,R,R,R,D,D,D,D,
   /* 0760 */ D,D,D,D,D,D,D,D,D,D,D,R,R,D,D,D,D,R,D,R,R,D,D,D,R,R,D,D,D,D,D,D,
 
-#define joining_offset_0x07ca 384
+  /* FILLER */
+
+  /* 0780 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
+  /* 07A0 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
 
   /* NKo */
 
-  /* 07C0 */                     D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,
-  /* 07E0 */ D,D,D,D,D,D,D,D,D,D,D,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,C,
+  /* 07C0 */ X,X,X,X,X,X,X,X,X,X,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,D,
+  /* 07E0 */ D,D,D,D,D,D,D,D,D,D,D,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,C,X,X,X,X,X,
 
-#define joining_offset_0x0840 433
+  /* FILLER */
 
-  /* Mandaic */
+  /* 0800 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
+  /* 0820 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
 
-  /* 0840 */ R,D,D,D,D,D,R,D,D,R,D,D,D,D,D,R,D,D,D,D,R,D,U,U,U,
+  /* Mandaic */
 
-#define joining_offset_0x08a0 458
+  /* 0840 */ R,D,D,D,D,D,R,D,D,R,D,D,D,D,D,R,D,D,D,D,R,D,U,U,U,X,X,X,X,X,X,X,
+  /* 0860 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
+  /* 0880 */ X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,X,
 
   /* Arabic Extended-A */
 
   /* 08A0 */ D,X,D,D,D,D,D,D,D,D,R,R,R,
 
-}; /* Table items: 471; occupancy: 66% */
+}; /* Table items: 685; occupancy: 45% */
 
 
 static unsigned int
 joining_type (hb_codepoint_t u)
 {
-  switch (u >> 8)
+  switch (u >> 12)
   {
-    case 0x6:
-      if (0x0600 <= u && u <= 0x077F) return joining_table[u - 0x0600 + joining_offset_0x0600];
-      break;
-
-    case 0x7:
-      if (0x0600 <= u && u <= 0x077F) return joining_table[u - 0x0600 + joining_offset_0x0600];
-      if (0x07CA <= u && u <= 0x07FA) return joining_table[u - 0x07CA + joining_offset_0x07ca];
-      break;
-
-    case 0x8:
-      if (0x0840 <= u && u <= 0x0858) return joining_table[u - 0x0840 + joining_offset_0x0840];
-      if (0x08A0 <= u && u <= 0x08AC) return joining_table[u - 0x08A0 + joining_offset_0x08a0];
+    case 0x0:
+      if (0x0600 <= u && u <= 0x08AC) return joining_table[u - 0x0600 + joining_offset_0x0600];
       break;
 
     default:


More information about the HarfBuzz mailing list