diff options
Diffstat (limited to 'source/blender/blenlib/intern/freetypefont.c')
-rw-r--r-- | source/blender/blenlib/intern/freetypefont.c | 25 |
1 files changed, 7 insertions, 18 deletions
diff --git a/source/blender/blenlib/intern/freetypefont.c b/source/blender/blenlib/intern/freetypefont.c index a97f2460ba1..0f2a6179964 100644 --- a/source/blender/blenlib/intern/freetypefont.c +++ b/source/blender/blenlib/intern/freetypefont.c @@ -30,8 +30,6 @@ * Code that uses exotic character maps is present but commented out. */ -#ifdef WITH_FREETYPE2 - #ifdef WIN32 #pragma warning (disable:4244) #endif @@ -49,9 +47,10 @@ #include "BLI_blenlib.h" #include "BLI_arithb.h" -#include "BIF_toolbox.h" +//XXX #include "BIF_toolbox.h" #include "BKE_global.h" +#include "BKE_font.h" #include "BKE_utildefines.h" #include "DNA_vfont_types.h" @@ -282,13 +281,7 @@ int objchr_to_ftvfontdata(VFont *vfont, FT_ULong charcode) struct TmpFont *tf; // Find the correct FreeType font - tf= G.ttfdata.first; - while(tf) - { - if(tf->vfont == vfont) - break; - tf= tf->next; - } + tf= vfont_find_tmpfont(vfont); // What, no font found. Something strange here if(!tf) return FALSE; @@ -432,7 +425,7 @@ static int check_freetypefont(PackedFile * pf) &face ); if(err) { success = 0; - error("This is not a valid font"); + //XXX error("This is not a valid font"); } else { /* @@ -461,7 +454,7 @@ static int check_freetypefont(PackedFile * pf) if (glyph->format == ft_glyph_format_outline ) { success = 1; } else { - error("Selected Font has no outline data"); + //XXX error("Selected Font has no outline data"); success = 0; } } @@ -479,7 +472,7 @@ VFontData *BLI_vfontdata_from_freetypefont(PackedFile *pf) //init Freetype err = FT_Init_FreeType( &library); if(err) { - error("Failed to load the Freetype font library"); + //XXX error("Failed to load the Freetype font library"); return 0; } @@ -504,7 +497,7 @@ int BLI_vfontchar_from_freetypefont(VFont *vfont, unsigned long character) // Init Freetype err = FT_Init_FreeType(&library); if(err) { - error("Failed to load the Freetype font library"); + //XXX error("Failed to load the Freetype font library"); return 0; } @@ -519,10 +512,6 @@ int BLI_vfontchar_from_freetypefont(VFont *vfont, unsigned long character) return TRUE; } -#endif // WITH_FREETYPE2 - - - #if 0 // Freetype2 Outline struct |