@@ -63,42 +63,34 @@ def draw_path_collection(self, gc, master_transform, paths, all_transforms,
63
63
offsets , offsetTrans , facecolors , edgecolors ,
64
64
linewidths , linestyles , antialiaseds , urls ,
65
65
offset_position ):
66
- cliprect = gc .get_clip_rectangle ()
67
- clippath , clippath_transform = gc .get_clip_path ()
68
- if all_transforms :
69
- transforms = [numpy .dot (master_transform , t ) for t in all_transforms ]
66
+ if offset_position == 'data' :
67
+ offset_position = True
70
68
else :
71
- transforms = [master_transform ]
72
- gc .draw_path_collection (cliprect ,
73
- clippath ,
74
- clippath_transform ,
75
- paths ,
76
- transforms ,
77
- offsets ,
78
- offsetTrans ,
79
- facecolors ,
80
- edgecolors ,
81
- linewidths ,
82
- linestyles ,
83
- antialiaseds )
69
+ offset_position = False
70
+ path_ids = []
71
+ for path , transform in self ._iter_collection_raw_paths (
72
+ master_transform , paths , all_transforms ):
73
+ path_ids .append ((path , transform ))
74
+ master_transform = master_transform .get_matrix ()
75
+ all_transforms = [t .get_matrix () for t in all_transforms ]
76
+ offsetTrans = offsetTrans .get_matrix ()
77
+ gc .draw_path_collection (master_transform , path_ids , all_transforms ,
78
+ offsets , offsetTrans , facecolors , edgecolors ,
79
+ linewidths , linestyles , antialiaseds ,
80
+ offset_position )
84
81
85
82
def draw_quad_mesh (self , gc , master_transform , meshWidth , meshHeight ,
86
83
coordinates , offsets , offsetTrans , facecolors ,
87
- antialiased , showedges ):
88
- cliprect = gc .get_clip_rectangle ()
89
- clippath , clippath_transform = gc .get_clip_path ()
90
- gc .draw_quad_mesh (master_transform ,
91
- cliprect ,
92
- clippath ,
93
- clippath_transform ,
84
+ antialiased , edgecolors ):
85
+ gc .draw_quad_mesh (master_transform .get_matrix (),
94
86
meshWidth ,
95
87
meshHeight ,
96
88
coordinates ,
97
89
offsets ,
98
- offsetTrans ,
90
+ offsetTrans . get_matrix () ,
99
91
facecolors ,
100
92
antialiased ,
101
- showedges )
93
+ edgecolors )
102
94
103
95
def new_gc (self ):
104
96
self .gc .save ()
0 commit comments