Fix confusing behavior when importing a font that doesn't exist

This commit is contained in:
Glenn Maynard
2003-10-17 23:41:16 +00:00
parent 0d594b89c0
commit bfbdd31db7
+7 -1
View File
@@ -799,7 +799,13 @@ void Font::Load(const CString &sFontOrTextureFilePath, CString sChars)
split(imports, ",", ImportList, true);
for(unsigned i = 0; i < ImportList.size(); ++i)
{
CString path = THEME->GetPathToF( ImportList[i]);
CString path = THEME->GetPathToF( ImportList[i], true );
if( path == "" )
{
LOG->Warn("Font \"%s\" imports a font \"%s\" that doesn't exist", sFontOrTextureFilePath.c_str(), ImportList[i].c_str());
continue;
}
Font subfont;
subfont.Load(path, "");
MergeFont(subfont);