Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/blenfont')
-rw-r--r--source/blender/blenfont/intern/blf_font.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenfont/intern/blf_font.c b/source/blender/blenfont/intern/blf_font.c
index 5f904d86b03..b958f3c2336 100644
--- a/source/blender/blenfont/intern/blf_font.c
+++ b/source/blender/blenfont/intern/blf_font.c
@@ -70,7 +70,7 @@ static ft_pix blf_font_width_max_ft_pix(struct FontBLF *font);
/* Return glyph id from charcode. */
uint blf_get_char_index(struct FontBLF *font, uint charcode)
{
- return FT_Get_Char_Index(font->face, charcode);
+ return blf_ensure_face(font) ? FT_Get_Char_Index(font->face, charcode) : 0;
}
/* -------------------------------------------------------------------- */