File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -460,14 +460,14 @@ def draw(self, renderer):
460460 pad = 2 * (self .borderaxespad + self .borderpad ) * fontsize
461461 self ._legend_box .set_width (self .get_bbox_to_anchor ().width - pad )
462462
463- if self ._drawFrame :
464- # update the location and size of the legend
465- bbox = self ._legend_box .get_window_extent (renderer )
466- self .legendPatch .set_bounds (bbox .x0 , bbox .y0 ,
467- bbox .width , bbox .height )
468-
469- self .legendPatch .set_mutation_scale (fontsize )
463+ # update the location and size of the legend. This needs to
464+ # be done in any case to clip the figure right.
465+ bbox = self ._legend_box .get_window_extent (renderer )
466+ self .legendPatch .set_bounds (bbox .x0 , bbox .y0 ,
467+ bbox .width , bbox .height )
468+ self .legendPatch .set_mutation_scale (fontsize )
470469
470+ if self ._drawFrame :
471471 if self .shadow :
472472 shadow = Shadow (self .legendPatch , 2 , - 2 )
473473 shadow .draw (renderer )
You can’t perform that action at this time.
0 commit comments