- plt.rcParams['font.sans-serif'] = ['SIMHEI']
- 成功了!前面要加u
- plt.title(u"motorway 地图", fontsize=20) 附:
# 已有字体
import matplotlib.font_manager
a = sorted([f.name for f in matplotlib.font_manager.fontManager.ttflist])
for i in a:
print(i)
# 重新加载字体
from matplotlib.font_manager import _rebuild
_rebuild()
# 引入
from matplotlib import pyplot as plt
- https://blog.csdn.net/kaizei_pao/article/details/80795377
- https://blog.csdn.net/u012705410/article/details/47379957 windows