mirror of
https://github.com/phooky/Apple-410.git
synced 2024-06-12 14:29:28 +00:00
correct centering
This commit is contained in:
parent
398389f315
commit
fc8e013999
|
@ -65,8 +65,10 @@ def plot_svg(f, center=False):
|
|||
s = max(s1,s2)
|
||||
if center:
|
||||
xoff = w/2 - (minx + spanx/2)/s
|
||||
yoff = w/2 - (miny + spany/2)/s
|
||||
yoff = h/2 - (miny + spany/2)/s
|
||||
sys.stderr.write("Centered\n")
|
||||
else:
|
||||
sys.stderr.write("Not centered\n")
|
||||
xoff = -minx/s
|
||||
yoff = -miny/s
|
||||
segs = map(lambda x: ((x[0][0]/s + xoff,x[0][1]/s + yoff),
|
||||
|
|
Loading…
Reference in New Issue
Block a user