Skip to content

Commit 03d0e88

Browse files
committed
Issue 2008: fix initial font loading in windows where there is a registry entry but the actual file is missing
1 parent 788852f commit 03d0e88

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src_py/sysfont.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,8 @@ def initsysfonts_win32():
8787
# Some are named A & B, both names should be processed separately
8888
# Ex: the main Cambria file is marked as "Cambria & Cambria Math"
8989
for name in name.split("&"):
90-
_parse_font_entry_win(name, font, fonts)
90+
if os.path.exists(font): # check if the file actually exists
91+
_parse_font_entry_win(name, font, fonts)
9192

9293
return fonts
9394

0 commit comments

Comments
 (0)