PEP8 fixes on offsetbox.py #1400

Merged
merged 1 commit into from Nov 8, 2012

Projects

None yet

3 participants

@NelleV
Contributor
NelleV commented Oct 14, 2012

PEP8 fixes on the module offsetbox

Thanks,
N

@dmcdougall dmcdougall commented on an outdated diff Nov 7, 2012
lib/matplotlib/offsetbox.py
@@ -331,10 +330,10 @@ def get_extent_offsets(self, renderer):
if isinstance(c, PackerBase) and c.mode == "expand":
c.set_width(self.width)
- whd_list = [c.get_extent(renderer) for c in self.get_visible_children()]
+ whd_list = [c.get_extent(renderer) for c
+ in self.get_visible_children()]
@dmcdougall
dmcdougall Nov 7, 2012 Member

Could you put the for c on this line too?

@dmcdougall dmcdougall commented on an outdated diff Nov 7, 2012
lib/matplotlib/offsetbox.py
@@ -389,7 +387,8 @@ def get_extent_offsets(self, renderer):
pad = self.pad * dpicor
sep = self.sep * dpicor
- whd_list = [c.get_extent(renderer) for c in self.get_visible_children()]
+ whd_list = [c.get_extent(renderer) for c
+ in self.get_visible_children()]
@dmcdougall
dmcdougall Nov 7, 2012 Member

Same here.

@dmcdougall dmcdougall commented on an outdated diff Nov 7, 2012
lib/matplotlib/offsetbox.py
@@ -1332,7 +1335,8 @@ def update_positions(self, renderer):
self.arrow_patch.set_mutation_scale(mutation_scale)
def _update_position_xybox(self, renderer, xy_pixel):
- "Update the pixel positions of the annotation text and the arrow patch."
+ """Update the pixel positions of the annotation text and the arrow
+ patch."""
@dmcdougall
dmcdougall Nov 7, 2012 Member

I think this looks better:

"""
Update the pixel positions of the annotation text and the arrow
patch.
"""
@NelleV
Contributor
NelleV commented Nov 8, 2012

I've fixed the 3 issues mentionned above.

Cheers,
N

@pelson pelson merged commit e637e12 into matplotlib:master Nov 8, 2012

1 check passed

default The Travis build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment