Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PEP8 fixes on text.py #1357

Merged
merged 2 commits into from Nov 19, 2012
Merged

PEP8 fixes on text.py #1357

merged 2 commits into from Nov 19, 2012

Conversation

NelleV
Copy link
Member

@NelleV NelleV commented Oct 10, 2012

PEP8 fixes on the module text

@@ -16,18 +16,15 @@
from matplotlib.patches import bbox_artist, YAArrow, FancyBboxPatch, \
FancyArrowPatch, Rectangle
import matplotlib.transforms as mtransforms
from matplotlib.transforms import Affine2D, Bbox, Transform ,\
BboxBase, BboxTransformTo
from matplotlib.transforms import Affine2D, Bbox, Transform,\
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's a trailing backslash been left in at the end of this line.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's because the import takes two lines.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In another PR (I can't remember which one) you just added an extra from matplotlib.blah import statement at the beginning of the wrapped line. There was also a PR that used ( and ) to encase the imported items so they would wrap well. Either of those approaches trumps this one, I think.

@dmcdougall
Copy link
Member

@NelleV Can you squash down to one commit?

@NelleV
Copy link
Member Author

NelleV commented Oct 13, 2012

@dmcdougall Done !

def _update_position_xytext(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."""
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Multi-line docstrings should have the triple-quotes on their own lines.

@NelleV
Copy link
Member Author

NelleV commented Oct 14, 2012

I get a pyflakes warning on this file:

 text.py|26| W402 'TextPath' imported but unused 

Should I delete it ?

@dmcdougall
Copy link
Member

I get a pyflakes warning on this file:

text.py|26| W402 'TextPath' imported but unused

Should I delete it ?

I'll open a separate issue for that once this is merged.

If nobody has any further objections, I'll merge this tomorrow.

@NelleV
Copy link
Member Author

NelleV commented Nov 19, 2012

I've rebased matplotlib/master on this branch: I think it is ready to be merged.

dmcdougall added a commit that referenced this pull request Nov 19, 2012
@dmcdougall dmcdougall merged commit c1b62af into matplotlib:master Nov 19, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants