Graphviz Issue Tracker
Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0002501graphvizDotpublic2014-11-12 19:422014-11-13 09:45
ReporterRon Savage 
Assigned Tonorth 
PrioritynormalSeveritynormalReproducibilityalways
StatusassignedResolutionnot fixable 
PlatformAMD64OSDebianOS Version7.7
Summary0002501: Using \N in label generates node widths too narrow for the label
DescriptionSee next point
Steps To Reproduce(1)
In the file you ship, directed/psfonttest.gv, change lines 4 and 5 to be:
node [shape=none margin=0 label = <<table border='1'><tr><td>\N</td></tr></table>>]
edge [color=green]
and run dot -Tsvg psfonttest.gv > psfonttest.svg.
These 2 files are attached, or at least the latter is.
(2)
Then, change line 4 to be:
node [shape=none margin=0 label = "\N"]
and you'll see what I assume is a related problem.
Additional InformationI've attached psfonttest.gv and psfonttest.svg, but the display only shows the latter.
TagsNo tags attached.
AUXILLARY-FILES
DATE-FIXED
FIX-COMMENT
FORMER-ID
INPUT-FILE
OUTPUT-FILE
STATUS-COMMENT
VERSIONGraphviz 2.38.0
Attached Files? file icon psfonttest.svg (Attachment missing)

- Relationships

-  Notes
User avatar (0000849)
north (administrator)
2014-11-12 20:02

The output looks mostly OK in Google Chrome (on Mac OSX but that probably doesn't matter). I tried both -Tsvg:core and -Tsvg:cairo svg:core is somewhat underspecified - there's no way for Graphviz to know how the renderer (which may be on a different computer) will interpret the fonts that are specified. I noticed that ZapfDingbats appeared very differently in svg:core and svg:cairo. This is just a problem with SVG in general. As we all probably know by now, svg:cairo avoids this problem by actually embedding the font paths in the generated SVG. This is accurate but not so pleasant for downstream tools.
User avatar (0000850)
Ron Savage (reporter)
2014-11-12 20:17

It looks much better in FF than in Chrome on my machine.

Given the rendering issue you mention, you might as well close this issue.
User avatar (0000851)
erg (administrator)
2014-11-13 09:43

As people have noted, SVG can also be pretty flexible with its color interpretation as well.
User avatar (0000852)
erg (administrator)
2014-11-13 09:45

The reported problem is a limitation with SVG, in that the SVG viewer can use very different fonts from the ones used by Graphviz to compute sizes. To avoid the problem, use -Tsvg:cairo so that the font info is embedded in the svg output.

- Issue History
Date Modified Username Field Change
2014-11-12 19:42 Ron Savage New Issue
2014-11-12 19:42 Ron Savage File Added: psfonttest.svg
2014-11-12 20:02 north Note Added: 0000849
2014-11-12 20:17 Ron Savage Note Added: 0000850
2014-11-13 09:43 erg Note Added: 0000851
2014-11-13 09:45 erg Note Added: 0000852
2014-11-13 09:45 erg Assigned To => north
2014-11-13 09:45 erg Status new => assigned
2014-11-13 09:45 erg Resolution open => not fixable


MantisBT 1.2.5[^]
Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker