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 3215acb

Browse filesBrowse files
story645oscargus
andcommitted
swap xkcd script for humor sans
add xkcd-script font to doc build Co-authored-by: Oscar Gustafsson <oscar.gustafsson@gmail.com>
1 parent ea66786 commit 3215acb
Copy full SHA for 3215acb

File tree

8 files changed

+17
-16
lines changed
Filter options

8 files changed

+17
-16
lines changed

‎.circleci/config.yml

Copy file name to clipboardExpand all lines: .circleci/config.yml
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ commands:
4949
ffmpeg \
5050
fonts-crosextra-carlito \
5151
fonts-freefont-otf \
52-
fonts-humor-sans \
5352
fonts-noto-cjk \
5453
fonts-wqy-zenhei \
5554
graphviz \
@@ -67,15 +66,16 @@ commands:
6766
fonts-install:
6867
steps:
6968
- restore_cache:
70-
key: fonts-2
69+
key: fonts-3
7170
- run:
7271
name: Install custom fonts
7372
command: |
7473
mkdir -p ~/.local/share/fonts
7574
wget -nc https://github.com/google/fonts/blob/master/ofl/felipa/Felipa-Regular.ttf?raw=true -O ~/.local/share/fonts/Felipa-Regular.ttf || true
75+
wget -nc https://github.com/ipython/xkcd-font/blob/master/xkcd-script/font/xkcd-script.ttf || true
7676
fc-cache -f -v
7777
- save_cache:
78-
key: fonts-2
78+
key: fonts-3
7979
paths:
8080
- ~/.local/share/fonts/
8181

‎.devcontainer/devcontainer.json

Copy file name to clipboardExpand all lines: .devcontainer/devcontainer.json
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"features": {
88
"ghcr.io/devcontainers/features/desktop-lite:1": {},
99
"ghcr.io/rocker-org/devcontainer-features/apt-packages:1": {
10-
"packages": "inkscape,ffmpeg,dvipng,lmodern,cm-super,texlive-latex-base,texlive-latex-extra,texlive-fonts-recommended,texlive-latex-recommended,texlive-pictures,texlive-xetex,fonts-wqy-zenhei,graphviz,fonts-crosextra-carlito,fonts-freefont-otf,fonts-humor-sans,fonts-noto-cjk,optipng"
10+
"packages": "inkscape,ffmpeg,dvipng,lmodern,cm-super,texlive-latex-base,texlive-latex-extra,texlive-fonts-recommended,texlive-latex-recommended,texlive-pictures,texlive-xetex,fonts-wqy-zenhei,graphviz,fonts-crosextra-carlito,fonts-freefont-otf,fonts-comic-neue,fonts-noto-cjk,optipng"
1111
}
1212
},
1313
"onCreateCommand": ".devcontainer/setup.sh",

‎doc/devel/dependencies.rst

Copy file name to clipboardExpand all lines: doc/devel/dependencies.rst
+3-2Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -419,6 +419,7 @@ Optional
419419

420420
* `Inkscape <https://inkscape.org>`_
421421
* `optipng <http://optipng.sourceforge.net>`_
422-
* the font "Humor Sans" (aka the "XKCD" font), or the free alternative
423-
`Comic Neue <http://comicneue.com/>`_
422+
* the font `xkcd script`_ or `Comic Neue <http://comicneue.com/>`_
424423
* the font "Times New Roman"
424+
425+
.. _`xkcd script`: https://github.com/dummy-index/xkcd-font/raw/brushup/xkcd-script/font/xkcd-script.ttf

‎lib/matplotlib/mpl-data/matplotlibrc

Copy file name to clipboardExpand all lines: lib/matplotlib/mpl-data/matplotlibrc
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@
269269
#font.serif: DejaVu Serif, Bitstream Vera Serif, Computer Modern Roman, New Century Schoolbook, Century Schoolbook L, Utopia, ITC Bookman, Bookman, Nimbus Roman No9 L, Times New Roman, Times, Palatino, Charter, serif
270270
#font.sans-serif: DejaVu Sans, Bitstream Vera Sans, Computer Modern Sans Serif, Lucida Grande, Verdana, Geneva, Lucid, Arial, Helvetica, Avant Garde, sans-serif
271271
#font.cursive: Apple Chancery, Textile, Zapf Chancery, Sand, Script MT, Felipa, Comic Neue, Comic Sans MS, cursive
272-
#font.fantasy: Chicago, Charcoal, Impact, Western, Humor Sans, xkcd, fantasy
272+
#font.fantasy: Chicago, Charcoal, Impact, Western, xkcd script, fantasy
273273
#font.monospace: DejaVu Sans Mono, Bitstream Vera Sans Mono, Computer Modern Typewriter, Andale Mono, Nimbus Mono L, Courier New, Courier, Fixed, Terminal, monospace
274274

275275

‎lib/matplotlib/mpl-data/stylelib/classic.mplstyle

Copy file name to clipboardExpand all lines: lib/matplotlib/mpl-data/stylelib/classic.mplstyle
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ font.size : 12.0
9191
font.serif : DejaVu Serif, New Century Schoolbook, Century Schoolbook L, Utopia, ITC Bookman, Bookman, Nimbus Roman No9 L, Times New Roman, Times, Palatino, Charter, serif
9292
font.sans-serif: DejaVu Sans, Lucida Grande, Verdana, Geneva, Lucid, Arial, Helvetica, Avant Garde, sans-serif
9393
font.cursive : Apple Chancery, Textile, Zapf Chancery, Sand, Script MT, Felipa, cursive
94-
font.fantasy : Comic Sans MS, Chicago, Charcoal, ImpactWestern, Humor Sans, fantasy
94+
font.fantasy : Comic Sans MS, Chicago, Charcoal, ImpactWestern, xkcd script, fantasy
9595
font.monospace : DejaVu Sans Mono, Andale Mono, Nimbus Mono L, Courier New, Courier, Fixed, Terminal, monospace
9696

9797
### TEXT

‎lib/matplotlib/pyplot.py

Copy file name to clipboardExpand all lines: lib/matplotlib/pyplot.py
+6-6Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -706,11 +706,12 @@ def xkcd(
706706
scale: float = 1, length: float = 100, randomness: float = 2
707707
) -> ExitStack:
708708
"""
709-
Turn on `xkcd <https://xkcd.com/>`_ sketch-style drawing mode. This will
710-
only have effect on things drawn after this function is called.
709+
Turn on `xkcd <https://xkcd.com/>`_ sketch-style drawing mode.
711710
712-
For best results, the "Humor Sans" font should be installed: it is
713-
not included with Matplotlib.
711+
This will only have an effect on things drawn after this function is called.
712+
713+
For best results, install the `xkcd script <https://github.com/ipython/xkcd-font/>`_
714+
font; xkcd fonts are not packaged with Matplotlib.
714715
715716
Parameters
716717
----------
@@ -749,8 +750,7 @@ def xkcd(
749750

750751
from matplotlib import patheffects
751752
rcParams.update({
752-
'font.family': ['xkcd', 'xkcd Script', 'Humor Sans', 'Comic Neue',
753-
'Comic Sans MS'],
753+
'font.family': ['xkcd', 'xkcd Script', 'Comic Neue', 'Comic Sans MS'],
754754
'font.size': 14.0,
755755
'path.sketch': (scale, length, randomness),
756756
'path.effects': [

‎lib/matplotlib/tests/test_axes.py

Copy file name to clipboardExpand all lines: lib/matplotlib/tests/test_axes.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8848,7 +8848,7 @@ def test_tick_param_labelfont():
88488848
fig, ax = plt.subplots()
88498849
ax.plot([1, 2, 3, 4], [1, 2, 3, 4])
88508850
ax.set_xlabel('X label in Impact font', fontname='Impact')
8851-
ax.set_ylabel('Y label in Humor Sans', fontname='Humor Sans')
8851+
ax.set_ylabel('Y label in xkcd script', fontname='xkcd script')
88528852
ax.tick_params(color='r', labelfontfamily='monospace')
88538853
plt.title('Title in sans-serif')
88548854
for text in ax.get_xticklabels():

‎lib/matplotlib/textpath.py

Copy file name to clipboardExpand all lines: lib/matplotlib/textpath.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ def get_text_path(self, prop, s, ismath=False):
9999
from matplotlib.text import TextToPath
100100
from matplotlib.font_manager import FontProperties
101101
102-
fp = FontProperties(family="Humor Sans", style="italic")
102+
fp = FontProperties(family="Comic Neue", style="italic")
103103
verts, codes = TextToPath().get_text_path(fp, "ABC")
104104
path = Path(verts, codes, closed=False)
105105

0 commit comments

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