8000 Merge pull request #13681 from meeseeksmachine/auto-backport-of-pr-13… · matplotlib/matplotlib@c28acae · GitHub
[go: up one dir, main page]

Skip to content

Commit c28acae

Browse files
authored
Merge pull request #13681 from meeseeksmachine/auto-backport-of-pr-13678-on-v3.1.x
Backport PR #13678 on branch v3.1.x (Fix font deduplication logic in createFontList.)
2 parents a64e921 + 9e5e6cd commit c28acae

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

lib/matplotlib/font_manager.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -517,8 +517,6 @@ def createFontList(fontfiles, fontext='ttf'):
517517
fname = os.path.split(fpath)[1]
518518
if fname in seen:
519519
continue
520-
else:
521-
seen.add(fname)
522520
if fontext == 'afm':
523521
try:
524522
with open(fpath, 'rb') as fh:
@@ -551,6 +549,7 @@ def createFontList(fontfiles, fontext='ttf'):
551549
continue
552550

553551
fontlist.append(prop)
552+
seen.add(fname)
554553
return fontlist
555554

556555

0 commit comments

Comments
 (0)
0