Hi Kent
On 01/12/13 13:46, Kent Fredric via RT wrote:
Show quoted text> Queue: GraphViz2
> Ticket <URL:
https://rt.cpan.org/Ticket/Display.html?id=91073 >
>
>>
>> I'll ask them about getting a more definitive list of attributes.
>
>
> You may want to even consider getting some properties by executing dot
> directly, as that will be self-maintaining , and be impervious to problems
> like, for instance, the possibility a user has compiled a modern version of
> graphviz which your data says supports a parameter, but they've compiled it
> without that parameter supported.
Exactly. Here are the responses to my post on the Graphviz list:
(1)
On 11/30/13 7:25 PM, Ron Savage wrote:
Show quoted text > Hi
>
> If I run:
>
> ron@zigzag:~/perl.modules/GraphViz2$ dot -T?
>
> I get:
>
> Format: "?" not recognized. Use one of: bmp canon cmap cmapx cmapx_np
dot eps fig gd gd2 gif gtk gv ico imap imap_np ismap jpe jpeg jpg pdf
pic plain plain-ext png pov ps ps2 svg svgz tif tiff tk vml vmlz vrml
wbmp x11 xdot xdot1.2 xdot1.4 xlib
Show quoted text >
> Should this list match the list of output formats on this page:
>
>
http://graphviz.org/content/output-formats
>
> For example, gv is in the first list but not the second.
>
> The context is a Perl module, GraphViz2
(
https://metacpan.org/release/GraphViz2), which is a wrapper around
Graphviz, in which I validate parameters before calling any executables
in Graphviz.
Show quoted text >
> I'm not sure which list I should use to check user parameters.
>
In terms of what is actually available in a given environment, the
output of dot -T? is the best one to use. All formats listed
on the web site may not be available depending on which plugins are
built and installed. By the way, if you are using the library
interface, you can access the plugin information using the gvPluginList
function.
In theory, the web site list should be a superset of what is actually on
a given installation, but I see that I neglected to add the
gv synonym for dot, and that various formats slipped in via the quartz
renderer. The web page has been updated. Thanks.
Emden
(2)
Ron,
The output from "dot -T" corresponds to the formats supported by the
locally available plugins. It can be a subset of the formats from all
possible plugins if some are not installed locally (or fail to
dynamically load.)
-Tgv is an alias for -Tdot, added fairly recently when we registered
.gv as a filename extension for files in the DOT language. (In an
attempt to avoid collisions with MS Word's .dot files).
Its possible that
http://graphviz.org/content/output-formats is out of
date, but the set returned by "dot -T" will always be valid for the
local installation.
Note that there can be multiple implementations of renderers, so, for
example, "dot -Tpng:?" will list all PNG renderers available locally.
The first listed is the one chosen by default.
John
So, the solution is indeed to run dot and configure GraphViz2 on-the-fly.
I'll also have to develop an FAQ item on this for the docs.
--
Ron Savage
http://savage.net.au/