Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Closed
Milestone
Description
Bug report
Bug summary
PolyCollection lines aren't affected by changes to the path.sketch rcparam, even though patches
are-the docs say that polycollection defaults to patch RC params
Code for reproduction
importnumpyasnpimportmatplotlib.collectionsasmcollectionsimportmatplotlib.patchesasmpatchesimportmatplotlib.pyplotaspltfrommatplotlibimportrcParamsrcParams['path.sketch']= (.5,25,20)fig, (ax1,ax2)=plt.subplots(ncols=2)f1=mpatches.Rectangle((.25,.25),.5,.5,facecolor='white',edgecolor='C0',linewidth=2)ax1.add_patch(f1)verts=np.array([[[1,-1], [1,1], [2.4,1.5], [2.4,-.5]], [[-.4,1.5],[-.4,-.5],[1,-1],[1,1]], [[-.4,1.5], [1,2],[2.4,1.5], [1,1]]])verts2=verts*.25+ [.3]p=mcollections.PolyCollection(np.vstack([verts,verts2]),facecolor='white',edgecolor='C0',linewidth=2)ax2.add_collection(p)
Matplotlib version
- Matplotlib version (
import matplotlib; print(matplotlib.__version__)
): 3.3.4 - Matplotlib backend (
print(matplotlib.get_backend())
): jupyter inline