From 93c2093ef3be8167eb3dfaf48156fa70b1077f72 Mon Sep 17 00:00:00 2001 From: Florian Festi Date: Tue, 9 Apr 2019 21:51:21 +0200 Subject: [PATCH] AllEdges: Fix spacing and add edegs around the corner to make it more clear which direction the edges are pointing. Related #132 --- boxes/generators/alledges.py | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/boxes/generators/alledges.py b/boxes/generators/alledges.py index 8942fd0..4df25fd 100644 --- a/boxes/generators/alledges.py +++ b/boxes/generators/alledges.py @@ -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)