Skip to content

Commit

Permalink
Issue #10
Browse files Browse the repository at this point in the history
  • Loading branch information
glejeune committed Aug 4, 2012
1 parent bbde971 commit 8db289b
Show file tree
Hide file tree
Showing 3 changed files with 163 additions and 156 deletions.
6 changes: 3 additions & 3 deletions Jakefile.js
Expand Up @@ -6,13 +6,13 @@ var util = require('util'),


var docTitle = 'node-graphviz' var docTitle = 'node-graphviz'
var docFiles = 'lib/graphviz.js lib/deps/graph.js lib/deps/node.js lib/deps/edge.js' var docFiles = 'lib/graphviz.js lib/deps/graph.js lib/deps/node.js lib/deps/edge.js'
var outputDocFile = 'documentation.html' var outputDocFile = 'documentation.json'
var docRibbon = 'http://github.com/glejeune/node-graphviz' var docRibbon = 'http://github.com/glejeune/node-graphviz'
var docDesc = '[Node.js](http://nodejs.org) interface to the [GraphViz](http://graphviz.org) graphing tool' var docDesc = '[Node.js](http://nodejs.org) interface to the [GraphViz](http://graphviz.org) graphing tool'


desc('Generate node-graphviz documentation.'); desc('Generate node-graphviz documentation.');
task('doc', [], function () { task('doc', [], function () {
child = exec('dox -r ' + docRibbon + ' -d "' + docDesc + '" -t "' + docTitle + '" -J ' + docFiles + ' > ' + outputDocFile, child = exec('dox -r ' + docRibbon + ' -d "' + docDesc + '" -t "' + docTitle + '" < ' + docFiles + ' > ' + outputDocFile,
function (error, stdout, stderr) { function (error, stdout, stderr) {
if (error !== null) { if (error !== null) {
console.log('exec error: ' + error); console.log('exec error: ' + error);
Expand Down Expand Up @@ -40,4 +40,4 @@ task('publish', [], function() {
} }
} }
); );
}); });
311 changes: 159 additions & 152 deletions lib/deps/attributs.js
Expand Up @@ -2,158 +2,165 @@ var Hash = require('./core_ext/hash').Hash,
util = require('util'); util = require('util');


var attrs = { var attrs = {
"Damping" : { "usage" : "G", "type" : "double" }, "Damping" : { "usage" : "G", "type" : "double" },
"K" : { "usage" : "GC", "type" : "double" }, "K" : { "usage" : "GC", "type" : "double" },
"URL" : { "usage" : "ENGC", "type" : "escString" }, "URL" : { "usage" : "ENGC", "type" : "escString" },
"arrowhead" : { "usage" : "E", "type" : "arrowType" }, "area" : { "usage" : "NC", "type" : "double" },
"arrowsize" : { "usage" : "E", "type" : "double" }, "arrowhead" : { "usage" : "E", "type" : "arrowType" },
"arrowtail" : { "usage" : "E", "type" : "arrowType" }, "arrowsize" : { "usage" : "E", "type" : "double" },
"aspect" : { "usage" : "G", "type" : "aspectType" }, "arrowtail" : { "usage" : "E", "type" : "arrowType" },
"bb" : { "usage" : "G", "type" : "rect" }, "aspect" : { "usage" : "G", "type" : "aspectType" },
"bgcolor" : { "usage" : "GC", "type" : "color" }, "bb" : { "usage" : "G", "type" : "rect" },
"center" : { "usage" : "G", "type" : "bool" }, "bgcolor" : { "usage" : "GC", "type" : "color" },
"charset" : { "usage" : "G", "type" : "string" }, "center" : { "usage" : "G", "type" : "bool" },
"clusterrank" : { "usage" : "G", "type" : "clusterMode" }, "charset" : { "usage" : "G", "type" : "string" },
"color" : { "usage" : "ENC", "type" : "color" }, "clusterrank" : { "usage" : "G", "type" : "clusterMode" },
"colorscheme" : { "usage" : "ENCG", "type" : "string" }, "color" : { "usage" : "ENC", "type" : "color" },
"comment" : { "usage" : "ENG", "type" : "string" }, "colorscheme" : { "usage" : "ENCG", "type" : "string" },
"compound" : { "usage" : "G", "type" : "bool" }, "comment" : { "usage" : "ENG", "type" : "string" },
"concentrate" : { "usage" : "G", "type" : "bool" }, "compound" : { "usage" : "G", "type" : "bool" },
"constraint" : { "usage" : "E", "type" : "bool" }, "concentrate" : { "usage" : "G", "type" : "bool" },
"decorate" : { "usage" : "E", "type" : "bool" }, "constraint" : { "usage" : "E", "type" : "bool" },
"defaultdist" : { "usage" : "G", "type" : "double" }, "decorate" : { "usage" : "E", "type" : "bool" },
"dim" : { "usage" : "G", "type" : "int" }, "defaultdist" : { "usage" : "G", "type" : "double" },
"dimen" : { "usage" : "G", "type" : "int" }, "dim" : { "usage" : "G", "type" : "int" },
"dir" : { "usage" : "E", "type" : "dirType" }, "dimen" : { "usage" : "G", "type" : "int" },
"diredgeconstraints" : { "usage" : "G", "type" : "string" }, "dir" : { "usage" : "E", "type" : "dirType" },
"distortion" : { "usage" : "N", "type" : "double" }, "diredgeconstraints" : { "usage" : "G", "type" : "string" },
"dpi" : { "usage" : "G", "type" : "double" }, "distortion" : { "usage" : "N", "type" : "double" },
"edgeURL" : { "usage" : "E", "type" : "escString" }, "dpi" : { "usage" : "G", "type" : "double" },
"edgehref" : { "usage" : "E", "type" : "escString" }, "edgeURL" : { "usage" : "E", "type" : "escString" },
"edgetarget" : { "usage" : "E", "type" : "escString" }, "edgehref" : { "usage" : "E", "type" : "escString" },
"edgetooltip" : { "usage" : "E", "type" : "escString" }, "edgetarget" : { "usage" : "E", "type" : "escString" },
"epsilon" : { "usage" : "G", "type" : "double" }, "edgetooltip" : { "usage" : "E", "type" : "escString" },
"esep" : { "usage" : "G", "type" : "double" }, "epsilon" : { "usage" : "G", "type" : "double" },
"fillcolor" : { "usage" : "NC", "type" : "color" }, "esep" : { "usage" : "G", "type" : "double" },
"fixedsize" : { "usage" : "N", "type" : "bool" }, "fillcolor" : { "usage" : "NEC", "type" : "color" },
"fontcolor" : { "usage" : "ENGC", "type" : "color" }, "fixedsize" : { "usage" : "N", "type" : "bool" },
"fontname" : { "usage" : "ENGC", "type" : "string" }, "fontcolor" : { "usage" : "ENGC", "type" : "color" },
"fontnames" : { "usage" : "G", "type" : "string" }, "fontname" : { "usage" : "ENGC", "type" : "string" },
"fontpath" : { "usage" : "G", "type" : "string" }, "fontnames" : { "usage" : "G", "type" : "string" },
"fontsize" : { "usage" : "ENGC", "type" : "double" }, "fontpath" : { "usage" : "G", "type" : "string" },
"group" : { "usage" : "N", "type" : "string" }, "fontsize" : { "usage" : "ENGC", "type" : "double" },
"headURL" : { "usage" : "E", "type" : "escString" }, "group" : { "usage" : "N", "type" : "string" },
"headclip" : { "usage" : "E", "type" : "bool" }, "headURL" : { "usage" : "E", "type" : "escString" },
"headhref" : { "usage" : "E", "type" : "escString" }, "headclip" : { "usage" : "E", "type" : "bool" },
"headlabel" : { "usage" : "E", "type" : "lblString" }, "headhref" : { "usage" : "E", "type" : "escString" },
"headport" : { "usage" : "E", "type" : "portPos" }, "headlabel" : { "usage" : "E", "type" : "lblString" },
"headtarget" : { "usage" : "E", "type" : "escString" }, "headport" : { "usage" : "E", "type" : "portPos" },
"headtooltip" : { "usage" : "E", "type" : "escString" }, "headtarget" : { "usage" : "E", "type" : "escString" },
"height" : { "usage" : "N", "type" : "double" }, "headtooltip" : { "usage" : "E", "type" : "escString" },
"href" : { "usage" : "E", "type" : "escString" }, "height" : { "usage" : "N", "type" : "double" },
"id" : { "usage" : "GNE", "type" : "lblString" }, "href" : { "usage" : "ENGC", "type" : "escString" },
"image" : { "usage" : "N", "type" : "string" }, "id" : { "usage" : "GNE", "type" : "lblString" },
"imagescale" : { "usage" : "N", "type" : "string" }, "image" : { "usage" : "N", "type" : "string" },
"label" : { "usage" : "ENGC", "type" : "lblString" }, "imagepath" : { "usage" : "G", "type" : "string" },
"labelURL" : { "usage" : "E", "type" : "escString" }, "imagescale" : { "usage" : "N", "type" : "string" },
"labelangle" : { "usage" : "E", "type" : "double" }, "label" : { "usage" : "ENGC", "type" : "lblString" },
"labeldistance" : { "usage" : "E", "type" : "double" }, "labelURL" : { "usage" : "E", "type" : "escString" },
"labelfloat" : { "usage" : "E", "type" : "bool" }, "labelangle" : { "usage" : "E", "type" : "double" },
"labelfontcolor" : { "usage" : "E", "type" : "color" }, "labeldistance" : { "usage" : "E", "type" : "double" },
"labelfontname" : { "usage" : "E", "type" : "string" }, "labelfloat" : { "usage" : "E", "type" : "bool" },
"labelfontsize" : { "usage" : "E", "type" : "double" }, "labelfontcolor" : { "usage" : "E", "type" : "color" },
"labelhref" : { "usage" : "E", "type" : "escString" }, "labelfontname" : { "usage" : "E", "type" : "string" },
"labeljust" : { "usage" : "GC", "type" : "string" }, "labelfontsize" : { "usage" : "E", "type" : "double" },
"labelloc" : { "usage" : "NGC", "type" : "string" }, "labelhref" : { "usage" : "E", "type" : "escString" },
"labeltarget" : { "usage" : "E", "type" : "escString" }, "labeljust" : { "usage" : "GC", "type" : "string" },
"labeltooltip" : { "usage" : "E", "type" : "escString" }, "labelloc" : { "usage" : "NGC", "type" : "string" },
"landscape" : { "usage" : "G", "type" : "bool" }, "labeltarget" : { "usage" : "E", "type" : "escString" },
"layer" : { "usage" : "EN", "type" : "layerRange" }, "labeltooltip" : { "usage" : "E", "type" : "escString" },
"layers" : { "usage" : "G", "type" : "layerList" }, "landscape" : { "usage" : "G", "type" : "bool" },
"layersep" : { "usage" : "G", "type" : "string" }, "layer" : { "usage" : "ENC", "type" : "layerRange" },
"layout" : { "usage" : "G", "type" : "string" }, "layerlistsep" : { "usage" : "G", "type" : "string" },
"len" : { "usage" : "E", "type" : "double" }, "layers" : { "usage" : "G", "type" : "layerList" },
"levels" : { "usage" : "G", "type" : "int" }, "layerselect" : { "usage" : "G", "type" : "layerRange" },
"levelsgap" : { "usage" : "G", "type" : "double" }, "layersep" : { "usage" : "G", "type" : "string" },
"lhead" : { "usage" : "E", "type" : "string" }, "layout" : { "usage" : "G", "type" : "string" },
"lheight" : { "usage" : "GC", "type" : "double" }, "len" : { "usage" : "E", "type" : "double" },
"lp" : { "usage" : "EGC", "type" : "point" }, "levels" : { "usage" : "G", "type" : "int" },
"ltail" : { "usage" : "E", "type" : "string" }, "levelsgap" : { "usage" : "G", "type" : "double" },
"lwidth" : { "usage" : "GC", "type" : "double" }, "lhead" : { "usage" : "E", "type" : "string" },
"margin" : { "usage" : "NG", "type" : "pointf" }, "lheight" : { "usage" : "GC", "type" : "double" },
"maxiter" : { "usage" : "G", "type" : "int" }, "lp" : { "usage" : "EGC", "type" : "point" },
"mclimit" : { "usage" : "G", "type" : "double" }, "ltail" : { "usage" : "E", "type" : "string" },
"mindist" : { "usage" : "G", "type" : "double" }, "lwidth" : { "usage" : "GC", "type" : "double" },
"minlen" : { "usage" : "E", "type" : "int" }, "margin" : { "usage" : "NGC", "type" : "pointf" },
"mode" : { "usage" : "G", "type" : "string" }, "maxiter" : { "usage" : "G", "type" : "int" },
"model" : { "usage" : "G", "type" : "string" }, "mclimit" : { "usage" : "G", "type" : "double" },
"mosek" : { "usage" : "G", "type" : "bool" }, "mindist" : { "usage" : "G", "type" : "double" },
"nodesep" : { "usage" : "G", "type" : "double" }, "minlen" : { "usage" : "E", "type" : "int" },
"nojustify" : { "usage" : "GCNE", "type" : "bool" }, "mode" : { "usage" : "G", "type" : "string" },
"normalize" : { "usage" : "G", "type" : "bool" }, "model" : { "usage" : "G", "type" : "string" },
"nslimit" : { "usage" : "G", "type" : "double" }, "mosek" : { "usage" : "G", "type" : "bool" },
"nslimit1" : { "usage" : "G", "type" : "double" }, "nodesep" : { "usage" : "G", "type" : "double" },
"ordering" : { "usage" : "G", "type" : "string" }, "nojustify" : { "usage" : "GCNE", "type" : "bool" },
"orientation" : { "usage" : "GN", "type" : "string" }, "normalize" : { "usage" : "G", "type" : "bool" },
"outputorder" : { "usage" : "G", "type" : "outputMode" }, "nslimit" : { "usage" : "G", "type" : "double" },
"overlap" : { "usage" : "G", "type" : "string" }, "nslimit1" : { "usage" : "G", "type" : "double" },
"overlap_scaling" : { "usage" : "G", "type" : "double" }, "ordering" : { "usage" : "GN", "type" : "string" },
"pack" : { "usage" : "G", "type" : "int" }, "orientation" : { "usage" : "GN", "type" : "string" },
"packmode" : { "usage" : "G", "type" : "packMode" }, "outputorder" : { "usage" : "G", "type" : "outputMode" },
"pad" : { "usage" : "G", "type" : "pointf" }, "overlap" : { "usage" : "G", "type" : "string" },
"page" : { "usage" : "G", "type" : "pointf" }, "overlap_scaling" : { "usage" : "G", "type" : "double" },
"pagedir" : { "usage" : "G", "type" : "pagedir" }, "pack" : { "usage" : "G", "type" : "int" },
"pencolor" : { "usage" : "C", "type" : "color" }, "packmode" : { "usage" : "G", "type" : "packMode" },
"penwidth" : { "usage" : "CNE", "type" : "double" }, "pad" : { "usage" : "G", "type" : "pointf" },
"peripheries" : { "usage" : "NC", "type" : "int" }, "page" : { "usage" : "G", "type" : "pointf" },
"pin" : { "usage" : "N", "type" : "bool" }, "pagedir" : { "usage" : "G", "type" : "pagedir" },
"pos" : { "usage" : "EN", "type" : "point" }, "pencolor" : { "usage" : "C", "type" : "color" },
"quadtree" : { "usage" : "G", "type" : "quadType" }, "penwidth" : { "usage" : "CNE", "type" : "double" },
"quantum" : { "usage" : "G", "type" : "double" }, "peripheries" : { "usage" : "NC", "type" : "int" },
"rank" : { "usage" : "S", "type" : "rankType" }, "pin" : { "usage" : "N", "type" : "bool" },
"rankdir" : { "usage" : "G", "type" : "rankdir" }, "pos" : { "usage" : "EN", "type" : "point" },
"ranksep" : { "usage" : "G", "type" : "double" }, "quadtree" : { "usage" : "G", "type" : "quadType" },
"ratio" : { "usage" : "G", "type" : "string" }, "quantum" : { "usage" : "G", "type" : "double" },
"rects" : { "usage" : "N", "type" : "rect" }, "rank" : { "usage" : "S", "type" : "rankType" },
"regular" : { "usage" : "N", "type" : "bool" }, "rankdir" : { "usage" : "G", "type" : "rankdir" },
"remincross" : { "usage" : "G", "type" : "bool" }, "ranksep" : { "usage" : "G", "type" : "double" },
"repulsiveforce" : { "usage" : "G", "type" : "double" }, "ratio" : { "usage" : "G", "type" : "string" },
"resolution" : { "usage" : "G", "type" : "double" }, "rects" : { "usage" : "N", "type" : "rect" },
"root" : { "usage" : "GN", "type" : "string" }, "regular" : { "usage" : "N", "type" : "bool" },
"rotate" : { "usage" : "G", "type" : "int" }, "remincross" : { "usage" : "G", "type" : "bool" },
"samehead" : { "usage" : "E", "type" : "string" }, "repulsiveforce" : { "usage" : "G", "type" : "double" },
"sametail" : { "usage" : "E", "type" : "string" }, "resolution" : { "usage" : "G", "type" : "double" },
"samplepoints" : { "usage" : "N", "type" : "int" }, "root" : { "usage" : "GN", "type" : "string" },
"searchsize" : { "usage" : "G", "type" : "int" }, "rotate" : { "usage" : "G", "type" : "int" },
"sep" : { "usage" : "G", "type" : "double" }, "rotation" : { "usage" : "G", "type" : "double" },
"shape" : { "usage" : "N", "type" : "shape" }, "samehead" : { "usage" : "E", "type" : "string" },
"shapefile" : { "usage" : "N", "type" : "string" }, "sametail" : { "usage" : "E", "type" : "string" },
"showboxes" : { "usage" : "ENG", "type" : "int" }, "samplepoints" : { "usage" : "N", "type" : "int" },
"sides" : { "usage" : "N", "type" : "int" }, "scale" : { "usage" : "G", "type" : "double" },
"size" : { "usage" : "G", "type" : "pointf" }, "searchsize" : { "usage" : "G", "type" : "int" },
"skew" : { "usage" : "N", "type" : "double" }, "sep" : { "usage" : "G", "type" : "double" },
"smoothing" : { "usage" : "G", "type" : "smoothType" }, "shape" : { "usage" : "N", "type" : "shape" },
"sortv" : { "usage" : "GCN", "type" : "int" }, "shapefile" : { "usage" : "N", "type" : "string" },
"splines" : { "usage" : "G", "type" : "string" }, "showboxes" : { "usage" : "ENG", "type" : "int" },
"start" : { "usage" : "G", "type" : "startType" }, "sides" : { "usage" : "N", "type" : "int" },
"style" : { "usage" : "ENC", "type" : "style" }, "size" : { "usage" : "G", "type" : "pointf" },
"stylesheet" : { "usage" : "G", "type" : "string" }, "skew" : { "usage" : "N", "type" : "double" },
"tailURL" : { "usage" : "E", "type" : "escString" }, "smoothing" : { "usage" : "G", "type" : "smoothType" },
"tailclip" : { "usage" : "E", "type" : "bool" }, "sortv" : { "usage" : "GCN", "type" : "int" },
"tailhref" : { "usage" : "E", "type" : "escString" }, "splines" : { "usage" : "G", "type" : "string" },
"taillabel" : { "usage" : "E", "type" : "lblString" }, "start" : { "usage" : "G", "type" : "startType" },
"tailport" : { "usage" : "E", "type" : "portPos" }, "style" : { "usage" : "ENCG", "type" : "style" },
"tailtarget" : { "usage" : "E", "type" : "escString" }, "stylesheet" : { "usage" : "G", "type" : "string" },
"tailtooltip" : { "usage" : "E", "type" : "escString" }, "tailURL" : { "usage" : "E", "type" : "escString" },
"target" : { "usage" : "ENGC", "type" : "escString" }, "tailclip" : { "usage" : "E", "type" : "bool" },
"tooltip" : { "usage" : "NEC", "type" : "escString" }, "tailhref" : { "usage" : "E", "type" : "escString" },
"truecolor" : { "usage" : "G", "type" : "bool" }, "taillabel" : { "usage" : "E", "type" : "lblString" },
"vertices" : { "usage" : "N", "type" : "pointfList" }, "tailport" : { "usage" : "E", "type" : "portPos" },
"viewport" : { "usage" : "G", "type" : "viewPort" }, "tailtarget" : { "usage" : "E", "type" : "escString" },
"voro_margin" : { "usage" : "G", "type" : "double" }, "tailtooltip" : { "usage" : "E", "type" : "escString" },
"weight" : { "usage" : "E", "type" : "double" }, "target" : { "usage" : "ENGC", "type" : "escString" },
"width" : { "usage" : "N", "type" : "double" }, "tooltip" : { "usage" : "NEC", "type" : "escString" },
"z" : { "usage" : "N", "type" : "double" } "truecolor" : { "usage" : "G", "type" : "bool" },
"vertices" : { "usage" : "N", "type" : "pointfList" },
"viewport" : { "usage" : "G", "type" : "viewPort" },
"voro_margin" : { "usage" : "G", "type" : "double" },
"weight" : { "usage" : "E", "type" : "double" },
"width" : { "usage" : "N", "type" : "double" },
"xlabel" : { "usage" : "EN", "type" : "lblString" },
"z" : { "usage" : "N", "type" : "double" }
}; };


var gType = { var gType = {
Expand Down
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{ {
"name" : "graphviz", "name" : "graphviz",
"version" : "0.0.7", "version" : "0.0.8",
"author": "Gregoire Lejeune <gregoire.lejeune@free.fr> (http://algorithmique.net/)", "author": "Gregoire Lejeune <gregoire.lejeune@free.fr> (http://algorithmique.net/)",
"description" : "Node.js interface to the GraphViz graphing tool", "description" : "Node.js interface to the GraphViz graphing tool",
"homepage" : "http://algorithmique.net/", "homepage" : "http://algorithmique.net/",
Expand Down

0 comments on commit 8db289b

Please sign in to comment.