Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit dc2fb2b

Browse filesBrowse files
committed
Use FontsInterface for agg backend
1 parent e877533 commit dc2fb2b
Copy full SHA for dc2fb2b

File tree

Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed

‎lib/matplotlib/backends/backend_agg.py

Copy file name to clipboardExpand all lines: lib/matplotlib/backends/backend_agg.py
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@
3535
from matplotlib.backend_bases import (
3636
_Backend, _check_savefig_extra_args, FigureCanvasBase, FigureManagerBase,
3737
RendererBase)
38-
from matplotlib.font_manager import findfont, get_font
38+
from matplotlib.font_manager import get_font, find_fontsprop
3939
from matplotlib.ft2font import (LOAD_FORCE_AUTOHINT, LOAD_NO_HINTING,
4040
LOAD_DEFAULT, LOAD_NO_AUTOHINT)
4141
from matplotlib.mathtext import MathTextParser
@@ -251,8 +251,8 @@ def _get_agg_font(self, prop):
251251
"""
252252
Get the font for text instance t, caching for efficiency
253253
"""
254-
fname = findfont(prop)
255-
font = get_font(fname)
254+
finterface = find_fontsprop(prop)
255+
font = get_font(finterface)
256256

257257
font.clear()
258258
size = prop.get_size_in_points()

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.