@ts-graphviz/common
Version:
Graphviz Types and Utilities
1,101 lines (1,086 loc) • 216 kB
TypeScript
/**
* @hidden
*/
export declare type $keywords<T extends string> = {
[key in T]: key;
};
/**
* @hidden
*/
export declare interface $keywordsValidation extends $keywords<`${string} ${string}` | `${string}\n${string}` | `${string}\t${string}`> {
}
/**
* A double with an optional prefix `'+'`.
*
* @see {@link https://graphviz.gitlab.io/docs/attr-types/addDouble/ addDouble}
* @group Attribute Types
*/
export declare type AddDouble = `+${Double}`;
/**
* A point with an optional prefix `'+'`.
*
* @see {@link https://graphviz.gitlab.io/docs/attr-types/addPoint/ addPoint}
* @group Attribute Types
*/
export declare type AddPoint = `+${Point}`;
/**
* The examples above show a set of commonly used arrow shapes.
*
* There is a grammar of arrow shapes which can be used to describe a collection of 3,111,696 arrow
* combinations of the 42 variations of the primitive set of 11 arrows.
*
* @see {@link https://graphviz.org/docs/attr-types/arrowType/ arrowType}
* @group Attribute Types
*/
export declare type ArrowType = ArrowType.aname | `${ArrowType.aname}${ArrowType.aname}`;
/** @hidden */
export declare namespace ArrowType {
export type shape = keyof $shape;
export interface $shape extends $keywords<'box' | 'crow' | 'curve' | 'icurve' | 'diamond' | 'dot' | 'inv' | 'none' | 'normal' | 'tee' | 'vee'> {
}
export type side = 'l' | 'r';
export type modifiers = side | 'o' | `o${side}`;
export type aname = shape | `${modifiers}${shape}`;
}
/**
* ASTType is an enumeration of the different types of nodes that can be found in an AST(Abstract Syntax Tree ).
* @group Models
*/
export declare type ASTType = 'Literal' | 'Dot' | 'Graph' | 'Attribute' | 'Comment' | 'AttributeList' | 'NodeRef' | 'NodeRefGroup' | 'Edge' | 'Node' | 'Subgraph';
/**
* This type represents an Attribute, which is a key-value mapping of an {@link AttributeKey} to a value.
*
* @param T The {@link AttributeKey} to be mapped to a value.
* @group Attribute
*/
export declare type Attribute<T extends AttributeKey> = Attribute.types[T];
export declare namespace Attribute {
export type keys = Omit<$keys, keyof $exclude | symbol | number>;
export type types = Omit<$types, keyof $exclude | symbol | number>;
/** @hidden */
export interface $keys extends $keywords<AttributeKey> {
}
export interface $exclude extends $keywordsValidation {
}
/**
* @group Attribute
*/
export interface $keys {
/**
* Factor damping force motions.
* On each iteration, a nodes movement is limited to this factor of its potential motion.
* By being less than 1.0, the system tends to ``cool'', thereby preventing cycling.
*
* @see {@link https://graphviz.org/docs/attrs/Damping/ Node, Edge and Graph Attributes#Damping} * | Key | Value |
* | --- | --- |
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 0.99 |
* | minimum | 0 |
* | notes | neato only |
* | used by | G |
*
* @category Attribute
*/
Damping: 'Damping';
/**
* Spring constant used in virtual physical model.
* It roughly corresponds to an ideal edge length (in inches), in that increasing K tends to increase the distance between nodes.
* Note that the edge attribute {@link len} can be used to override this value for adjacent nodes.
*
* @see {@link https://graphviz.org/docs/attrs/K/ Node, Edge and Graph Attributes#K} * | Key | Value |
* | --- | --- |
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 0.3 |
* | minimum | 0 |
* | used by | GC |
* | notes | sfdp, fdp only |
*
* @category Attribute
*/
K: 'K';
/**
* Hyperlinks incorporated into device-dependent output.
* At present, used in ps2, cmap, i*map and svg formats.
* For all these formats, URLs can be attached to nodes, edges and clusters.
* URL attributes can also be attached to the root graph in ps2, cmap and i*map formats.
* This serves as the base URL for relative URLs in the former, and as the default image map file in the latter.
*
* For svg, cmapx and imap output, the active area for a node is its visible image.
* For example, an unfilled node with no drawn boundary will only be active on its label.
* For other output, the active area is its bounding box.
* The active area for a cluster is its bounding box.
* For edges, the active areas are small circles where the edge contacts its head and tail nodes.
* In addition, for svg, cmapx and imap, the active area includes a thin polygon approximating the edge.
* The circles may overlap the related node, and the edge URL dominates.
* If the edge has a label, this will also be active. Finally, if the edge has a head or tail label, this will also be active.
*
* Note that, for edges, the attributes {@link headURL}, {@link tailURL}, {@link labelURL} and {@link edgeURL} allow control of various parts of an edge.
* Also note that, if active areas of two edges overlap, it is unspecified which area dominates.
*
* @see {@link https://graphviz.org/docs/attrs/URL/ Node, Edge and Graph Attributes#URL} * | Key | Value |
* | --- | --- |
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | <none> |
* | used by | ENGC |
* | notes | svg, postscript, map only |
*
* @category Attribute
*/
URL: 'URL';
/**
* A string in the {@link https://graphviz.org/_pages/doc/info/output.html#d:xdot xdot format} specifying an arbitrary background.
* During rendering, the canvas is first filled as described in the {@link bgcolor} attribute.
* Then, if _background is defined, the graphics operations described in the string are performed on the canvas.
*
* @see {@link https://graphviz.org/docs/attrs/_background/ Node, Edge and Graph Attributes#_background} * | Key | Value |
* | --- | --- |
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | <none> |
* | used by | G |
* | notes | xdot only |
*
* @category Attribute
*/
_background: '_background';
/**
* Indicates the preferred area for a node or empty cluster when laid out by patchwork.
*
* @see {@link https://graphviz.org/docs/attrs/area/ Node, Edge and Graph Attributes#area} * | Key | Value |
* | --- | --- |
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 1 |
* | minimum | >0 |
* | used by | NC |
* | notes | patchwork only |
*
* @category Attribute
*/
area: 'area';
/**
* Style of arrowhead on the head node of an edge.
* This will only appear if the {@link dir} attribute is "forward" or "both".
*
* See the {@link https://graphviz.org/doc/info/attrs.html#undir_note limitation}.
*
* @see {@link https://graphviz.org/docs/attrs/arrowhead/ Node, Edge and Graph Attributes#arrowhead} * | Key | Value |
* | --- | --- |
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/arrowType/ arrowType} |
* | default | normal |
* | used by | E |
*
* @category Attribute
*/
arrowhead: 'arrowhead';
/**
* Multiplicative scale factor for arrowheads.
*
* @see {@link https://graphviz.org/docs/attrs/arrowsize/ Node, Edge and Graph Attributes#arrowsize} * | Key | Value |
* | --- | --- |
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 1 |
* | minimum | 0 |
* | used by | E |
*
* @category Attribute
*/
arrowsize: 'arrowsize';
/**
* Style of arrowhead on the tail node of an edge.
* This will only appear if the {@link dir} attribute is "back" or "both".
*
* See the {@link https://graphviz.org/doc/info/attrs.html#undir_note limitation}.
*
* @see {@link https://graphviz.org/docs/attrs/arrowtail/ Node, Edge and Graph Attributes#arrowtail}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/arrowType/ arrowType} |
* | default | normal |
* | used by | E |
*
* @category Attribute
*/
arrowtail: 'arrowtail';
/**
* Bounding box of drawing in points.
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/rect/ rect} |
* | used by | G |
* | notes | write only |
*
* @category Attribute
*/
bb: 'bb';
/**
* When attached to the root graph, this color is used as the background for entire canvas.
* When a cluster attribute, it is used as the initial background for the cluster.
* If a cluster has a filled {@link style}, the cluster's {@link fillcolor} will overlay the background color.
*
* @see {@link https://graphviz.org/docs/attrs/bgcolor/ Node, Edge and Graph Attributes#bgcolor}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/color/ color}/{@link https://graphviz.org/docs/attr-types/color/List colorList} |
* | default | <none> |
* | used by | G |
*
* @category Attribute
*/
bgcolor: 'bgcolor';
/**
* If true, the drawing is centered in the output canvas.
*
* @see {@link https://graphviz.org/docs/attrs/center/ Node, Edge and Graph Attributes#center}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | FALSE |
* | used by | G |
*
* @category Attribute
*/
center: 'center';
/**
* Specifies the character encoding used when interpreting string input as a text label.
* The default value is "UTF-8". The other legal value is "iso-8859-1" or, equivalently, "Latin1".
* The charset attribute is case-insensitive.
* Note that if the character encoding used in the input does not match the charset value, the resulting output may be very strange.
*
* @see {@link https://graphviz.org/docs/attrs/charset/ Node, Edge and Graph Attributes#charset}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | "UTF-8" |
* | used by | G |
*
* @category Attribute
*/
charset: 'charset';
/**
* Classnames to attach to the node, edge, graph, or cluster's SVG element.
* Combine with stylesheet for styling SVG output using CSS classnames.
*
* @see {@link https://graphviz.org/docs/attrs/class/ class}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | "" |
* | used by | ENCG |
*
* @category Attribute
*/
class: 'class';
/**
* Mode used for handling clusters.
* If clusterrank is "local", a subgraph whose name begins with "cluster" is given special treatment.
* The subgraph is laid out separately, and then integrated as a unit into its parent graph, with a bounding rectangle drawn about it.
* If the cluster has a label parameter, this label is displayed within the rectangle.
* Note also that there can be clusters within clusters.
* At present, the modes "global" and "none" appear to be identical, both turning off the special cluster processing.
*
* @see {@link https://graphviz.org/docs/attrs/clusterrank/ Node, Edge and Graph Attributes#clusterrank}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/clusterMode/ clusterMode} |
* | default | local |
* | used by | G |
* | notes | dot only |
*
* @category Attribute
*/
clusterrank: 'clusterrank';
/**
* Basic drawing color for graphics, not text.
* For the latter, use the fontcolor attribute.
*
* For edges, the value can either be a single color or a colorList.
* In the latter case, if colorList has no fractions, the edge is drawn using parallel splines or lines, one for each color in the list, in the order given.
* The head arrow, if any, is drawn using the first color in the list, and the tail arrow, if any, the second color.
* This supports the common case of drawing opposing edges, but using parallel splines instead of separately routed multiedges.
* If any fraction is used, the colors are drawn in series, with each color being given roughly its specified fraction of the edge.
* For example, the graph
*
* ```dot
* digraph G {
* a -> b [dir=both color="red:blue"]
* c -> d [dir=none color="green:red;0.25:blue"]
* }
* ```
*
* yields
*
* 
*
* @see {@link https://graphviz.org/docs/attrs/color/ Node, Edge and Graph Attributes#color}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/color/ color}/{@link https://graphviz.org/docs/attr-types/color/List colorList} |
* | default | black |
* | used by | ENC |
*
* @category Attribute
*/
color: 'color';
/**
* This attribute specifies a color scheme namespace.
* If defined, it specifies the context for interpreting color names.
* In particular, if a color value has form "xxx" or "//xxx", then the color xxx will be evaluated according to the current color scheme.
* If no color scheme is set, the standard X11 naming is used.
* For example, if colorscheme=bugn9, then color=7 is interpreted as "/bugn9/7".
*
* @see {@link https://graphviz.org/docs/attrs/colorscheme/ Node, Edge and Graph Attributes#colorscheme}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | "" |
* | used by | ENCG |
*
* @category Attribute
*/
colorscheme: 'colorscheme';
/**
* Comments are inserted into output.
* Device-dependent
*
* @see {@link https://graphviz.org/docs/attrs/comment/ Node, Edge and Graph Attributes#comment}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | "" |
* | used by | ENCG |
*
* @category Attribute
*/
comment: 'comment';
/**
* If true, allow edges between clusters. (See {@link lhead} and {@link ltail} below.)
*
* @see {@link https://graphviz.org/docs/attrs/compound/ Node, Edge and Graph Attributes#compound}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | FALSE |
* | used by | G |
* | notes | dot only |
*
* @category Attribute
*/
compound: 'compound';
/**
* If true, use edge concentrators.
* This merges multiedges into a single edge and causes partially parallel edges to share part of their paths.
* The latter feature is not yet available outside of dot.
*
* @see {@link https://graphviz.org/docs/attrs/concentrate/ Node, Edge and Graph Attributes#concentrate}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | FALSE |
* | used by | G |
*
* @category Attribute
*/
concentrate: 'concentrate';
/**
* If false, the edge is not used in ranking the nodes.
* For example, in the graph
*
* ```graphviz
* digraph G {
* a -> c;
* a -> b;
* b -> c [constraint=false];
* }
* ```
*
* the edge `b -> c` does not add a constraint during rank assignment, so the only constraints are that a be above b and c, yielding the graph:
*
* 
*
* @see {@link https://graphviz.org/docs/attrs/constraint/ Node, Edge and Graph Attributes#constraint}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | TRUE |
* | used by | E |
* | notes | dot only |
*
* @category Attribute
*/
constraint: 'constraint';
/**
* If true, attach edge label to edge by a 2-segment polyline, underlining the label, then going to the closest point of spline.
*
* @see {@link https://graphviz.org/docs/attrs/decorate/ Node, Edge and Graph Attributes#decorate}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | FALSE |
* | used by | E |
*
* @category Attribute
*/
decorate: 'decorate';
/**
* This specifies the distance between nodes in separate connected components.
* If set too small, connected components may overlap. Only applicable if {@link pack}=false.
*
* @see {@link https://graphviz.org/docs/attrs/defaultdist/ Node, Edge and Graph Attributes#defaultdist}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 1+(avg. len)*sqrt(|V|) |
* | minimum | epsilon |
* | notes | neato only |
* | used by | G |
*
* @category Attribute
*/
defaultdist: 'defaultdist';
/**
* Set the number of dimensions used for the layout.
* The maximum value allowed is 10.
*
* @see {@link https://graphviz.org/docs/attrs/dim/ Node, Edge and Graph Attributes#dim}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/int/ int} |
* | default | 2 |
* | minimum | 2 |
* | notes | sfdp, fdp, neato only |
* | used by | G |
*
* @category Attribute
*/
dim: 'dim';
/**
* Set the number of dimensions used for rendering.
* The maximum value allowed is 10.
* If both dimen and dim are set, the latter specifies the dimension used for layout, and the former for rendering.
* If only dimen is set, this is used for both layout and rendering dimensions.
*
* Note that, at present, all aspects of rendering are 2D.
* This includes the shape and size of nodes, overlap removal, and edge routing.
* Thus, for dimen > 2, the only valid information is the pos attribute of the nodes.
* All other coordinates will be 2D and, at best, will reflect a projection of a higher-dimensional point onto the plane.
*
* @see {@link https://graphviz.org/docs/attrs/dimen/ Node, Edge and Graph Attributes#dimen}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/int/ int} |
* | default | 2 |
* | minimum | 2 |
* | used by | G |
* | notes | sfdp, fdp, neato only |
*
* @category Attribute
*/
dimen: 'dimen';
/**
* Set edge type for drawing arrowheads.
* This indicates which ends of the edge should be decorated with an arrowhead.
* The actual style of the arrowhead can be specified using the {@link arrowhead} and {@link arrowtail} attributes.
* See {@link https://graphviz.org/doc/info/attrs.html#undir_note limitation}.
*
* @see {@link https://graphviz.org/docs/attrs/dir/ Node, Edge and Graph Attributes#dir}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/dirType/ dirType} |
* | default | forward(directed) none(undirected) |
* | used by | E |
*
* @category Attribute
*/
dir: 'dir';
/**
* Only valid when {@link mode}="ipsep".
* If true, constraints are generated for each edge in the largest (heuristic) directed acyclic subgraph such that the edge must point downwards.
* If "hier", generates level constraints similar to those used with {@link mode}="hier".
* The main difference is that, in the latter case, only these constraints are involved, so a faster solver can be used.
*
* @see {@link https://graphviz.org/docs/attrs/diredgeconstraints/ Node, Edge and Graph Attributes#diredgeconstraints}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string}/{@link https://graphviz.org/docs/attr-types/bool bool} |
* | default | FALSE |
* | used by | G |
* | notes | neato only |
*
* @category Attribute
*/
diredgeconstraints: 'diredgeconstraints';
/**
* Distortion factor for {@link shape}=polygon.
* Positive values cause top part to be larger than bottom; negative values do the opposite.
*
* @see {@link https://graphviz.org/docs/attrs/distortion/ Node, Edge and Graph Attributes#distortion}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | -100 |
* | used by | N |
*
* @category Attribute
*/
distortion: 'distortion';
/**
* This specifies the expected number of pixels per inch on a display device.
* For bitmap output, this guarantees that text rendering will be done more accurately, both in size and in placement.
* For SVG output, it is used to guarantee that the dimensions in the output correspond to the correct number of points or inches.
*
* @see {@link https://graphviz.org/docs/attrs/dpi/ Node, Edge and Graph Attributes#dpi}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 96.0 0.0 |
* | used by | G |
* | notes | svg, bitmap output only |
*
* @category Attribute
*/
dpi: 'dpi';
/**
* If **edgeURL** is defined, this is the link used for the non-label parts of an edge.
* This value overrides any {@link URL} defined for the edge.
* Also, this value is used near the head or tail node unless overridden by a {@link headURL} or {@link tailURL} value, respectively.
* See {@link https://graphviz.org/doc/info/attrs.html#undir_note limitation}.
*
* @see {@link https://graphviz.org/docs/attrs/edgeURL/ Node, Edge and Graph Attributes#edgeURL}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | E |
* | notes | svg, map only |
*
* @category Attribute
*/
edgeURL: 'edgeURL';
/**
* Synonym for {@link edgeURL}.
*
* @see {@link https://graphviz.org/docs/attrs/edgehref/ Node, Edge and Graph Attributes#edgehref}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | E |
* | notes | svg, map only |
*
* @category Attribute
*/
edgehref: 'edgehref';
/**
* If the edge has a {@link URL} or {@link edgeURL} attribute, this attribute determines which window of the browser is used for the URL attached to the non-label part of the edge.
* Setting it to "_graphviz" will open a new window if it doesn't already exist, or reuse it if it does.
* If undefined, the value of the {@link target} is used.
*
* @see {@link https://graphviz.org/docs/attrs/edgetarget/ Node, Edge and Graph Attributes#edgetarget}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | <none> |
* | used by | E |
* | notes | svg, map only |
*
* @category Attribute
*/
edgetarget: 'edgetarget';
/**
* Tooltip annotation attached to the non-label part of an edge.
* This is used only if the edge has a {@link URL} or {@link edgeURL} attribute.
*
* @see {@link https://graphviz.org/docs/attrs/edgetooltip/ Node, Edge and Graph Attributes#edgetooltip}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | E |
* | notes | svg, cmap only |
*
* @category Attribute
*/
edgetooltip: 'edgetooltip';
/**
* Terminating condition. If the length squared of all energy gradients are < **epsilon**, the algorithm stops.
*
* @see {@link https://graphviz.org/docs/attrs/epsilon/ Node, Edge and Graph Attributes#epsilon}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | .0001 |
* | minimum | 0 |
* | used by | G |
* | notes | neato only |
*
* @category Attribute
*/
epsilon: 'epsilon';
/**
* Margin used around polygons for purposes of spline edge routing.
* The interpretation is the same as given for {@link sep}.
* This should normally be strictly less than {@link sep}.
*
* @see {@link https://graphviz.org/docs/attrs/esep/ Node, Edge and Graph Attributes#esep}
*
* | Key | Value |
* | --- | --- |\
* | type | {@link https://graphviz.org/docs/attr-types/addDouble/ addDouble}/{@link https://graphviz.org/_pages/doc/info/attrs.html#k:addPoint addPoint} |
* | default | 3 |
* | used by | G |
* | notes | not dot |
*
* @category Attribute
*/
esep: 'esep';
/**
* Color used to fill the background of a node or cluster assuming {@link style}=filled, or a filled arrowhead.
* If fillcolor is not defined, {@link color} is used. (For clusters, if color is not defined, {@link bgcolor} is used.)
* If this is not defined, the default is used, except for {@link shape}=point or when the output format is MIF, which use black by default.
*
* If the value is a {@link colorList}, a gradient fill is used.
* By default, this is a linear fill; setting style=radial will cause a radial fill.
* At present, only two colors are used. If the second color (after a colon) is missing, the default color is used for it.
* See also the {@link gradientangle} attribute for setting the gradient angle.
*
* Note that a cluster inherits the root graph's attributes if defined.
* Thus, if the root graph has defined a **fillcolor**, this will override a **color** or **bgcolor** attribute set for the cluster.
*
* @see {@link https://graphviz.org/docs/attrs/fillcolor/ Node, Edge and Graph Attributes#fillcolor}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/color/ color}/{@link https://graphviz.org/docs/attr-types/color/List colorList} |
* | default | lightgrey(nodes) black(clusters) |
* | used by | NEC |
*
* @category Attribute
*/
fillcolor: 'fillcolor';
/**
* If `false`, the size of a node is determined by smallest width and height needed to contain its label and image,
* if any, with a {@link margin} specified by the margin attribute.
* The width and height must also be at least as large as the sizes specified by the {@link width} and {@link height} attributes,
* which specify the minimum values for these parameters.
*
* If `true`, the node size is specified by the values of the {@link width} and {@link height} attributes only and is not expanded to contain the text label.
* There will be a warning if the label (with margin) cannot fit within these limits.
*
* If the {@link fixedsize} attribute is set to shape, the {@link width} and {@link height} attributes also determine the size of the node shape,
* but the label can be much larger. Both the label and shape sizes are used when avoiding node overlap,
* but all edges to the node ignore the label and only contact the node shape. No warning is given if the label is too large.
*
* @see {@link https://graphviz.org/docs/attrs/fixedsize/ Node, Edge and Graph Attributes#fixedsize}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | FALSE |
* | used by | N |
*
* @category Attribute
*/
fixedsize: 'fixedsize';
/**
* Color used for text.
*
* @see {@link https://graphviz.org/docs/attrs/fontcolor/ Node, Edge and Graph Attributes#fontcolor}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/color/ color} |
* | default | black |
* | used by | ENGC |
*
* @category Attribute
*/
fontcolor: 'fontcolor';
/**
* Font used for text.
* This very much depends on the output format and, for non-bitmap output such as PostScript or SVG,
* the availability of the font when the graph is displayed or printed.
* As such, it is best to rely on font faces that are generally available,
* such as Times-Roman, Helvetica or Courier.
*
* How font names are resolved also depends on the underlying library that handles font name resolution.
* If Graphviz was built using the fontconfig library, the latter library will be used to search for the font.
* See the commands **fc-list**, **fc-match** and the other fontconfig commands for how names are resolved and which fonts are available.
* Other systems may provide their own font package, such as Quartz for OS X.
*
* Note that various font attributes, such as weight and slant, can be built into the font name.
* Unfortunately, the syntax varies depending on which font system is dominant. Thus, using fontname="times bold italic" will produce a bold, slanted Times font using Pango, the usual main font library.
* Alternatively, fontname="times:italic" will produce a slanted Times font from fontconfig, while fontname="times-bold" will resolve to a bold Times using Quartz.
* You will need to ascertain which package is used by your Graphviz system and refer to the relevant documentation.
*
* If Graphviz is not built with a high-level font library, fontname will be considered the name of a Type 1 or True Type font file.
* If you specify fontname=schlbk, the tool will look for a file named schlbk.ttf or schlbk.pfa or schlbk.pfb in one of the directories specified by the {@link fontpath} attribute.
* The lookup does support various aliases for the common fonts.
*
* @see {@link https://graphviz.org/docs/attrs/fontname/ Node, Edge and Graph Attributes#fontname}
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | "Times-Roman" |
* | used by | ENGC |
*
* @category Attribute
*/
fontname: 'fontname';
/**
* Allows user control of how basic fontnames are represented in SVG output.
* If fontnames is undefined or "svg", the output will try to use known SVG fontnames.
* For example, the default font "Times-Roman" will be mapped to the basic SVG font "serif".
* This can be overridden by setting fontnames to "ps" or "gd". In the former case, known PostScript font names such as "Times-Roman" will be used in the output.
* In the latter case, the fontconfig font conventions are used. Thus, "Times-Roman" would be treated as "Nimbus Roman No9 L".
* These last two options are useful with SVG viewers that support these richer fontname spaces.
*
* @see {@link https://graphviz.org/docs/attrs/fontnames/ Node, Edge and Graph Attributes#fontnames}
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | "" |
* | used by | G |
* | notes | svg only |
*
* @category Attribute
*/
fontnames: 'fontnames';
/**
* Directory list used by libgd to search for bitmap fonts if Graphviz was not built with the fontconfig library.
* If **fontpath** is not set, the environment variable DOTFONTPATH is checked.
* If that is not set, GDFONTPATH is checked.
* If not set, libgd uses its compiled-in font path.
* Note that fontpath is an attribute of the root graph.
*
* @see {@link https://graphviz.org/docs/attrs/fontpath/ Node, Edge and Graph Attributes#fontpath}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | system-dependent |
* | used by | G |
*
* @category Attribute
*/
fontpath: 'fontpath';
/**
* Font size, {@link https://graphviz.org/doc/info/attrs.html in points}, used for text.
*
* @see {@link https://graphviz.org/docs/attrs/fontsize/ Node, Edge and Graph Attributes#fontsize}
*
* | Key | Value |
* | --- | --- |\
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 14 |
* | minimum | 1 |
* | used by | ENGC |
*
* @category Attribute
*/
fontsize: 'fontsize';
/**
* If true, all {@link xlabel} attributes are placed,
* even if there is some overlap with nodes or other labels.
*
* @see {@link https://graphviz.org/docs/attrs/forcelabels/ Node, Edge and Graph Attributes#forcelabels}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | TRUE |
* | used by | G |
*
* @category Attribute
*/
forcelabels: 'forcelabels';
/**
* If a gradient fill is being used, this determines the angle of the fill.
* For linear fills, the colors transform along a line specified by the angle and the center of the object.
* For radial fills, a value of zero causes the colors to transform radially from the center; for non-zero values,
* the colors transform from a point near the object's periphery as specified by the value.
*
* If unset, the default angle is 0.
*
* @see {@link https://graphviz.org/docs/attrs/gradientangle/ Node, Edge and Graph Attributes#gradientangle}
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/int/ int} |
* | default | "" |
* | used by | NCG |
*
* @category Attribute
*/
gradientangle: 'gradientangle';
/**
* If the end points of an edge belong to the same group, i.e.,
* have the same group attribute, parameters are set to avoid crossings and keep the edges straight.
*
* @see {@link https://graphviz.org/docs/attrs/group/ Node, Edge and Graph Attributes#group}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/string/ string} |
* | default | "" |
* | used by | N |
* | notes | dot only |
*
* @category Attribute
*/
group: 'group';
/**
* If **headURL** is defined, it is output as part of the head label of the edge.
* Also, this value is used near the head node, overriding any {@link URL} value.
* See {@link https://graphviz.org/doc/info/attrs.html#undir_note limitation}.
*
* @see {@link https://graphviz.org/docs/attrs/headURL/ Node, Edge and Graph Attributes#headURL}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | E |
* | notes | svg, map only |
*
* @category Attribute
*/
headURL: 'headURL';
/**
* Position of an edge's head label, {@link https://graphviz.org/doc/info/attrs.html in points}.
* The position indicates the center of the label.
*
* @see {@link https://graphviz.org/docs/attrs/head_lp/ Node, Edge and Graph Attributes#head_lp}\
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/point/ point} |
* | used by | E |
* | notes | write only |
*
* @category Attribute
*/
head_lp: 'head_lp';
/**
* If true, the head of an edge is clipped to the boundary of the head node; otherwise,
* the end of the edge goes to the center of the node, or the center of a port, if applicable.
*
* @see {@link https://graphviz.org/docs/attrs/headclip/ Node, Edge and Graph Attributes#headclip}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/bool/ bool} |
* | default | TRUE |
* | used by | E |
*
* @category Attribute
*/
headclip: 'headclip';
/**
* Synonym for {@link headURL}.
*
* @see {@link https://graphviz.org/docs/attrs/headhref/ Node, Edge and Graph Attributes#headhref}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | E |
* | notes | svg, map only |
*
* @category Attribute
*/
headhref: 'headhref';
/**
* Text label to be placed near head of edge.
* See {@link https://graphviz.org/doc/info/attrs.html#undir_note limitation}.
*
* @see {@link https://graphviz.org/docs/attrs/headlabel/ Node, Edge and Graph Attributes#headlabel}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/lblString/ lblString} |
* | default | center |
* | used by | E |
*
* @category Attribute
*/
headlabel: 'headlabel';
/**
* Indicates where on the head node to attach the head of the edge.
* In the default case, the edge is aimed towards the center of the node, and then clipped at the node boundary.
* See {@link https://graphviz.org/doc/info/attrs.html#undir_note limitation}.
*
* @see {@link https://graphviz.org/docs/attrs/headport/ Node, Edge and Graph Attributes#headport}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/portPos/ portPos} |
* | default | <none> |
* | used by | E |
* | notes | svg, map only |
*
* @category Attribute
*/
headport: 'headport';
/**
* If the edge has a {@link headURL}, this attribute determines which window of the browser is used for the URL.
* Setting it to "_graphviz" will open a new window if it doesn't already exist, or reuse it if it does.
* If undefined, the value of the {@link target} is used.
*
* @see {@link https://graphviz.org/docs/attrs/headtarget/ Node, Edge and Graph Attributes#headtarget}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | E |
* | notes | svg, cmap only |
*
* @category Attribute
*/
headtarget: 'headtarget';
/**
* Tooltip annotation attached to the head of an edge.
* This is used only if the edge has a {@link headURL} attribute.
*
* @see {@link https://graphviz.org/docs/attrs/headtooltip/ Node, Edge and Graph Attributes#headtooltip}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | 0.5 |
* | minimum | 0.02 |
* | used by | N |
*
* @category Attribute
*/
headtooltip: 'headtooltip';
/**
* Height of node, in inches.
* This is taken as the initial, minimum height of the node.
* If {@link fixedsize} is true, this will be the final height of the node.
* Otherwise, if the node label requires more height to fit, the node's **height** will be increased to contain the label.
* Note also that, if the output format is dot, the value given to height will be the final value.
*
* If the node shape is regular, the width and height are made identical.
* In this case, if either the width or the height is set explicitly, that value is used.
* In this case, if both the width or the height are set explicitly, the maximum of the two values is used.
* If neither is set explicitly, the minimum of the two default values is used.
*
* @see {@link https://graphviz.org/docs/attrs/height/ Node, Edge and Graph Attributes#height}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/double/ double} |
* | default | 0.5 |
* | minimum | 0.02 |
* | used by | N |
* | notes | svg, postscript, map only |
*
* @category Attribute
*/
height: 'height';
/**
* Synonym for {@link URL}.
*
* @see {@link https://graphviz.org/docs/attrs/href/ Node, Edge and Graph Attributes#href}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | GCNE |
* | notes | svg, postscript, map only |
*
* @category Attribute
*/
href: 'href';
/**
* Allows the graph author to provide an id for graph objects which is to be included in the output.
* Normal "\N", "\E", "\G" substitutions are applied.
* If provided, it is the responsibility of the provider to keep its values sufficiently unique for its intended downstream use.
* Note, in particular, that "\E" does not provide a unique id for multi-edges.
* If no id attribute is provided, then a unique internal id is used.
* However, this value is unpredictable by the graph writer.
* An externally provided id is not used internally.
*
* If the graph provides an id attribute, this will be used as a prefix for internally generated attributes.
* By making these distinct, the user can include multiple image maps in the same document.
*
* @see {@link https://graphviz.org/docs/attrs/id/ Node, Edge and Graph Attributes#id}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/docs/attr-types/escString/ escString} |
* | default | "" |
* | used by | GCNE |
* | notes | svg, postscript, map only |
*
* @category Attribute
*/
id: 'id';
/**
* Gives the name of a file containing an image to be displayed inside a node.
* The image file must be in one of the recognized {@link https://graphviz.org/docs/outputs/ formats},
* typically JPEG, PNG, GIF, BMP, SVG or Postscript, and be able to be converted into the desired output format.
*
* The file must contain the image size information.
* This is usually trivially true for the bitmap formats.
* For PostScript, the file must contain a line starting with %%BoundingBox: followed by four integers specifying the lower left x and y coordinates and the upper right x and y coordinates of the bounding box for the image, the coordinates being in points.
* An SVG image file must contain width and height attributes, typically as part of the svg element.
* The values for these should have the form of a floating point number, followed by optional units, e.g.,
* width="76pt". Recognized units are in, px, pc, pt, cm and mm for inches, pixels, picas, points, centimeters and millimeters, respectively.
* The default unit is points.
*
* Unlike with the {@link shapefile} attribute, the image is treated as node content rather than the entire node. In particular, an image can be contained in a node of any shape, not just a rectangle.
*
* @see {@link https://graphviz.org/docs/attrs/image/ Node, Edge and Graph Attributes#image}
*
* | Key | Value |
* | --- | --- |
* | type | {@link https://graphviz.org/d