/// @file /// @ingroup common_utils /************************************************************************* * Copyright (c) 2011 AT&T Intellectual Property * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * https://www.eclipse.org/legal/epl-v10.html * * Contributors: Details at https://graphviz.org *************************************************************************/ #pragma once #define LPAREN '(' #define RPAREN ')' #define LBRACE '{' #define RBRACE '}' /* node,edge types */ #ifdef NORMAL #undef NORMAL #endif #define NORMAL 0 /* an original input node */ #define VIRTUAL 1 /* virtual nodes in long edge chains */ #define SLACKNODE 2 /* encode edges in node position phase */ #define REVERSED 3 /* reverse of an original edge */ #define FLATORDER 4 /* for ordered edges */ #define CLUSTER_EDGE 5 /* for ranking clusters */ #define IGNORED 6 /* concentrated multi-edges */ /* collapsed node classifications */ #define NOCMD 0 /* default */ #define SAMERANK 1 /* place on same rank */ #define MINRANK 2 /* place on "least" rank */ #define SOURCERANK 3 /* strict version of MINRANK */ #define MAXRANK 4 /* place on "greatest" rank */ #define SINKRANK 5 /* strict version of MAXRANK */ #define LEAFSET 6 /* set of collapsed leaf nodes */ #define CLUSTER 7 /* set of clustered nodes */ /* type of cluster rank assignment */ #define LOCAL 100 #define GLOBAL 101 #define NOCLUST 102 /* default attributes */ #define DEFAULT_COLOR "black" #define DEFAULT_ACTIVEPENCOLOR "#808080" #define DEFAULT_ACTIVEFILLCOLOR "#fcfcfc" #define DEFAULT_ACTIVEFONTCOLOR "black" #define DEFAULT_SELECTEDPENCOLOR "#303030" #define DEFAULT_SELECTEDFILLCOLOR "#e8e8e8" #define DEFAULT_SELECTEDFONTCOLOR "black" #define DEFAULT_DELETEDPENCOLOR "#e0e0e0" #define DEFAULT_DELETEDFILLCOLOR "#f0f0f0" #define DEFAULT_DELETEDFONTCOLOR "darkgrey" #define DEFAULT_VISITEDPENCOLOR "#101010" #define DEFAULT_VISITEDFILLCOLOR "#f8f8f8" #define DEFAULT_VISITEDFONTCOLOR "black" #define DEFAULT_FONTSIZE 14.0 #define DEFAULT_LABEL_FONTSIZE 11.0 /* for head/taillabel */ #define MIN_FONTSIZE 1.0 #if defined(__ENVIRONMENT_IPHONE_OS_VERSION_MIN_REQUIRED__) || defined(__IPHONE_OS_VERSION_MIN_REQUIRED) #define DEFAULT_FONTNAME "TimesNewRomanPSMT" #else #define DEFAULT_FONTNAME "Times-Roman" #endif #define DEFAULT_FILL "lightgrey" #define LINESPACING 1.20 #define DEFAULT_NODEHEIGHT 0.5 #define MIN_NODEHEIGHT 0.02 #define DEFAULT_NODEWIDTH 0.75 #define MIN_NODEWIDTH 0.01 #define DEFAULT_NODESHAPE "ellipse" #define DEFAULT_NODEPENWIDTH 1.0 #define MIN_NODEPENWIDTH 0.0 #define NODENAME_ESC "\\N" #define DEFAULT_LAYERSEP ":\t " #define DEFAULT_LAYERLISTSEP "," #define DEFAULT_NODESEP 0.25 #define MIN_NODESEP 0.02 #define DEFAULT_RANKSEP 0.5 #define MIN_RANKSEP 0.02 /* default margin for paged formats such as PostScript - in points = 0.5in */ #define DEFAULT_PRINT_MARGIN 36 /* default margin for embedded formats such as PNG - in points */ #define DEFAULT_EMBED_MARGIN 0 /* default padding around graph - in points */ #define DEFAULT_GRAPH_PAD 4 #define SELF_EDGE_SIZE 18 #define MC_SCALE 256 /* for mincross */ #define PORT_LABEL_DISTANCE 10 #define PORT_LABEL_ANGLE -25 /* degrees; pos is CCW, neg is CW */ /* default polygon sample size for overlap removal and maps */ #define DFLT_SAMPLE 20 /* arrow types */ #define ARR_NONE 0 /* sides (e.g. of cluster margins) */ #define BOTTOM_IX 0 #define RIGHT_IX 1 #define TOP_IX 2 #define LEFT_IX 3 /* sides of boxes for SHAPE_path */ #define BOTTOM (1<