matplotlib.patches#

Inheritance diagram of matplotlib.patches

补丁是具有填充颜色和边框颜色的 Artist

#

Annulus(xy, r, width[, angle])

一个椭圆环。

Arc(xy, width, height, *[, angle, theta1, ...])

一个椭圆弧,即椭圆的一个片段。

Arrow(x, y, dx, dy, *[, width])

一个箭头补丁。

ArrowStyle(stylename, **kwargs)

ArrowStyle 是一个容器类,它定义了多个箭头样式类,用于沿给定路径创建箭头路径。

BoxStyle(stylename, **kwargs)

BoxStyle 是一个容器类,它定义了多个方框样式类,用于 FancyBboxPatch

Circle(xy[, radius])

一个圆形补丁。

CirclePolygon(xy[, radius, resolution])

一个圆形的近似多边形补丁。

ConnectionPatch(xyA, xyB, coordsA[, ...])

连接两个点(可能在不同 Axes 中)的补丁。

ConnectionStyle(stylename, **kwargs)

ConnectionStyle 是一个容器类,它定义了多个连接样式类,用于创建两点之间的路径。

Ellipse(xy, width, height, *[, angle])

一个无比例椭圆。

FancyArrow(x, y, dx, dy, *[, width, ...])

类似于 Arrow,但允许您独立设置箭头头部宽度和高度。

FancyArrowPatch([posA, posB, path, ...])

一个花式箭头补丁。

FancyBboxPatch(xy, width, height[, ...])

围绕一个矩形的花式方框,其左下角位于 *xy* = (*x*, *y*),具有指定的宽度和高度。

Patch(*[, edgecolor, facecolor, color, ...])

补丁是一个具有填充颜色和边框颜色的 2D artist。

PathPatch(path, **kwargs)

一个通用的多曲线路径补丁。

StepPatch(values, edges, *[, orientation, ...])

描述阶梯常数函数的路径补丁。

Polygon(xy, *[, closed])

一个通用的多边形补丁。

Rectangle(xy, width, height, *[, angle, ...])

通过锚点 *xy* 及其 *width* 和 *height* 定义的矩形。

RegularPolygon(xy, numVertices, *[, radius, ...])

一个正多边形补丁。

Shadow(patch, ox, oy, *[, shade])

创建给定 *补丁* 的阴影。

Wedge(center, r, theta1, theta2, *[, width])

楔形补丁。

函数#

bbox_artist(artist, renderer[, props, fill])

一个调试函数,用于在 artist 的 Artist.get_window_extent 返回的边界框周围绘制一个矩形,以测试 artist 是否返回了正确的边界框。

draw_bbox(bbox, renderer[, color, trans])

一个调试函数,用于在 artist 的 Artist.get_window_extent 返回的边界框周围绘制一个矩形,以测试 artist 是否返回了正确的边界框。