#define _OTF_H_
/* Version name of this library. */
-#define LIBOTF_VERSION "0.9.1"
+#define LIBOTF_VERSION "0.9.3"
/* Major version number. */
#define LIBOTF_MAJOR_VERSION 0
/* Minor version number. */
#define LIBOTF_MINOR_VERSION 9
/* Release (i.e. patch level) number. */
-#define LIBOTF_RELEASE_NUMBER 1
+#define LIBOTF_RELEASE_NUMBER 3
/***
Table of contents:
(3-4) OTF_drive_gsub()
(3-5) OTF_drive_gpos()
(3-6) OTF_drive_tables()
+ (3-7) OTF_get_unicode()
+ (3-8) OTF_drive_gsub_alternate()
(4) API for error handling
(4-1) Error codes
typedef struct
{
- unsigned subHeaderKeys[256];
+ unsigned short subHeaderKeys[256];
+ int subHeaderCount;
OTF_cmapSubHeader *subHeaders;
- unsigned *glyphIndexArray;
+ int glyphIndexCount;
+ OTF_GlyphID *glyphIndexArray;
} OTF_EncodingSubtable2;
typedef struct
/* How many glyphs are allocated at the memory pointed by the member
<glyphs>. */
int size;
- /* How many glyphs contains valid information. */
+ /* How many glyphs contain valid information. */
int used;
/* Array of glyphs. It must be allocated by malloc(). The
functions otf_drive_XXX() may reallocate it and increase the
font $OTF, and by using features the font has for script $SCRIPT
and language system $LANGSYS, update member <glyphs> of the glyph
string $GSTRING. It may substitute, delete, insert glyphs in that
- array. $FEATURES is a list of features to apply. */
+ array. $FEATURES is a list of features to apply. This doesn't
+ perform a lookup of type 3 (Alternate Substitution). For that,
+ use OTF_drive_gsub_alternate(). */
extern int OTF_drive_gsub (OTF *otf, OTF_GlyphString *gstring,
char *script, char *language, char *features);
extern int OTF_get_unicode (OTF *otf, OTF_GlyphID code);
+/*** (3-8) OTF_drive_gsub_alternate() */
+
+/***
+ Find alternate glyphs.
+
+ This is like OTF_drive_gsub(), but perform only a lookup of type 3
+ (Alternate Substituion). */
+
+extern int OTF_drive_gsub_alternate (OTF *otf, OTF_GlyphString *gstring,
+ char *script, char *language,
+ char *features);
+
/*** (4) API for error handling ***/
/*** (4-1) Error codes ***/