Commit e45e591b authored by Alexandre Delanoë's avatar Alexandre Delanoë

[FIX][EXPORT][GEXF] size of nodes were lacking

parent 3fac5d9a
......@@ -52,11 +52,12 @@ instance Xmlbf.ToXml Graph where
nodes gn = Xmlbf.element "nodes" HashMap.empty $ P.concatMap node' gn
node' :: G.Node -> [Xmlbf.Node]
node' (G.Node { node_id = nId, node_label = l }) =
node' (G.Node { node_id = nId, node_label = l, node_size = w}) =
Xmlbf.element "node" params []
where
params = HashMap.fromList [ ("id", nId)
, ("label", l) ]
, ("label", l)
, ("size", (cs . show) w)]
edges :: [G.Edge] -> [Xmlbf.Node]
edges gn = Xmlbf.element "edges" HashMap.empty $ P.concatMap edge gn
edge :: G.Edge -> [Xmlbf.Node]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment