Skip to content

Cleanup: remove unused variable/assignment/expression and debug comments #7941

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

Merged
merged 1 commit into from
Jan 25, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 1 addition & 17 deletions lib/matplotlib/patches.py
Original file line number Diff line number Diff line change
Expand Up @@ -1803,8 +1803,6 @@ def _pprint_styles(_styles):
(stylename : styleclass), return a formatted string listing all the
styles. Used to update the documentation.
"""
names, attrss, clss = [], [], []

import inspect

_table = [["Class", "Name", "Attrs"]]
Expand Down Expand Up @@ -3057,8 +3055,6 @@ def connect(self, posA, posB):
x1, y1 = posA
x20, y20 = x2, y2 = posB

x12, y12 = (x1 + x2) / 2., (y1 + y2) / 2.

theta1 = math.atan2(y2 - y1, x2 - x1)
dx, dy = x2 - x1, y2 - y1
dd = (dx * dx + dy * dy) ** .5
Expand All @@ -3067,18 +3063,12 @@ def connect(self, posA, posB):
armA, armB = self.armA, self.armB

if self.angle is not None:
#angle = self.angle % 180.
#if angle < 0. or angle > 180.:
# angle
#theta0 = (self.angle%180.)/180.*math.pi
theta0 = self.angle / 180. * math.pi
#theta0 = (((self.angle+90)%180.) - 90.)/180.*math.pi
dtheta = theta1 - theta0
dl = dd * math.sin(dtheta)

dl = dd * math.sin(dtheta)
dL = dd * math.cos(dtheta)

#x2, y2 = x2 + dl*ddy, y2 - dl*ddx
x2, y2 = x1 + dL * math.cos(theta0), y1 + dL * math.sin(theta0)

armB = armB - dl
Expand All @@ -3091,14 +3081,8 @@ def connect(self, posA, posB):
else:
dl = 0.

#if armA > armB:
# armB = armA + dl
#else:
# armA = armB - dl

arm = max(armA, armB)
f = self.fraction * dd + arm
#fB = self.fraction*dd + armB

cx1, cy1 = x1 + f * ddy, y1 - f * ddx
cx2, cy2 = x2 + f * ddy, y2 - f * ddx
Expand Down
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy