Matplotlib: Times New Roman appears bold

后端 未结 8 1729
醉梦人生
醉梦人生 2021-02-14 23:40

For some reason when using Times New Roman in my mpl plots it appears bold. Other fonts are OK.

Here is a minimal example, and the result (inside a Word doc

8条回答
  •  野趣味
    野趣味 (楼主)
    2021-02-14 23:53

    Using python 3.7 on Windows 10, Jupyter Notebook, no Anaconda installed.

    Simply adjusted the font sequence C:\Windows\Fonts\Times New Roman as suggested above doesn't work here.

    Under C:\User\Name\.matplolib, find a JSON File (text file) named fontlist-v300.

    Delete

    {
          "fname": "C:\\WINDOWS\\Fonts\\timesbd.ttf",
          "name": "Times New Roman",
          "style": "normal",
          "variant": "normal",
          "weight": "roman",
          "stretch": "normal",
          "size": "scalable",
          "__class__": "FontEntry"
    }
    

    in the text file works for me.

    Not a good way, though.

提交回复
热议问题