Draw a marker at each of *path*'s vertices (excluding control points). The base (fallback) implementation makes multiple calls to `draw_path`. Backends may want to override this method in order to draw the marker only once and reuse it multiple times. Param
(self, gc, marker_path, marker_trans, path,
trans, rgbFace=None)
| 177 | raise NotImplementedError |
| 178 | |
| 179 | def draw_markers(self, gc, marker_path, marker_trans, path, |
| 180 | trans, rgbFace=None): |
| 181 | """ |
| 182 | Draw a marker at each of *path*'s vertices (excluding control points). |
| 183 | |
| 184 | The base (fallback) implementation makes multiple calls to `draw_path`. |
| 185 | Backends may want to override this method in order to draw the marker |
| 186 | only once and reuse it multiple times. |
| 187 | |
| 188 | Parameters |
| 189 | ---------- |
| 190 | gc : `.GraphicsContextBase` |
| 191 | The graphics context. |
| 192 | marker_path : `~matplotlib.path.Path` |
| 193 | The path for the marker. |
| 194 | marker_trans : `~matplotlib.transforms.Transform` |
| 195 | An affine transform applied to the marker. |
| 196 | path : `~matplotlib.path.Path` |
| 197 | The locations to draw the markers. |
| 198 | trans : `~matplotlib.transforms.Transform` |
| 199 | An affine transform applied to the path. |
| 200 | rgbFace : :mpltype:`color`, optional |
| 201 | """ |
| 202 | for vertices, codes in path.iter_segments(trans, simplify=False): |
| 203 | if len(vertices): |
| 204 | x, y = vertices[-2:] |
| 205 | self.draw_path(gc, marker_path, |
| 206 | marker_trans + |
| 207 | transforms.Affine2D().translate(x, y), |
| 208 | rgbFace) |
| 209 | |
| 210 | def draw_path_collection(self, gc, master_transform, paths, all_transforms, |
| 211 | offsets, offset_trans, facecolors, edgecolors, |
no test coverage detected