summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2003-07-26 03:03:21 +0000
committerOwen Taylor <otaylor@src.gnome.org>2003-07-26 03:03:21 +0000
commit9efede3457787f587603d76957e91aa989c210a2 (patch)
tree97d9a9d6d74a829bd88df1ddd3f050bb33fa013f
parentd0563f12a799db1c26d775438146e77ba8343613 (diff)
downloadpango-9efede3457787f587603d76957e91aa989c210a2.tar.gz
Add GPOS_LOOKUP_EXTENSION, GSUB_LOOKUP_EXTENSION, which allow lookup
Fri Jul 25 22:59:13 2003 Owen Taylor <otaylor@redhat.com> * pango/opentype/ftx{gpos,gsub}.h pango/opentype/ftxgdef.c: Add GPOS_LOOKUP_EXTENSION, GSUB_LOOKUP_EXTENSION, which allow lookup information to be stored at 32-bit offets via a double indirection. (From FreeType, Werner Lemberg, 2001-08-08)
-rw-r--r--ChangeLog8
-rw-r--r--ChangeLog.pre-1-108
-rw-r--r--ChangeLog.pre-1-48
-rw-r--r--ChangeLog.pre-1-68
-rw-r--r--ChangeLog.pre-1-88
-rw-r--r--pango/opentype/ftxgpos.h17
-rw-r--r--pango/opentype/ftxgsub.h1
-rw-r--r--pango/opentype/ftxopen.c19
8 files changed, 69 insertions, 8 deletions
diff --git a/ChangeLog b/ChangeLog
index d4bfab53..40049240 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+Fri Jul 25 22:59:13 2003 Owen Taylor <otaylor@redhat.com>
+
+ * pango/opentype/ftx{gpos,gsub}.h pango/opentype/ftxgdef.c:
+ Add GPOS_LOOKUP_EXTENSION, GSUB_LOOKUP_EXTENSION, which
+ allow lookup information to be stored at 32-bit offets
+ via a double indirection. (From FreeType, Werner Lemberg,
+ 2001-08-08)
+
Fri Jul 25 22:25:48 2003 Owen Taylor <otaylor@redhat.com>
* pango/opentype/ftxgsub.c (Lookup_ContextSubst2,
diff --git a/ChangeLog.pre-1-10 b/ChangeLog.pre-1-10
index d4bfab53..40049240 100644
--- a/ChangeLog.pre-1-10
+++ b/ChangeLog.pre-1-10
@@ -1,3 +1,11 @@
+Fri Jul 25 22:59:13 2003 Owen Taylor <otaylor@redhat.com>
+
+ * pango/opentype/ftx{gpos,gsub}.h pango/opentype/ftxgdef.c:
+ Add GPOS_LOOKUP_EXTENSION, GSUB_LOOKUP_EXTENSION, which
+ allow lookup information to be stored at 32-bit offets
+ via a double indirection. (From FreeType, Werner Lemberg,
+ 2001-08-08)
+
Fri Jul 25 22:25:48 2003 Owen Taylor <otaylor@redhat.com>
* pango/opentype/ftxgsub.c (Lookup_ContextSubst2,
diff --git a/ChangeLog.pre-1-4 b/ChangeLog.pre-1-4
index d4bfab53..40049240 100644
--- a/ChangeLog.pre-1-4
+++ b/ChangeLog.pre-1-4
@@ -1,3 +1,11 @@
+Fri Jul 25 22:59:13 2003 Owen Taylor <otaylor@redhat.com>
+
+ * pango/opentype/ftx{gpos,gsub}.h pango/opentype/ftxgdef.c:
+ Add GPOS_LOOKUP_EXTENSION, GSUB_LOOKUP_EXTENSION, which
+ allow lookup information to be stored at 32-bit offets
+ via a double indirection. (From FreeType, Werner Lemberg,
+ 2001-08-08)
+
Fri Jul 25 22:25:48 2003 Owen Taylor <otaylor@redhat.com>
* pango/opentype/ftxgsub.c (Lookup_ContextSubst2,
diff --git a/ChangeLog.pre-1-6 b/ChangeLog.pre-1-6
index d4bfab53..40049240 100644
--- a/ChangeLog.pre-1-6
+++ b/ChangeLog.pre-1-6
@@ -1,3 +1,11 @@
+Fri Jul 25 22:59:13 2003 Owen Taylor <otaylor@redhat.com>
+
+ * pango/opentype/ftx{gpos,gsub}.h pango/opentype/ftxgdef.c:
+ Add GPOS_LOOKUP_EXTENSION, GSUB_LOOKUP_EXTENSION, which
+ allow lookup information to be stored at 32-bit offets
+ via a double indirection. (From FreeType, Werner Lemberg,
+ 2001-08-08)
+
Fri Jul 25 22:25:48 2003 Owen Taylor <otaylor@redhat.com>
* pango/opentype/ftxgsub.c (Lookup_ContextSubst2,
diff --git a/ChangeLog.pre-1-8 b/ChangeLog.pre-1-8
index d4bfab53..40049240 100644
--- a/ChangeLog.pre-1-8
+++ b/ChangeLog.pre-1-8
@@ -1,3 +1,11 @@
+Fri Jul 25 22:59:13 2003 Owen Taylor <otaylor@redhat.com>
+
+ * pango/opentype/ftx{gpos,gsub}.h pango/opentype/ftxgdef.c:
+ Add GPOS_LOOKUP_EXTENSION, GSUB_LOOKUP_EXTENSION, which
+ allow lookup information to be stored at 32-bit offets
+ via a double indirection. (From FreeType, Werner Lemberg,
+ 2001-08-08)
+
Fri Jul 25 22:25:48 2003 Owen Taylor <otaylor@redhat.com>
* pango/opentype/ftxgsub.c (Lookup_ContextSubst2,
diff --git a/pango/opentype/ftxgpos.h b/pango/opentype/ftxgpos.h
index 56ffb785..408bcb0a 100644
--- a/pango/opentype/ftxgpos.h
+++ b/pango/opentype/ftxgpos.h
@@ -32,14 +32,15 @@ extern "C" {
/* Lookup types for glyph positioning */
-#define GPOS_LOOKUP_SINGLE 1
-#define GPOS_LOOKUP_PAIR 2
-#define GPOS_LOOKUP_CURSIVE 3
-#define GPOS_LOOKUP_MARKBASE 4
-#define GPOS_LOOKUP_MARKLIG 5
-#define GPOS_LOOKUP_MARKMARK 6
-#define GPOS_LOOKUP_CONTEXT 7
-#define GPOS_LOOKUP_CHAIN 8
+#define GPOS_LOOKUP_SINGLE 1
+#define GPOS_LOOKUP_PAIR 2
+#define GPOS_LOOKUP_CURSIVE 3
+#define GPOS_LOOKUP_MARKBASE 4
+#define GPOS_LOOKUP_MARKLIG 5
+#define GPOS_LOOKUP_MARKMARK 6
+#define GPOS_LOOKUP_CONTEXT 7
+#define GPOS_LOOKUP_CHAIN 8
+#define GPOS_LOOKUP_EXTENSION 9
/* A pointer to a function which loads a glyph. Its parameters are
diff --git a/pango/opentype/ftxgsub.h b/pango/opentype/ftxgsub.h
index 3f4f8ada..8951e441 100644
--- a/pango/opentype/ftxgsub.h
+++ b/pango/opentype/ftxgsub.h
@@ -38,6 +38,7 @@ extern "C" {
#define GSUB_LOOKUP_LIGATURE 4
#define GSUB_LOOKUP_CONTEXT 5
#define GSUB_LOOKUP_CHAIN 6
+#define GSUB_LOOKUP_EXTENSION 7
/* Use this if a feature applies to all glyphs */
diff --git a/pango/opentype/ftxopen.c b/pango/opentype/ftxopen.c
index ba605bd7..5d9cfad3 100644
--- a/pango/opentype/ftxopen.c
+++ b/pango/opentype/ftxopen.c
@@ -584,6 +584,8 @@
TTO_SubTable* st;
+ Bool is_extension = FALSE;
+
base_offset = FILE_Pos();
@@ -603,6 +605,10 @@
st = l->SubTable;
+ if ( ( type == GSUB && l->LookupType == GSUB_LOOKUP_EXTENSION ) ||
+ ( type == GPOS && l->LookupType == GPOS_LOOKUP_EXTENSION ) )
+ is_extension = TRUE;
+
for ( n = 0; n < count; n++ )
{
if ( ACCESS_Frame( 2L ) )
@@ -613,6 +619,19 @@
FORGET_Frame();
cur_offset = FILE_Pos();
+
+ if ( is_extension )
+ {
+ if ( FILE_Seek( new_offset ) || ACCESS_Frame( 8L ) )
+ goto Fail;
+
+ (void)GET_UShort(); /* format should be 1 */
+ l->LookupType = GET_UShort();
+ new_offset = GET_ULong() + base_offset;
+
+ FORGET_Frame();
+ }
+
if ( FILE_Seek( new_offset ) ||
( error = Load_SubTable( &st[n], stream,
type, l->LookupType ) ) != TT_Err_Ok )