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 c31fc6f

Browse filesBrowse files
committed
Forwarded select Rectangle kwargs to the Conneciton patch
1 parent e98d8d0 commit c31fc6f
Copy full SHA for c31fc6f

File tree

1 file changed

+12
-3
lines changed
Filter options

1 file changed

+12
-3
lines changed

‎lib/matplotlib/axes/_axes.py

Copy file name to clipboardExpand all lines: lib/matplotlib/axes/_axes.py
+12-3Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -474,11 +474,20 @@ def indicate_inset(self, bounds, inset_ax=None, *, transform=None,
474474
if self.yaxis.get_inverted():
475475
ey = 1 - ey
476476
xy_data = x + ex * width, y + ey * height
477+
478+
blacklist={
479+
'alpha', 'rasterized', 'transform',
480+
'color', 'facecolor', 'url',
481+
'hatch', 'in_layout', 'path_effects'}
482+
483+
patch_kwargs = {key: val for key, val in kwargs.items() if key not in blacklist}
484+
477485
p = mpatches.ConnectionPatch(
478-
xyA=xy_inset_ax, coordsA=inset_ax.transAxes,
479-
xyB=xy_data, coordsB=self.transData,
486+
xyA=xy_inset_ax, coordsA=inset_ax.transAxes,
487+
xyB=xy_data, coordsB=self.transData,
480488
arrowstyle="-", zorder=zorder,
481-
edgecolor=edgecolor, alpha=alpha)
489+
edgecolor=edgecolor, alpha=alpha,
490+
**patch_kwargs)
482491
connects.append(p)
483492
self.add_patch(p)
484493

0 commit comments

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