Movatterモバイル変換


[0]ホーム

URL:


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

Sign up
Appearance settings

Fix figure legend when drawing stackplots#30186

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
timhoffm merged 2 commits intomatplotlib:mainfromdstansby:fig-legend-error
Jul 7, 2025
Merged
Changes from1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
Add smoke test
  • Loading branch information
@dstansby
dstansby committedJul 6, 2025
commitb370e30c4cc5412ded32796ea56a4a1926e39b02
14 changes: 14 additions & 0 deletionslib/matplotlib/tests/test_axes.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -3420,6 +3420,20 @@ def test_stackplot_hatching(fig_ref, fig_test):
ax_ref.set_ylim(0, 70)


def test_stackplot_subfig_legend():
# Smoke test for https://github.com/matplotlib/matplotlib/issues/30158

fig = plt.figure()
subfigs = fig.subfigures(nrows=1, ncols=2)

for _fig in subfigs:
ax = _fig.subplots(nrows=1, ncols=1)
ax.stackplot([3, 4], [[1, 2]], labels=['a'])

fig.legend()
fig.draw_without_rendering()


def _bxp_test_helper(
stats_kwargs={}, transform_stats=lambda s: s, bxp_kwargs={}):
np.random.seed(937)
Expand Down
Loading

[8]ページ先頭

©2009-2025 Movatter.jp