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 e1bdb3b

Browse filesBrowse files
authored
Merge pull request #23063 from megies/doc_mathtext_example_axhspan
doc: mathtext example: use axhspan() instead of fill_between() for backdrop rectangle shading
2 parents fa24348 + 213d37f commit e1bdb3b
Copy full SHA for e1bdb3b

File tree

Expand file treeCollapse file tree

1 file changed

+1
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-3
lines changed

‎examples/text_labels_and_annotations/mathtext_examples.py

Copy file name to clipboardExpand all lines: examples/text_labels_and_annotations/mathtext_examples.py
+1-3Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,9 +89,7 @@ def doall():
8989
baseline = 1 - i_line * line_axesfrac
9090
baseline_next = baseline - line_axesfrac
9191
fill_color = ['white', 'tab:blue'][i_line % 2]
92-
ax.fill_between([0, 1], [baseline, baseline],
93-
[baseline_next, baseline_next],
94-
color=fill_color, alpha=0.2)
92+
ax.axhspan(baseline, baseline_next, color=fill_color, alpha=0.2)
9593
ax.annotate(f'{title}:',
9694
xy=(0.06, baseline - 0.3 * line_axesfrac),
9795
color=mpl_grey_rgb, weight='bold')

0 commit comments

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