Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 2f8afae

Browse files
authored
apply black formatting
1 parent 761f3d6 commit 2f8afae

1 file changed

Lines changed: 8 additions & 8 deletions

File tree

examples/text_labels_and_annotations/font_family_rc_sgskip.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,11 @@
2727

2828
import matplotlib.pyplot as plt
2929

30-
plt.rcParams['font.family'] = 'sans-serif'
31-
plt.rcParams['font.sans-serif'] = ['Tahoma']
30+
plt.rcParams["font.family"] = "sans-serif"
31+
plt.rcParams["font.sans-serif"] = ["Tahoma"]
3232

3333
fig, ax = plt.subplots(figsize=(6, 1), facecolor="#eefade")
34-
ax.text(0.01, 0.2, "Hello World! 01", size = 40)
34+
ax.text(0.01, 0.2, "Hello World! 01", size=40)
3535
ax.axis("off")
3636
plt.show()
3737

@@ -40,11 +40,11 @@
4040
And here a second example:
4141
"""
4242

43-
plt.rcParams['font.family'] = 'monospace'
44-
# plt.rcParams['font.monospace'] = ['Computer Modern Typewriter'] # this line gives an error currently, therefore the
45-
# question: How can one access the fonts from https://github.com/matplotlib/matplotlib/blob/main/lib/matplotlib/mpl-data/matplotlibrc#L273
43+
plt.rcParams["font.family"] = "monospace"
44+
# plt.rcParams['font.monospace'] = ['Computer Modern Typewriter'] # this line gives an error currently, therefore the
45+
# question: How can one access the fonts from https://github.com/matplotlib/matplotlib/blob/main/lib/matplotlib/mpl-data/matplotlibrc#L273
4646
# the correct way?
4747
fig, ax = plt.subplots(figsize=(6, 1), facecolor="#eefade")
48-
ax.text(0.01, 0.2, "Hello World! 01", size = 40)
48+
ax.text(0.01, 0.2, "Hello World! 01", size=40)
4949
ax.axis("off")
50-
plt.show()
50+
plt.show()

0 commit comments

Comments
 (0)