def to_dot_html(self, ctxt): from gccutils.dot import Table, Tr, Td, Text funtype = self.fun.decl.type args = ",".join(["%s %s" % (arg.type, arg.name) for arg in self.fun.decl.arguments]) signature = "%s %s(%s)" % (funtype.type, self.fun.decl.name, args) table = Table([Tr([Td([Text("ENTRY %s" % signature)])])]) for var in self.fun.local_decls: table.add_child(Tr([Td([Text("%s %s;" % (var.type, var))])])) return table
def to_dot_html(self, ctxt): from gccutils.dot import Table, Tr, Td, Text, Br, Font table = Table() tr = table.add_child(Tr()) td = tr.add_child(Td(align='left')) td.add_child(Text('%s' % (self.callstring))) #.to_dot_id()))) tr = table.add_child(Tr()) td = tr.add_child(Td(align='left')) td.add_child(self.innernode.to_dot_html(ctxt)) return table
def to_dot_html(self, ctxt): from gccutils.dot import Table, Tr, Td, Text funtype = self.fun.decl.type args = ','.join([ '%s %s' % (arg.type, arg.name) for arg in self.fun.decl.arguments ]) signature = '%s %s(%s)' % (funtype.type, self.fun.decl.name, args) table = Table([Tr([Td([Text('ENTRY %s' % signature)])])]) for var in self.fun.local_decls: table.add_child(Tr([Td([Text('%s %s;' % (var.type, var))])])) return table
def to_dot_html(self, ctxt): from gccutils.dot import Table, Tr, Td, Text, Br, Font from gccutils import get_src_for_loc loc = self.get_gcc_loc() if loc: table = Table() code = get_src_for_loc(loc).rstrip() tr = table.add_child(Tr()) td = tr.add_child(Td(align='left')) td.add_child(Text('%4i %s' % (self.stmt.loc.line, code))) td.add_child(Br()) td.add_child(Text(' ' * (5 + self.stmt.loc.column-1) + '^')) td.add_child(Br()) td.add_child(Text(str(self))) return table # return Font([table], face="monospace") else: return Text(str(self))
def to_dot_html(self, ctxt): from gccutils.dot import Table, Tr, Td, Text, Br, Font from gccutils import get_src_for_loc loc = self.get_gcc_loc() if loc: table = Table() code = get_src_for_loc(loc).rstrip() tr = table.add_child(Tr()) td = tr.add_child(Td(align='left')) td.add_child(Text('%4i %s' % (self.stmt.loc.line, code))) td.add_child(Br()) td.add_child(Text(' ' * (5 + self.stmt.loc.column - 1) + '^')) td.add_child(Br()) td.add_child(Text(str(self))) return table # return Font([table], face="monospace") else: return Text(str(self))