summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog6
-rw-r--r--ChangeLog.pre-1-106
-rw-r--r--ChangeLog.pre-1-86
-rw-r--r--modules/indic/indic-fc.c13
-rw-r--r--modules/indic/indic-ot.h19
5 files changed, 46 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index ab682f34..1aaa4269 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+Wed Dec 15 18:50:18 2004 Owen Taylor <otaylor@redhat.com>
+
+ * modules/indic/indic-fc.c modules/indic/indic-ot.h:
+ Force zero-width marks to glyph index 0 so they
+ won't be drawn. (#145233, Aniruddha Shankar)
+
Wed Dec 15 11:15:37 2004 Owen Taylor <otaylor@redhat.com>
* configure.in modules/Makefile.am modules/tibetan/*:
diff --git a/ChangeLog.pre-1-10 b/ChangeLog.pre-1-10
index ab682f34..1aaa4269 100644
--- a/ChangeLog.pre-1-10
+++ b/ChangeLog.pre-1-10
@@ -1,3 +1,9 @@
+Wed Dec 15 18:50:18 2004 Owen Taylor <otaylor@redhat.com>
+
+ * modules/indic/indic-fc.c modules/indic/indic-ot.h:
+ Force zero-width marks to glyph index 0 so they
+ won't be drawn. (#145233, Aniruddha Shankar)
+
Wed Dec 15 11:15:37 2004 Owen Taylor <otaylor@redhat.com>
* configure.in modules/Makefile.am modules/tibetan/*:
diff --git a/ChangeLog.pre-1-8 b/ChangeLog.pre-1-8
index ab682f34..1aaa4269 100644
--- a/ChangeLog.pre-1-8
+++ b/ChangeLog.pre-1-8
@@ -1,3 +1,9 @@
+Wed Dec 15 18:50:18 2004 Owen Taylor <otaylor@redhat.com>
+
+ * modules/indic/indic-fc.c modules/indic/indic-ot.h:
+ Force zero-width marks to glyph index 0 so they
+ won't be drawn. (#145233, Aniruddha Shankar)
+
Wed Dec 15 11:15:37 2004 Owen Taylor <otaylor@redhat.com>
* configure.in modules/Makefile.am modules/tibetan/*:
diff --git a/modules/indic/indic-fc.c b/modules/indic/indic-fc.c
index 721e974b..788bc64f 100644
--- a/modules/indic/indic-fc.c
+++ b/modules/indic/indic-fc.c
@@ -248,6 +248,7 @@ get_gpos_ruleset (FT_Face face, PangoIndicInfo *indic_info)
return ruleset;
}
+
static void
set_glyphs (PangoFont *font, FT_Face face, const gunichar *wcs, gulong *tags, glong n_glyphs, PangoOTBuffer *buffer)
{
@@ -257,10 +258,14 @@ set_glyphs (PangoFont *font, FT_Face face, const gunichar *wcs, gulong *tags, gl
for (i = 0; i < n_glyphs; i += 1)
{
- pango_ot_buffer_add_glyph (buffer,
- FT_Get_Char_Index (face, wcs[i]),
- tags[i],
- i);
+ guint glyph;
+
+ if (ZERO_WIDTH_CHAR (wcs[i]))
+ glyph = 0;
+ else
+ glyph = FT_Get_Char_Index (face, wcs[i]);
+
+ pango_ot_buffer_add_glyph (buffer, glyph, tags[i], i);
}
}
diff --git a/modules/indic/indic-ot.h b/modules/indic/indic-ot.h
index f7d13559..d6b498b3 100644
--- a/modules/indic/indic-ot.h
+++ b/modules/indic/indic-ot.h
@@ -175,6 +175,25 @@ enum indic_glyph_property_
#define HAS_BELOW_BASE_FORM(charClass) ((charClass & CF_BELOW_BASE) != 0)
+/* This macro definition is shared with basic-common.h
+ *
+ * Zero Width characters:
+ *
+ * 200B ZERO WIDTH SPACE
+ * 200C ZERO WIDTH NON-JOINER
+ * 200D ZERO WIDTH JOINER
+ * 200E LEFT-TO-RIGHT MARK
+ * 200F RIGHT-TO-LEFT MARK
+ * 202A LEFT-TO-RIGHT EMBEDDING
+ * 202B RIGHT-TO-LEFT EMBEDDING
+ * 202C POP DIRECTIONAL FORMATTING
+ * 202D LEFT-TO-RIGHT OVERRIDE
+ * 202E RIGHT-TO-LEFT OVERRIDE
+ * FEFF ZERO WIDTH NO-BREAK SPACE
+ */
+#define ZERO_WIDTH_CHAR(wc) \
+ (((wc) >= 0x200B && (wc) <= 0x200F) || ((wc) >= 0x202A && (wc) <= 0x202E) || ((wc) == 0xFEFF))
+
struct _IndicOTClassTable
{
gunichar firstChar;