findfont: Font family 'Helvetica' not found.
Good morning,
I am developing a calendar heatmap using your package, and it appears the font you have chosen as default ('Helvetica') is no longer supported by matplotlib? Or at the very least does not work on my environment.
OS: Windows 10 Python Version: 3.9.13 calplot==0.1.7.5
Behavior:
- when returning a plot from a call to calplot.calplot(), the following warning is printed: findfont: Font family 'Helvetica' not found.
I traced the problem to line 327 in calplot.py, where the following code exists:
ylabel_kws = dict(
fontsize=30,
color='gray',
fontname='Helvetica',
fontweight='bold',
ha='center')
ylabel_kws.update(yearlabel_kws)
Changing the 'fontname' key from Helvetica to sans-serif fixed the issue.
Could you perhaps add an argument to calplot.calplot() to let us specify the font type in your next release?
Thanks.
Hi! I faced the same issue with the same release (0.1.7.5). I found that passing your desired font (in this case 'sans-serif') to the parameter yearlabel_kws can solve the problem:
calplot.calplot(events, yearlabel_kws={'fontname':'sans-serif'})
Facing same Issue!
Same issue here on Linux. Would be great to have a non-proprietary font as the default.
Hi! I faced the same issue with the same release (0.1.7.5). I found that passing your desired font (in this case
'sans-serif') to the parameteryearlabel_kwscan solve the problem:calplot.calplot(events, yearlabel_kws={'fontname':'sans-serif'})
This appears to be a working solution, thanks.