From 794a37561c2fc132eb0e7024469dd592ace21000 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Longtsing=20=C2=B7=20Wang?= Date: Sun, 10 Sep 2023 01:10:54 +0800 Subject: [PATCH] Check the availability of Arial font (#97) --- cinrad/visualize/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cinrad/visualize/__init__.py b/cinrad/visualize/__init__.py index 6e43f10..e89830f 100644 --- a/cinrad/visualize/__init__.py +++ b/cinrad/visualize/__init__.py @@ -3,6 +3,7 @@ import matplotlib -matplotlib.rc("font", family="Arial") +if 'Arial' in matplotlib.rc_params()['font.sans-serif']: + matplotlib.rc("font", family="Arial") from cinrad.visualize.ppi import * from cinrad.visualize.rhi import *