dot_writer.py (9853:20c07aa9322c) | dot_writer.py (9854:e4a4cdfb1b81) |
---|---|
1# Copyright (c) 2012-2013 ARM Limited 2# All rights reserved. 3# 4# The license below extends only to copyright in the software and shall 5# not be construed as granting a license to any other intellectual 6# property including but not limited to intellectual property relating 7# to a hardware implementation of the functionality of the software 8# licensed hereunder. You may use the software subject to the license --- 115 unchanged lines hidden (view full) --- 124 125def dot_add_edge(simNode, callgraph, full_port_name, peerPort): 126 if peerPort.role == "MASTER": 127 peer_port_name = re.sub('\.', '_', peerPort.peer.simobj.path() \ 128 + "." + peerPort.peer.name) 129 callgraph.add_edge(pydot.Edge(full_port_name, peer_port_name)) 130 131def dot_create_cluster(simNode, full_path, label): | 1# Copyright (c) 2012-2013 ARM Limited 2# All rights reserved. 3# 4# The license below extends only to copyright in the software and shall 5# not be construed as granting a license to any other intellectual 6# property including but not limited to intellectual property relating 7# to a hardware implementation of the functionality of the software 8# licensed hereunder. You may use the software subject to the license --- 115 unchanged lines hidden (view full) --- 124 125def dot_add_edge(simNode, callgraph, full_port_name, peerPort): 126 if peerPort.role == "MASTER": 127 peer_port_name = re.sub('\.', '_', peerPort.peer.simobj.path() \ 128 + "." + peerPort.peer.name) 129 callgraph.add_edge(pydot.Edge(full_port_name, peer_port_name)) 130 131def dot_create_cluster(simNode, full_path, label): |
132 # get the parameter values of the node and use them as a tooltip 133 ini_strings = [] 134 for param in sorted(simNode._params.keys()): 135 value = simNode._values.get(param) 136 if value != None: 137 # parameter name = value in HTML friendly format 138 ini_strings.append(str(param) + "=" + 139 simNode._values[param].ini_str()) 140 # join all the parameters with an HTML newline 141 tooltip = " ".join(ini_strings) 142 |
|
132 return pydot.Cluster( \ 133 full_path, \ 134 shape = "Mrecord", \ 135 label = label, \ | 143 return pydot.Cluster( \ 144 full_path, \ 145 shape = "Mrecord", \ 146 label = label, \ |
147 tooltip = "\"" + tooltip + "\"", \ |
|
136 style = "\"rounded, filled\"", \ 137 color = "#000000", \ 138 fillcolor = dot_gen_colour(simNode), \ 139 fontname = "Arial", \ 140 fontsize = "14", \ 141 fontcolor = "#000000" \ 142 ) 143 --- 121 unchanged lines hidden --- | 148 style = "\"rounded, filled\"", \ 149 color = "#000000", \ 150 fillcolor = dot_gen_colour(simNode), \ 151 fontname = "Arial", \ 152 fontsize = "14", \ 153 fontcolor = "#000000" \ 154 ) 155 --- 121 unchanged lines hidden --- |