Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/torch/argcheck.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRonan Collobert <ronan@collobert.com>2014-11-08 04:56:13 +0300
committerRonan Collobert <ronan@collobert.com>2014-11-08 04:56:13 +0300
commitf0686dc07fb701b5ce31615403f54e81a126c188 (patch)
tree0fcf0de3444ce70c0b7fc243f1adce9ee7507109
parent73ee6aa5112e8c73c6d8e2e517589d660e839728 (diff)
cosmetic changes to generated dot graph
-rw-r--r--graph.lua9
1 files changed, 5 insertions, 4 deletions
diff --git a/graph.lua b/graph.lua
index 81fa844..3690c59 100644
--- a/graph.lua
+++ b/graph.lua
@@ -113,12 +113,13 @@ end
function ACN:print(txt)
local isroot = not txt
txt = txt or {'digraph ACN {'}
- table.insert(txt, string.format('id%s [label="%s%s (%s)" style=filled fillcolor=%s];',
+ table.insert(txt, 'edge [penwidth=.3 arrowsize=0.8];')
+ table.insert(txt, string.format('id%s [label="%s%s%s" penwidth=.1 fontsize=10 style=filled fillcolor="%s"];',
self:id(),
self.type,
- self.check and '<check>' or '',
- self.name,
- self.rules and 'red' or 'blue'))
+ self.check and ' <check>' or '',
+ self.name and string.format(' (%s)', self.name) or '',
+ self.rules and '#aaaaaa' or '#eeeeee'))
for n=1,self.n do
local next = self.next[n]