den-run-ai / yapgvb

Automatically exported from code.google.com/p/yapgvb
0 stars 0 forks source link

The label attribute on shapes doesn't support html attributes #11

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Set the label on a shape to a html text (should be valid per
http://www.graphviz.org/doc/info/shapes.html#html

What is the expected output? What do you see instead?
Html displayed inside the shape.  Instead, I simply saw the html displayed
as text.

What version of the product are you using? On what operating system?
1.2.3 (latest from SVN on Sept 4, 2009)

Original issue reported on code.google.com by philip.p...@gmail.com on 4 Sep 2009 at 12:12

GoogleCodeExporter commented 9 years ago
In _yapgvb_py.py, I found, it should become something like :

def _write_dot(self, filename):
        f = open(filename,'w')

        def afmt(n,v):
            if v.startswith('<'):
                return "%s=%s" % (n,v)
        return "%s=\"%s\"" % (n,v)

But I don't know how to apply my changes.

Original comment by leplat...@gmail.com on 23 Feb 2010 at 11:18

GoogleCodeExporter commented 9 years ago
I could eventually validate this fix using pure python backend.

Original comment by leplat...@gmail.com on 26 Feb 2010 at 4:49

GoogleCodeExporter commented 9 years ago
when a label starts with < and ends with > graphviz will, try to, render as 
html. its 
very nice because you can use basic html tables!

Original comment by franshaa...@gmail.com on 27 Apr 2010 at 12:12

GoogleCodeExporter commented 9 years ago
It would be great if this would be added to the main release.

Original comment by holke.vi...@gmail.com on 24 Jan 2011 at 9:38

GoogleCodeExporter commented 9 years ago
The workaround works for me.

Original comment by holke.vi...@gmail.com on 24 Jan 2011 at 9:50