Commit 1a26888d authored by David Turner's avatar David Turner
Browse files

some changes to ensure that the code compiles

cleanly when TT_CONFIG_OPTION_POSTSCRIPT_NAMES
is undefined..
parent a8635cc6
......@@ -24,6 +24,7 @@
#include <tttags.h>
#include <sfnt.h>
#include <psnames.h>
#include <ttobjs.h>
#include <ttpload.h>
......@@ -226,9 +227,10 @@
TT_Long face_index,
TT_Face face )
{
TT_Error error;
TT_ULong format_tag;
SFNT_Interface* sfnt;
TT_Error error;
TT_ULong format_tag;
SFNT_Interface* sfnt;
PSNames_Interface* psnames;
sfnt = (SFNT_Interface*)face->sfnt;
if (!sfnt)
......@@ -248,6 +250,18 @@
face->goto_table = sfnt->goto_table;
}
psnames = (PSNames_Interface*)face->psnames;
if (!psnames)
{
/* look-up the PSNames driver */
FT_Driver psnames_driver;
psnames_driver = FT_Get_Driver( face->root.driver->library, "psnames" );
if (psnames_driver)
face->psnames = (PSNames_Interface*)
(psnames_driver->interface.format_interface);
}
/* create input stream from resource */
if ( FILE_Seek(0) )
goto Exit;
......@@ -291,13 +305,17 @@
LOAD_( charmaps ) ||
LOAD_( names ) ||
LOAD_( os2 ) ||
LOAD_( psnames ) ||
LOAD_( psnames ) )
goto Exit;
/* the optional tables */
/* the optional tables */
/* embedded bitmap support. */
#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
LOAD_( sbits ) ||
if (sfnt->load_sbits && LOAD_(sbits)) goto Exit;
#endif
LOAD_( hdmx ) ||
if ( LOAD_( hdmx ) ||
LOAD_( gasp ) ||
LOAD_( kerning ) ||
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment