be more forgiving in opengl mode when a font color isn't available and use the default font
This commit is contained in:
parent
ccdd49042f
commit
c8b935b322
1 changed files with 8 additions and 1 deletions
|
@ -463,7 +463,14 @@ CGraphic *CFont::GetFontColorGraphic(const CFontColor &fontColor) const
|
|||
{
|
||||
#if defined(USE_OPENGL) || defined(USE_GLES)
|
||||
if (UseOpenGL) {
|
||||
return FontColorGraphics[this][&fontColor];
|
||||
CGraphic* fontColorG = FontColorGraphics[this][&fontColor];
|
||||
if (!fontColorG) {
|
||||
#ifdef DEBUG
|
||||
fprintf(stderr, "Could not load font color %s for font %s\n", fontColor.Ident, this->Ident);
|
||||
#endif
|
||||
return this->G;
|
||||
}
|
||||
return fontColorG;
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue