AllEdges: Fix spacing and add edegs around the corner

to make it more clear which direction the edges are pointing.

Related #132
This commit is contained in:
Florian Festi 2019-04-09 21:51:21 +02:00
parent f22be6f6d5
commit 93c2093ef3
1 changed files with 11 additions and 3 deletions

View File

@ -40,11 +40,19 @@ class AllEdges(Boxes):
chars = list(self.edges.keys())
chars.sort(key=lambda c: c.lower() + (c if c.isupper() else ''))
chars.reverse()
self.moveTo(0, 10*t)
for c in chars:
self.moveTo(0, 15*t)
with self.saved_context():
self.moveTo(x, 0, 180)
self.moveTo(x, 0, 90)
self.edge(t+self.edges[c].startwidth())
self.corner(90)
self.edges[c](x, h=4*t)
self.text("%s - %s" % (c, self.edges[c].description), y=5*t)
self.corner(90)
self.edge(t+self.edges[c].endwidth())
self.moveTo(0, 3*t + self.edges[c].spacing())
self.text("%s - %s" % (c, self.edges[c].description))
self.moveTo(0, 12*t)