annotate toolboxes/graph_visualisation/share/graphviz/doc/Dot.ref @ 0:cc4b1211e677 tip

initial commit to HG from Changeset: 646 (e263d8a21543) added further path and more save "camirversion.m"
author Daniel Wolff
date Fri, 19 Aug 2016 13:07:06 +0200
parents
children
rev   line source
Daniel@0 1 Quick Reference Guide for GraphViz
Daniel@0 2 20 February 2002
Daniel@0 3
Daniel@0 4
Daniel@0 5 Command-line Invocation
Daniel@0 6
Daniel@0 7 ------------------------------------------------------------------------
Daniel@0 8 All GraphViz programs have a similar invocation:
Daniel@0 9 cmd [ flags ] [ input files ]
Daniel@0 10 If no input files are supplied, the program reads from stdin.
Daniel@0 11
Daniel@0 12 Flags
Daniel@0 13
Daniel@0 14 -Gname=value
Daniel@0 15 Set a graph attribute.
Daniel@0 16 -Nname=value
Daniel@0 17 Set a default node attribute.
Daniel@0 18 -Ename=value
Daniel@0 19 Set a default edge attribute.
Daniel@0 20 -Tformat
Daniel@0 21 Set output language to one of the supported formats. By default,
Daniel@0 22 attributed dot is produced.
Daniel@0 23 -V
Daniel@0 24 Emit version information and exit.
Daniel@0 25 -llibfile
Daniel@0 26 User-supplied, device-dependent library files. Multiple libraries may
Daniel@0 27 be given. These names are passed to the code generator at the beginning
Daniel@0 28 of output.
Daniel@0 29 -n[num]
Daniel@0 30 Sets no-op flag in neato. If set, neato assumes nodes have already been
Daniel@0 31 positioned and have a pos attribute giving this position. It then just
Daniel@0 32 computes the edge layouts and emits the graph in the appropriate
Daniel@0 33 format. If num is supplied and > 1, neato checks for previously
Daniel@0 34 positioned edges, with control points provided in the pos attribute. It
Daniel@0 35 uses these if given; otherwise, it computes the edge layout.
Daniel@0 36 -ooutfile
Daniel@0 37 Write output to file outfile. By default, output goes to stdout.
Daniel@0 38 -s[scale]
Daniel@0 39 Set input scale to scale. If this value is omitted, 72.0 is used. This
Daniel@0 40 number is used to convert the point coordinate units used in the pos
Daniel@0 41 attribute into inches. For example, dot -Tdot produces pos values in
Daniel@0 42 points, with 72 per inch. Thus, to use this output as input to neato
Daniel@0 43 -n, one needs -s (equivalently, -s72).
Daniel@0 44 -v
Daniel@0 45 Verbose mode
Daniel@0 46 -x
Daniel@0 47 In neato, on input, prune isolated nodes and peninsulas. This removes
Daniel@0 48 uninteresting graph structure and produces a less cluttered drawing.
Daniel@0 49
Daniel@0 50 Note that the file contents override the -G, -N and -E flags. In addition,
Daniel@0 51 these flags cause the related attributes to be permanently attached to the
Daniel@0 52 graph. Thus, if attributed dot is used for output, the graph will have these
Daniel@0 53 attributes.
Daniel@0 54
Daniel@0 55 ------------------------------------------------------------------------
Daniel@0 56
Daniel@0 57 The DOT Language
Daniel@0 58
Daniel@0 59 ------------------------------------------------------------------------
Daniel@0 60 digraph G {foo -> bar; ... } or graph G { foo -- bar; ...}
Daniel@0 61
Daniel@0 62 To connect all pairs:
Daniel@0 63 {foo bar}->{baz bart}
Daniel@0 64
Daniel@0 65 To make a chain of links:
Daniel@0 66 foo->bar->baz
Daniel@0 67
Daniel@0 68 Commas inside [...] and semicolons inside {...} are optional.
Daniel@0 69
Daniel@0 70 Quotes are needed on attribute values to protect spaces, commas, periods, etc.
Daniel@0 71
Daniel@0 72 // C++ like comment: to end of line
Daniel@0 73 /* C-like comment: between delimiters */
Daniel@0 74
Daniel@0 75 For a complete language description, see
Daniel@0 76
Daniel@0 77 http://www.research.att.com/~erg/graphviz/info/lang.html
Daniel@0 78
Daniel@0 79 ------------------------------------------------------------------------
Daniel@0 80
Daniel@0 81 Attributes
Daniel@0 82
Daniel@0 83 ------------------------------------------------------------------------
Daniel@0 84
Daniel@0 85 Name Used By Type Default Minimum Notes
Daniel@0 86 Damping G double 0.99 0.0 neato only
Daniel@0 87 Epsilon G double (.0001 * # nodes) neato only
Daniel@0 88 URL ENGC string
Daniel@0 89 arrowhead E arrowType normal
Daniel@0 90 arrowsize E double 1.0 0.0
Daniel@0 91 arrowtail E arrowType normal
Daniel@0 92 bb G rect write-only
Daniel@0 93 bgcolor G color
Daniel@0 94 bottomlabel N string ""
Daniel@0 95 center G bool false
Daniel@0 96 clusterrank G clusterMode local dot only
Daniel@0 97 color ENC color black
Daniel@0 98 comment ENG string ""
Daniel@0 99 compound G bool false dot only
Daniel@0 100 concentrate G bool false dot only
Daniel@0 101 constraint E bool true dot only
Daniel@0 102 decorate E bool false
Daniel@0 103
Daniel@0 104 dir E dirType forward(directed)
Daniel@0 105 none(undirected)
Daniel@0 106 distortion N double 0.0 -100.0
Daniel@0 107
Daniel@0 108 fillcolor NC color lightgrey(nodes)
Daniel@0 109 black(clusters)
Daniel@0 110 fixedsize N bool false
Daniel@0 111 fontcolor ENGC color black
Daniel@0 112 fontname ENGC string "Times-Roman"
Daniel@0 113 fontpath G string ""
Daniel@0 114 fontsize ENGC double 14.0 1.0
Daniel@0 115 group N string "" dot only
Daniel@0 116 headURL E string ""
Daniel@0 117 headlabel E string ""
Daniel@0 118 headport E portPos center
Daniel@0 119 height N double 0.5 0.02
Daniel@0 120 K G double 1.0 0.0 sfdp only
Daniel@0 121
Daniel@0 122 label ENGC string ""
Daniel@0 123 "\N" (nodes)
Daniel@0 124 labelangle E double -25.0 -180.0
Daniel@0 125 labeldistance E double 1.0 0.0
Daniel@0 126 labelfloat E bool false
Daniel@0 127 labelfontcolor E color black
Daniel@0 128 labelfontname E string "Times-Roman"
Daniel@0 129 labelfontsize E double 11.0 1.0
Daniel@0 130 labeljust C string "" dot only
Daniel@0 131
Daniel@0 132 labelloc GC string "t"(clusters) dot only
Daniel@0 133 "b"(root graphs)
Daniel@0 134 layer EN layerRange ""
Daniel@0 135 layers G layerList ""
Daniel@0 136 len E double 1.0 neato only
Daniel@0 137 levels G int MAXINT 0 sfdp only
Daniel@0 138 lhead E string "" dot only
Daniel@0 139 lp EGC point write-only
Daniel@0 140 ltail E string "" dot only
Daniel@0 141
Daniel@0 142 margin G double
Daniel@0 143 pointf
Daniel@0 144 maxiter G int MAXINT neato only
Daniel@0 145 mclimit G double 1.0 dot only
Daniel@0 146 minlen E int 1 0 dot only
Daniel@0 147 model G string "" neato only
Daniel@0 148 nodesep G double 0.25 0.02 dot only
Daniel@0 149 normalize G bool false neato only
Daniel@0 150 nslimit
Daniel@0 151 nslimit1 G double dot only
Daniel@0 152 ordering G string "" dot only
Daniel@0 153 orientation N double 0.0 360.0
Daniel@0 154 orientation G string ""
Daniel@0 155
Daniel@0 156 overlap G string "" neato/sfdp only
Daniel@0 157 bool
Daniel@0 158 page G pointf
Daniel@0 159 pagedir G pagedir BL
Daniel@0 160 peripheries N int 0
Daniel@0 161 pin N bool neato only
Daniel@0 162
Daniel@0 163 pos EN point
Daniel@0 164 splineType
Daniel@0 165 quadtree G string "" sfdp only
Daniel@0 166 quantum G double 0.0 0.0
Daniel@0 167 rank S rankType dot only
Daniel@0 168 rankdir G rankdir TB dot only
Daniel@0 169 ranksep G double 0.5 0.02
Daniel@0 170 ratio G double
Daniel@0 171 rects N rect write-only
Daniel@0 172 regular N bool false
Daniel@0 173 remincross G bool false dot only
Daniel@0 174 repulsiveforce G double 1 0.0 sfdp only
Daniel@0 175 rotate G int 0
Daniel@0 176 samehead E string "" dot only
Daniel@0 177 sametail E string "" dot only
Daniel@0 178 samplepoints G int 8
Daniel@0 179 searchsize G int 30 dot only
Daniel@0 180 sep G double 0.01 neato only
Daniel@0 181 shape N shape ellipse
Daniel@0 182 shapefile N string ""
Daniel@0 183 showboxes ENG int 0 0 dot only
Daniel@0 184 sides N int 4 0
Daniel@0 185 size G pointf
Daniel@0 186 skew N double 0.0 -100.0
Daniel@0 187 smoothing G string "" sfdp only
Daniel@0 188 splines G bool false neato only
Daniel@0 189
Daniel@0 190 start G string "" neato only
Daniel@0 191 int
Daniel@0 192 style ENC style
Daniel@0 193 styleheet G style
Daniel@0 194 tailURL E string ""
Daniel@0 195 taillabel E string ""
Daniel@0 196 tailport E portPos center
Daniel@0 197 toplabel N string ""
Daniel@0 198 vertices N pointfList write-only
Daniel@0 199 voro_margin G double 0.05 0.0 neato only
Daniel@0 200 w E double 1.0 neato only
Daniel@0 201
Daniel@0 202 weight E double 1.0 0(dot)
Daniel@0 203 1(neato)
Daniel@0 204 width N double 0.75 0.01
Daniel@0 205
Daniel@0 206 z N double 0.0 -MAXFLOAT
Daniel@0 207 -1000
Daniel@0 208 ------------------------------------------------------
Daniel@0 209 For the bool type, TRUE values are represented by "true" (case-insensitive)
Daniel@0 210 and any non-zero integer, and FALSE values by "false" (case-insensitive) and
Daniel@0 211 zero.
Daniel@0 212
Daniel@0 213 In the Used By field, the characters E, N, G and C represent edges, nodes,
Daniel@0 214 the root graph and cluster subgraphs, respectively. This field indicates
Daniel@0 215 which graph component uses the attribute.
Daniel@0 216 ------------------------------------------------------------------------
Daniel@0 217
Daniel@0 218 Attribute Descriptions
Daniel@0 219
Daniel@0 220 Damping
Daniel@0 221 Factor damping force motions. On each iteration, a nodes movement is
Daniel@0 222 limited to this factor of its potential motion. By being less than 1.0,
Daniel@0 223 the system tends to ``cool'', thereby preventing cycling.
Daniel@0 224 Epsilon
Daniel@0 225 Terminating condition. If the length squared of all energy gradients
Daniel@0 226 are < Epsilon, the algorithm stops.
Daniel@0 227 URL
Daniel@0 228 Incorporated into device-dependent output. At present, used for ps2,
Daniel@0 229 i*map and svg. For ps2, URLs can be attached to nodes and the root
Daniel@0 230 graph. When distilled to PDF, such nodes are active links and the graph
Daniel@0 231 URL can be used as a base URL. For i*map, URLs can be attached to
Daniel@0 232 nodes, edges and the root graph. If the node or edge URL contains "\N",
Daniel@0 233 this is replaced by the object's name. For svg, URLs can be attached to
Daniel@0 234 nodes, edges and clusters, with "\N" replacement done for all three.
Daniel@0 235 arrowhead
Daniel@0 236 Style of arrowhead on head of edge.
Daniel@0 237 arrowsize
Daniel@0 238 Multiplicative scale factor for arrowheads.
Daniel@0 239 arrowtail
Daniel@0 240 Style of arrowhead on tail of edge.
Daniel@0 241 bb
Daniel@0 242 Bounding box of drawing in integer points.
Daniel@0 243 bgcolor
Daniel@0 244 Color used as background for canvas, plus initial fill color.
Daniel@0 245 bottomlabel
Daniel@0 246 Additional label near bottom of nodes of shape M*.
Daniel@0 247 center
Daniel@0 248 If true, the drawing is centered in the output canvas.
Daniel@0 249 clusterrank
Daniel@0 250 Mode used for handling clusters. If clusterrank is "local", a subgraph
Daniel@0 251 whose name begins with "cluster" is given special treatment. The
Daniel@0 252 subgraph is laid out separately, and then integrated as a unit into its
Daniel@0 253 parent graph, with a bounding rectangle drawn about it. If the cluster
Daniel@0 254 has a label parameter, this label is displayed within the rectangle.
Daniel@0 255 Note also that there can be clusters within clusters. At present, the
Daniel@0 256 modes "global" and "none" appear to be identical, both turning off the
Daniel@0 257 special cluster processing.
Daniel@0 258 color
Daniel@0 259 Basic drawing color for graphics.
Daniel@0 260 comment
Daniel@0 261 Comments are inserted into output. Device-dependent
Daniel@0 262 compound
Daniel@0 263 If true, allow edges between clusters. (See lhead and ltail below.)
Daniel@0 264 concentrate
Daniel@0 265 If true, use edge concentrators.
Daniel@0 266 constraint
Daniel@0 267 If false, the edge is not used in ranking the nodes. For example, in
Daniel@0 268 the graph
Daniel@0 269
Daniel@0 270 digraph G {
Daniel@0 271 a -> c;
Daniel@0 272 a -> b;
Daniel@0 273 b -> c [constraint=false];
Daniel@0 274 }
Daniel@0 275
Daniel@0 276
Daniel@0 277 the edge b -> c does not add a constraint during rank assignment, so
Daniel@0 278 the only constraints are that a be above b and c.
Daniel@0 279
Daniel@0 280 decorate
Daniel@0 281 If true, attach edge label to edge by a 2-segment polyline, underlining
Daniel@0 282 the label, then going to the closest point of spline.
Daniel@0 283 dir
Daniel@0 284 Set edge type for drawing arrowheads.
Daniel@0 285 distortion
Daniel@0 286 Distortion factor for shape=polygon. Positive values cause top part to
Daniel@0 287 be larger than bottom; negative values do the opposite.
Daniel@0 288 fillcolor
Daniel@0 289 If fillcolor is not defined, color is used. If this is not defined, the
Daniel@0 290 default is used, except for shape=point or when the output format is
Daniel@0 291 MIF, which use black by default.
Daniel@0 292 fixedsize
Daniel@0 293 If true, the node size is kept fixed and not expanded to contain the
Daniel@0 294 text label.
Daniel@0 295 fontcolor
Daniel@0 296 Color used for text.
Daniel@0 297 fontname
Daniel@0 298 Font used for text.
Daniel@0 299 fontpath
Daniel@0 300 Directory list used by libgd to search for bitmap fonts. If fontpath is
Daniel@0 301 not set, the environment variable DOTFONTPATH is checked. If that is
Daniel@0 302 not set, GDFONTPATH is checked. If not set, libgd uses its compiled-in
Daniel@0 303 font path.
Daniel@0 304 fontsize
Daniel@0 305 Font size, in points, used for text.
Daniel@0 306 group
Daniel@0 307 If the end points of an edge belong to the same group, i.e., have the
Daniel@0 308 same group attribute, parameters are set to avoid crossings and keep
Daniel@0 309 the edges straight.
Daniel@0 310 headURL
Daniel@0 311 For the output format imap, or cmap, if headURL is defined, it is
Daniel@0 312 output as part of the head label of the edge. If headURL contains
Daniel@0 313 "\N", this will be replaced by the head label text.
Daniel@0 314 headlabel
Daniel@0 315 Text label to be placed near head of edge.
Daniel@0 316 headport
Daniel@0 317 Indicates where on the head node to attach the head of the edge. In the
Daniel@0 318 default case, the edge is aimed towards the center of the node, and
Daniel@0 319 then clipped at the node boundary.
Daniel@0 320 height
Daniel@0 321 Height of node, in inches.
Daniel@0 322 K constant used in the Fruchterman-Reingold force directed model.
Daniel@0 323 label
Daniel@0 324 Text label attached to objects. The escape sequences "\n", "\l" and
Daniel@0 325 "\r" divide the label into lines, centered, left-justified and
Daniel@0 326 right-justified, respectively. The escape sequence "\N" represents a
Daniel@0 327 node's name. If a node's shape is record, then the label can have a
Daniel@0 328 special format which describes the record layout.
Daniel@0 329 labelangle
Daniel@0 330 Angle, in degrees, that the headlabel(taillabel) is rotated from the
Daniel@0 331 angle the edge makes incident with the head(tail) node, respectively.
Daniel@0 332 labeldistance
Daniel@0 333 Multiplicative scaling factor adjusting the distance that the
Daniel@0 334 headlabel(taillabel) is the from head(tail) node.
Daniel@0 335 labelfloat
Daniel@0 336 If true, allows edge labels to be less constrained in position. In
Daniel@0 337 particular, it may appear on top of other edges.
Daniel@0 338 labelfontcolor
Daniel@0 339 Color used for headlabel and taillabel.
Daniel@0 340 labelfontname
Daniel@0 341 Font used for headlabel and taillabel.
Daniel@0 342 labelfontsize
Daniel@0 343 Font size, in points, used for headlabel and taillabel.
Daniel@0 344 labeljust
Daniel@0 345 Justification for cluster labels. If "r", the label is right-justified
Daniel@0 346 within bounding rectangle; otherwise, left-justified.
Daniel@0 347 labelloc
Daniel@0 348 Top/bottom placement of graph and cluster labels. If the attribute is
Daniel@0 349 "t", place label at the top; if the attribute is "b", place label at
Daniel@0 350 the bottom. By default, root graph labels go on the bottom and cluster
Daniel@0 351 labels go on the top.
Daniel@0 352 layer
Daniel@0 353 Specifies layers in which the node or edge is present.
Daniel@0 354 layers
Daniel@0 355 Specifies a linearly ordered list of layer names attached to the graph
Daniel@0 356 The graph is then output in separate layers. Only those components
Daniel@0 357 belonging to the current output layer appear. For more information, see
Daniel@0 358 the page How to use drawing layers (overlays).
Daniel@0 359 len
Daniel@0 360 Preferred edge length, in inches.
Daniel@0 361 levels
Daniel@0 362 Number of levels allowed in the multilevel scheme. Default is MAXINT.
Daniel@0 363 lhead
Daniel@0 364 Logical head of an edge. When compound is true, if lhead is defined and
Daniel@0 365 is the name of a cluster containing the real head, the edge is clipped
Daniel@0 366 to the boundary of the cluster.
Daniel@0 367 lp
Daniel@0 368 Label position, in points.
Daniel@0 369 ltail
Daniel@0 370 Logical tail of an edge. When compound is true, if ltail is defined and
Daniel@0 371 is the name of a cluster containing the real tail, the edge is clipped
Daniel@0 372 to the boundary of the cluster.
Daniel@0 373 margin
Daniel@0 374 Set x and y margins of canvas, in inches. In first case, both margins
Daniel@0 375 are set equal to the given value.
Daniel@0 376 maxiter
Daniel@0 377 Sets the number of iterations used.
Daniel@0 378 mclimit
Daniel@0 379 Multiplicative scale factor used to alter the MinQuit (default = 8) and
Daniel@0 380 MaxIter (default = 24) parameters used during crossing minimization.
Daniel@0 381 These correspond to the number of tries without improvement before
Daniel@0 382 quitting and the maximum number of iterations in each pass.
Daniel@0 383 minlen
Daniel@0 384 Minimum edge length (rank difference between head and tail).
Daniel@0 385 model
Daniel@0 386 If "circuit", use circuit resistance model to compute dissimilarity
Daniel@0 387 values; otherwise, use shortest path model.
Daniel@0 388 nodesep
Daniel@0 389 Minimum space between two adjacent nodes in the same rank, in inches.
Daniel@0 390 normalize
Daniel@0 391 If set, normalize coordinates of final layout so that the first point
Daniel@0 392 is at the origin, and then rotate the layout so that the first edge is
Daniel@0 393 horizontal.
Daniel@0 394 nslimit ,
Daniel@0 395 nslimit1
Daniel@0 396 Used to set number of iterations in network simplex applications.
Daniel@0 397 nslimit is used in computing node x coordinates, nslimit1 for ranking
Daniel@0 398 nodes. If defined, # iterations = nslimit(1) * # nodes; otherwise, #
Daniel@0 399 iterations = MAXINT.
Daniel@0 400 ordering
Daniel@0 401 If "out" for a graph G, and n is a node in G, then edges n->* appear
Daniel@0 402 left-to-right in the same order in which they are defined.
Daniel@0 403 orientation
Daniel@0 404 Angle, in degrees, used to rotate node shapes.
Daniel@0 405 orientation
Daniel@0 406 If "[lL]*", set graph orientation to landscape Used only if rotate is
Daniel@0 407 not defined.
Daniel@0 408 overlap
Daniel@0 409 If "scale", remove node overlaps by scaling; if converts to false,
Daniel@0 410 remove node overlaps by the Voronoi technique; otherwise, leave
Daniel@0 411 overlaps.
Daniel@0 412 page
Daniel@0 413 Width and height of output pages, in inches. If this is set and is
Daniel@0 414 smaller than the size of the layout, a rectangular array of pages of
Daniel@0 415 the specified page size is overlaid on the layout, with origins aligned
Daniel@0 416 in the lower-left corner, thereby partitioning the layout into pages.
Daniel@0 417 The pages are then produced one at a time, in pagedir order.
Daniel@0 418 pagedir
Daniel@0 419 If the page attribute is set and applicable, this attribute specifies
Daniel@0 420 the order in which the pages are emitted. This is limited to one of the
Daniel@0 421 8 row or column major orders.
Daniel@0 422 peripheries
Daniel@0 423 Set number of peripheries used in polygonal shapes.
Daniel@0 424 pin
Daniel@0 425 If true and the node has a pos attribute on input, neato prevents the
Daniel@0 426 node from moving from the input position. This property can also be
Daniel@0 427 specified in the pos attribute itself (cf. the point type).
Daniel@0 428 pos
Daniel@0 429 Position of node, or spline control points, in points. In neato, pos
Daniel@0 430 can be used to set initial position of a node. Concerning this, see the
Daniel@0 431 -s command line flag.
Daniel@0 432 quantum
Daniel@0 433 If quantum > 0.0, node label dimensions will be rounded to integral
Daniel@0 434 multiples of the quantum.
Daniel@0 435 quadtree
Daniel@0 436 Quadtree scheme to use. Values are "normal" (default), "fast" or "none".
Daniel@0 437 "fast" gives about 2-4 overall speedup compared with "normal", though
Daniel@0 438 layout quality can suffer a little.
Daniel@0 439 rank
Daniel@0 440 Rank constraints on the nodes in a subgraph. If rank="same", all nodes
Daniel@0 441 are placed on the same rank. If rank="min", all nodes are placed on the
Daniel@0 442 minimum rank. If rank="source", all nodes are placed on the minimum
Daniel@0 443 rank, and the only nodes on the minimum rank belong to some subgraph
Daniel@0 444 whose rank attribute is "source" or "min". Analogous criteria hold for
Daniel@0 445 rank="max" and rank="sink". (Note: the minimum rank is topmost or
Daniel@0 446 leftmost, and the maximum rank is bottommost or rightmost.)
Daniel@0 447 rankdir
Daniel@0 448 Sets direction of graph layout. If rankdir="LR", the graph is laid out
Daniel@0 449 from left to right, i.e., directed edges tend to go from left to right.
Daniel@0 450 By default, graphs are laid out from top to bottom.
Daniel@0 451 ranksep
Daniel@0 452 In dot, this the gives desired rank separation, in inches. This is the
Daniel@0 453 minimum vertical distance between the bottom of the nodes in one rank
Daniel@0 454 and the tops of nodes in the next. If the value contains "equally", the
Daniel@0 455 centers of all ranks are spaced equally apart. Note that both settings
Daniel@0 456 are possible, e.g., ranksep = "1.2 equally". In twopi, specifies radial
Daniel@0 457 separation of ranks.
Daniel@0 458 ratio
Daniel@0 459 Sets the aspect ratio (drawing height/drawing width) for the drawing.
Daniel@0 460 Note that this is adjusted before the size attribute constraints are
Daniel@0 461 enforced.
Daniel@0 462
Daniel@0 463 If ratio is numeric, it is taken as the desired aspect ratio. Then, if
Daniel@0 464 the actual aspect ratio is less than the desired ratio, the drawing
Daniel@0 465 height is scaled up to achieve the desired ratio; if the actual ratio
Daniel@0 466 is greater than that desired ratio, the drawing width is scaled up.
Daniel@0 467
Daniel@0 468 If ratio = "fill" and the size attribute is set, the drawing is scaled
Daniel@0 469 to achieve the aspect ratio implied by size. As size is set, when the
Daniel@0 470 drawing is later scaled to fit that rectangle, the resulting picture
Daniel@0 471 will fill the rectangle.
Daniel@0 472
Daniel@0 473 If ratio = "compress" and the size attribute is set, dot attempts to
Daniel@0 474 compress the initial layout to fit in the given size. This achieves a
Daniel@0 475 tighter packing of nodes but reduces the balance and symmetry.
Daniel@0 476
Daniel@0 477 If ratio = "auto", the page attribute is set and the graph cannot be
Daniel@0 478 drawn on a single page, then size is set to an ``ideal'' value. In
Daniel@0 479 particular, the size in a given dimension will be the smallest integral
Daniel@0 480 multiple of the page size in that dimension which is at least half the
Daniel@0 481 current size. The two dimensions are then scaled independently to the
Daniel@0 482 new size.
Daniel@0 483 rects
Daniel@0 484 Rectangles for fields of records, in points.
Daniel@0 485 regular
Daniel@0 486 If true, force polygon to be regular.
Daniel@0 487 repulsiveforce
Daniel@0 488 The power of repulsive force used in an extended Fruchterman-Reingold
Daniel@0 489 force directed model. Default is 1. Values larger than 1 tend to reduce
Daniel@0 490 the warping effect at the expensive of less clustering.
Daniel@0 491 remincross
Daniel@0 492 If true and there are multiple clusters, run cross minimization a
Daniel@0 493 second time.
Daniel@0 494 rotate
Daniel@0 495 If 90, set drawing orientation to landscape.
Daniel@0 496 samehead
Daniel@0 497 Edges with the same head and the same samehead value are aimed at the
Daniel@0 498 same point on the head.
Daniel@0 499 sametail
Daniel@0 500 Edges with the same tail and the same sametail value are aimed at the
Daniel@0 501 same point on the tail.
Daniel@0 502 samplepoints
Daniel@0 503 If the input graph defines the vertices attribute, and output is plain*
Daniel@0 504 or attributed dot, this give the number of points used to represent
Daniel@0 505 circles and ellipses. It plays the same role in neato, when adjusting
Daniel@0 506 the layout to avoid overlapping nodes.
Daniel@0 507 searchsize
Daniel@0 508 During network simplex, maximum number of edges with negative cut
Daniel@0 509 values to search when looking for one with minimum cut value.
Daniel@0 510 sep
Daniel@0 511 Fraction to increase polygons (multiply coordinates by 1 + sep) for
Daniel@0 512 purposes of determining overlap. Guarantees a minimal non-zero distance
Daniel@0 513 between nodes.
Daniel@0 514 shape
Daniel@0 515 Set shape of node.
Daniel@0 516 shapefile
Daniel@0 517 For output format is ps* or svg*, if non-empty, taken as a filename
Daniel@0 518 containing a device-dependent description of a node's shape.
Daniel@0 519 showboxes
Daniel@0 520 Print guide boxes in PostScript at the beginning of routesplines if 1,
Daniel@0 521 or at the end if 2. (Debugging)
Daniel@0 522 sides
Daniel@0 523 Number of sides if shape=polygon.
Daniel@0 524 size
Daniel@0 525 Maximum width and height of drawing, inches. If defined and the drawing
Daniel@0 526 is too large, the drawing is uniformly scaled down so that it fits
Daniel@0 527 within the given size. Note that there is some interaction between the
Daniel@0 528 size and ratio attributes.
Daniel@0 529 skew
Daniel@0 530 Skew factor for shape=polygon. Positive values skew top of polygon to
Daniel@0 531 right; negative to left.
Daniel@0 532 smoothing
Daniel@0 533 A post processing step to smooth out uneven distribution of nodes. Possible
Daniel@0 534 values are "none" (default), "avg_dist", "graph_dist", "power_dist", "rng",
Daniel@0 535 "spring" and "triangle".
Daniel@0 536 splines
Daniel@0 537 If true, draw edges as splines. This requires non-overlapping nodes
Daniel@0 538 (cf. overlap).
Daniel@0 539 start
Daniel@0 540 Parameter used to determine the initial layout of nodes. By default,
Daniel@0 541 nodes are randomly placed in a square whose sides have length (#
Daniel@0 542 nodes). The same seed is always used for the random number generator,
Daniel@0 543 so the initial placement is repeatable. If start converts to an
Daniel@0 544 integer, this is used as a seed value for the random number generator.
Daniel@0 545 If start is "regular", the nodes are placed regularly about a circle.
Daniel@0 546 Finally, if start is defined but is not one of the above cases, the
Daniel@0 547 current time is used to pick a seed.
Daniel@0 548 style
Daniel@0 549 Set style for node or edge. For cluster subgraph, if "filled", the
Daniel@0 550 cluster box's background is filled.
Daniel@0 551 stylesheet
Daniel@0 552 The URL of a CSS stylesheet to be referenced from the output file.
Daniel@0 553 Relevant only for SVG output.
Daniel@0 554 tailURL
Daniel@0 555 When the output format is imap, or cmap, if tailURL is defined, it is
Daniel@0 556 output as part of the tail label of the edge. If tailURL
Daniel@0 557 contains "\N", this will be replaced by the tail label text.
Daniel@0 558 taillabel
Daniel@0 559 Text label to be placed near tail of edge.
Daniel@0 560 tailport
Daniel@0 561 Indicates where on the tail node to attach the tail of the edge.
Daniel@0 562 toplabel
Daniel@0 563 Additional label near top of nodes of shape M*.
Daniel@0 564 vertices
Daniel@0 565 If the input graph defines this attribute, the node is polynomial, and
Daniel@0 566 output is plain* or attributed dot, this attribute provides the
Daniel@0 567 coordinates of the vertices of the node's polynomial, in points. If the
Daniel@0 568 node is an ellipse or circle, the samplepoints attribute affects the
Daniel@0 569 output.
Daniel@0 570 voro_margin
Daniel@0 571 Factor to scale up drawing to allow margin for expansion in Voronoi
Daniel@0 572 technique. dim' = (1+2*margin)*dim.
Daniel@0 573 w
Daniel@0 574 Redundant definition of weight in neato, cf. bug 9.
Daniel@0 575 weight
Daniel@0 576 Weight of edge. Usually, the heavier the weight, the shorter (and, in
Daniel@0 577 dot, straighter and more vertical) an edge is.
Daniel@0 578 width
Daniel@0 579 Width of node, in inches.
Daniel@0 580 z
Daniel@0 581 Provides z coordinate for the node when output format is VRML.
Daniel@0 582
Daniel@0 583 ------------------------------------------------------------------------
Daniel@0 584
Daniel@0 585 Attribute Type Descriptions
Daniel@0 586
Daniel@0 587 arrowType
Daniel@0 588 "normal" "inv"
Daniel@0 589
Daniel@0 590 "dot" "invdot"
Daniel@0 591
Daniel@0 592 "odot" "invodot"
Daniel@0 593
Daniel@0 594 "none"
Daniel@0 595 clusterMode
Daniel@0 596 "local","global","none"
Daniel@0 597 color
Daniel@0 598 "#%2x%2x%2x" RGB
Daniel@0 599 "#%2x%2x%2x%2x"RGBA
Daniel@0 600 "%lf,%lf,%lf" HSV 0.0 <= values <= 1.0
Daniel@0 601 string color name
Daniel@0 602 dirType
Daniel@0 603 For an edge T -> H;
Daniel@0 604
Daniel@0 605 "forward" "back"
Daniel@0 606
Daniel@0 607 "both" "none"
Daniel@0 608
Daniel@0 609 For undirected edges T -- H;, one of the nodes, usually the righthand
Daniel@0 610 one, is treated as the head for the purpose of interpreting "forward"
Daniel@0 611 and "back".
Daniel@0 612 layerList
Daniel@0 613 list of strings separated by colons, tabs or spaces, defining layer
Daniel@0 614 names and implicitly numbered 1,2,...
Daniel@0 615 layerRange
Daniel@0 616 layerId or layerId[:\t ]layerId,
Daniel@0 617 where layerId = "all", decimal integer or layer name. (An integer i
Daniel@0 618 corresponds to layer i.)
Daniel@0 619 pagedir
Daniel@0 620 "BL", "BR", "TL", "TR", "RB", "RT", "LB", "LT". These specify the 8 row
Daniel@0 621 or column major orders for traversing a rectangular array, the first
Daniel@0 622 character corresponding to the major order and the second to the minor
Daniel@0 623 order. Thus, for "BL", the major order is from bottom to top, and the
Daniel@0 624 minor order is from left to right. This means the bottom row is
Daniel@0 625 traversed first, from left to right, then the next row up, from left to
Daniel@0 626 right, and so on, until the topmost row is traversed.
Daniel@0 627 point
Daniel@0 628 "%d,%d"('!') representing the point (x,y). The optional '!' indicates
Daniel@0 629 the node position should not change (input-only).
Daniel@0 630 pointf
Daniel@0 631 "%lf,%lf" representing the point (x,y).
Daniel@0 632 pointfList
Daniel@0 633 list of pointf, separated by spaces.
Daniel@0 634 portPos
Daniel@0 635 "n","ne","e","se","s","sw","w","nw" These correspond to the obvious
Daniel@0 636 compass points on the node.
Daniel@0 637 rankType
Daniel@0 638 "same", "min", "source", "max", "sink"
Daniel@0 639 rankdir
Daniel@0 640 "LR". Any other value corresponds to a top-down layout.
Daniel@0 641 rect
Daniel@0 642 "%d,%d,%d,%d" The rect llx,lly,urx,ury gives the coordinates, in
Daniel@0 643 points, of the lower-left corner (llx,lly) and the upper-right corner
Daniel@0 644 (urx,ury).
Daniel@0 645 shape
Daniel@0 646 A string specifying the shape of a node. There are three main types of
Daniel@0 647 shapes : polygon-based, record-based and PostScript-based.
Daniel@0 648 splineType
Daniel@0 649 spline ( ';' spline )*
Daniel@0 650 where spline= (endp)? (startp)? point (triple)]*
Daniel@0 651 and triple = point point point
Daniel@0 652 and endp = "e,%d,%d"
Daniel@0 653 and startp = "s,%d,%d"
Daniel@0 654 If a spline has points p1 p2 p3 ... pn, (n = 1 (mod 3)), the points
Daniel@0 655 correspond to the control points of a B-spline from p1 to pn. If startp
Daniel@0 656 is given, it touches one node of the edge, and the arrowhead goes from
Daniel@0 657 p1 to startp. If startp is not given, p1 touches a node. Similarly for
Daniel@0 658 pn and endp.
Daniel@0 659 style
Daniel@0 660 styleItem ( ',' styleItem )*
Daniel@0 661 where styleItem= name or name'('args')'
Daniel@0 662 and args = name ( ',' name )*
Daniel@0 663 and name = [^)(, ][^)(,]*
Daniel@0 664 At present, the recognized style names comprise "dashed", "dotted",
Daniel@0 665 "solid", "invis" and "bold" for nodes and edges, and "filled",
Daniel@0 666 "diagonals" and "rounded" for nodes only. Additional styles are
Daniel@0 667 available in device-dependent form. Style lists are passed to device
Daniel@0 668 drivers, which can use this to generate appropriate output.
Daniel@0 669
Daniel@0 670 Note that, at present, "rounded" cancels "filled", except for circles
Daniel@0 671 and ellipses. This holds for the Mrecord shape, which is rounded by
Daniel@0 672 definition.
Daniel@0 673
Daniel@0 674 ------------------------------------------------------------------------
Daniel@0 675
Daniel@0 676 Output Formats
Daniel@0 677
Daniel@0 678 ------------------------------------------------------------------------
Daniel@0 679 The output format is specified with the -Tlang flag on the command line,
Daniel@0 680 where lang is one of the following:
Daniel@0 681 Command-line
Daniel@0 682 parameter Format
Daniel@0 683 canon
Daniel@0 684 cmap Client-side imagemap
Daniel@0 685 dot DOT
Daniel@0 686 fig FIG
Daniel@0 687 gd
Daniel@0 688 gd2 GD/GD2 formats
Daniel@0 689 gif GIF
Daniel@0 690 hpgl HP-GL/2
Daniel@0 691 imap Server-side imagemap
Daniel@0 692 ismap Server-side imagemap (deprecated)
Daniel@0 693 jpg
Daniel@0 694 jpeg JPEG
Daniel@0 695 mif FrameMaker MIF format
Daniel@0 696 mp MetaPost
Daniel@0 697 pcl PCL
Daniel@0 698 pic PIC
Daniel@0 699 plain
Daniel@0 700 plain-ext Simple text format
Daniel@0 701 png Portable Network Graphics format
Daniel@0 702 ps PostScript
Daniel@0 703 ps2 PostScript for PDF
Daniel@0 704 svg
Daniel@0 705 svgz Scalable Vector Graphics
Daniel@0 706 vrml VRML
Daniel@0 707 vtx Visual Thought format
Daniel@0 708 wbmp Wireless BitMap format
Daniel@0 709 ------------------------------------------------------------------------
Daniel@0 710
Daniel@0 711 Format Descriptions
Daniel@0 712
Daniel@0 713 canon ,
Daniel@0 714 dot
Daniel@0 715 These two formats produce output in variations of the dot language.
Daniel@0 716 Using canon produces a prettyprinted version of the input, with no
Daniel@0 717 layout performed.
Daniel@0 718
Daniel@0 719 dot corresponds to attributed dot, and is the default output format. It
Daniel@0 720 reproduces the input, along with layout information for the graph. In
Daniel@0 721 particular, a bb attribute is attached to the graph, specifying the
Daniel@0 722 bounding box of the drawing. If the graph has a label, its position is
Daniel@0 723 specified by the lp attribute.
Daniel@0 724
Daniel@0 725 Each node gets pos, width and height attributes. If the node is a
Daniel@0 726 record, the record rectangles are given in the rects attribute. If the
Daniel@0 727 node is a polygon and the vertices attribute is defined, this attribute
Daniel@0 728 contains the vertices of the node.
Daniel@0 729
Daniel@0 730 Every edge is assigned a pos attribute, and if the edge has a label,
Daniel@0 731 the label position is given in lp.
Daniel@0 732 fig
Daniel@0 733 Outputs graphs in the FIG graphics language.
Daniel@0 734 gd ,
Daniel@0 735 gd2
Daniel@0 736 Output images in the GD and GD2 format. These are the internal formats
Daniel@0 737 used by the gd library. The latter is compressed.
Daniel@0 738 gif
Daniel@0 739 Outputs GIF bitmap images.
Daniel@0 740 hpgl
Daniel@0 741 Produces output in the HP-GL/2 vector graphic printer language.
Daniel@0 742 imap
Daniel@0 743 cmap
Daniel@0 744 Produces map files for server-side and client-side image maps,
Daniel@0 745 respectively. These can be used in a web page with a graphical
Daniel@0 746 form of the output, e.g. in JPEG or GIF format, to attach links
Daniel@0 747 to nodes and edges. For example, given the dot file
Daniel@0 748
Daniel@0 749 /* x.dot */
Daniel@0 750 digraph G {
Daniel@0 751 URL="http://www.research.att.com/";
Daniel@0 752 command [URL="command.html"];
Daniel@0 753 command -> output [URL="colors.html"];
Daniel@0 754 }
Daniel@0 755
Daniel@0 756
Daniel@0 757 this can be processed twice:
Daniel@0 758
Daniel@0 759 dot -Timap > x.map
Daniel@0 760 dot -Tgif > x.gif
Daniel@0 761
Daniel@0 762
Daniel@0 763 and then be referred to in a web page, such as
Daniel@0 764
Daniel@0 765 <A HREF="x.map">
Daniel@0 766 <IMG SRC="x.gif" ISMAP>
Daniel@0 767 </A>
Daniel@0 768
Daniel@0 769
Daniel@0 770 URLs can be attached to the root graph, nodes and edges. If the URL of
Daniel@0 771 a node contains the escape sequence "\N", it will be replaced by the
Daniel@0 772 node's name. If an edge has a URL, various points along the edge (but
Daniel@0 773 not the head or tail) will link to it. In addition, if the edge has a
Daniel@0 774 label, that will link to the URL.
Daniel@0 775
Daniel@0 776 As for the head of the edge, this is linked to the headURL, if set.
Daniel@0 777 Otherwise, it is linked to the edge's URL if that is defined. If the
Daniel@0 778 headURL contains the escape sequence "\N", it will be replaced by the
Daniel@0 779 headlabel, if defined. The analogous description holds for the tail,
Daniel@0 780 tailURL and taillabel.
Daniel@0 781 ismap
Daniel@0 782 Produces HTML image map files. This is a predecessor (circa 1994) of
Daniel@0 783 the IMAP format. Most servers now user the latter. URLs can be attached
Daniel@0 784 to the root graph, nodes and edges. Since edge links are attached to
Daniel@0 785 edge labels, an edge must have a label for its URL to be used. For both
Daniel@0 786 nodes and edges, if the URL has the escape sequence "\N" embedded in
Daniel@0 787 its string, this will be replaced with the node or edge name.
Daniel@0 788 jpg ,
Daniel@0 789 jpeg
Daniel@0 790 Output JPEG compressed image files. This format relies on the
Daniel@0 791 installation having the JPEG library.
Daniel@0 792 mif
Daniel@0 793 Generates Frame Maker MIF files.
Daniel@0 794 mp
Daniel@0 795 Produces MetaPost output.
Daniel@0 796 pcl
Daniel@0 797 Produces output in the PCL printer language. HP-GL is a subset of PCL,
Daniel@0 798 so that PCL output is the same as HP-GL, wrapped with some initial and
Daniel@0 799 final commands to set the printer to and from HP-GL mode.
Daniel@0 800 pic
Daniel@0 801 Outputs in PIC, the picture description language in the troff-family
Daniel@0 802 plain ,
Daniel@0 803 plain-ext
Daniel@0 804 The plain and plain-ext formats produce output using a simple,
Daniel@0 805 line-based language. The latter format differs in that, on edges, it
Daniel@0 806 provides port names on head and tail nodes when applicable.
Daniel@0 807
Daniel@0 808 There are four types of statements.
Daniel@0 809
Daniel@0 810 graph scale width height
Daniel@0 811 node name x y width height label style shape color fillcolor
Daniel@0 812 edge tail head n x1 y1 .. xn yn [label xl yl] style color
Daniel@0 813 stop
Daniel@0 814
Daniel@0 815
Daniel@0 816 graph
Daniel@0 817 The width and height values give the width and height of the
Daniel@0 818 drawing. The lower left corner of the drawing is at the origin.
Daniel@0 819 The scale value indicates how the drawing should be scaled if a
Daniel@0 820 size attribute was given and the drawing needs to be scaled to
Daniel@0 821 conform to that size. If no scaling is necessary, it will be set
Daniel@0 822 to 1.0. Note that all graph, node and edge coordinates and lengths
Daniel@0 823 are given unscaled.
Daniel@0 824 node
Daniel@0 825 The name value is the name of the node, and x and y give the
Daniel@0 826 node's position. The width and height are the width and height of
Daniel@0 827 the node. The label, style, shape, color and fillcolor give the
Daniel@0 828 node's label, style, shape, color and fillcolor, respectively,
Daniel@0 829 using attribute default values where necessary. If the node does
Daniel@0 830 not have a style attribute, "solid" is used.
Daniel@0 831 edge
Daniel@0 832 The tail and head values give the names of the head and tail
Daniel@0 833 nodes. n is the number of control points defining the B-spline
Daniel@0 834 forming the edge. This is followed by 2*n numbers giving the x and
Daniel@0 835 y coordinates of the control points in order from tail to head. If
Daniel@0 836 the edge has a label, this comes next followed by the x and y
Daniel@0 837 coordinates of the label's position. The edge description is
Daniel@0 838 completed by the edge's style and color. As with nodes, if a style
Daniel@0 839 is not defined, "solid" is used.
Daniel@0 840 The output consists of one graph line, a sequence of node lines, one
Daniel@0 841 per node, a sequence of edge lines, one per edge, and a final stop
Daniel@0 842 line. All units are in inches, represented by a floating point number.
Daniel@0 843 png
Daniel@0 844 Produces output in the PNG (Portable Network Graphics) format. PNG
Daniel@0 845 relies on having libz and the PNG library.
Daniel@0 846 ps
Daniel@0 847 Produces PostScript output.
Daniel@0 848 ps2
Daniel@0 849 Produces PostScript output with PDF notations. It is assumed the output
Daniel@0 850 will be directly converted into PDF format. The notations include PDF
Daniel@0 851 bounding box information, so that the resulting PDF file can be
Daniel@0 852 correctly used with pdf tools, such as pdflatex. In addition, if a node
Daniel@0 853 has a URL attribute, this gets translated into PDF code such that the
Daniel@0 854 node, when viewed in a PDF-viewer, e.g., acroread, is a link to the
Daniel@0 855 given URL. If a URL is attached to the graph, this serves as a base,
Daniel@0 856 such that relative URLs on nodes are derived from it.
Daniel@0 857 svg ,
Daniel@0 858 svgz
Daniel@0 859 Produce SVG output, the latter in compressed format. SVG relies on
Daniel@0 860 having libz.
Daniel@0 861 vrml
Daniel@0 862 Outputs graphs in the VRML format. VRML relies on having the PNG
Daniel@0 863 library.
Daniel@0 864 vtx
Daniel@0 865 Generates graph diagrams in the format for Confluents's Visual Thought.
Daniel@0 866 wbmp
Daniel@0 867 Produces output in the Wireless BitMap (WBMP) format, optimized for
Daniel@0 868 mobile computing.
Daniel@0 869
Daniel@0 870 ------------------------------------------------------------------------