This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# set -x | |
T=svg | |
usage() { # Function: Print a help message. | |
echo "Usage: $0 [ -G|N|E GraphvizOption ] [ -L layoutEngine ] [ -T outputFormat ] myFile.gv" 1>&2 | |
} | |
exit_abnormal() { # Function: Exit with error. | |
usage | |
exit 1 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/************************************************************************** | |
add a grid to a graph in .dot format | |
**************************************************************************/ | |
BEGIN{ | |
int i, Indx, bcnt, LR; | |
string Type, Val, Gcolor[], Gstyle[], Gsize[], tmpstr; | |
string Hcolor, Vcolor, Hstyle, Vstyle, gridType, gridAlign; | |
float Hsize, Vsize, deltaX, deltaY, minX, minY, maxX, maxY; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/***************************************************** | |
Name: roundedOrtho.gvpr | |
As of Date: 2024-08-25 20:24:11 | |
Description: when possible, changes ortho edges to round the squared edges | |
Usage: dot -Gsplines=ortho myFile.gv | gvpr -cf roundedOrtho2.gvpr|neato -n2 -T... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/********************************************************************** | |
justify nodes that are on the same rank | |
- add a new "rankjustify" to any nodes you want "justified" | |
- legal values: t,b,l,r,min,max (for top, bottom, left, right, min, and max) | |
usage: | |
dot myFile.gv | gvpr -cf justifyRanks.gvpr | neato -n ... | |
**********************************************************************/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/************************************************************************** | |
add a grid to a graph in .dot format | |
**************************************************************************/ | |
BEGIN{ | |
int i, Indx, bcnt, LR; | |
string Type, Val, Gcolor[], Gstyle[], Gsize[], tmpstr; | |
string Hcolor, Vcolor, Hstyle, Vstyle, gridType, gridAlign; | |
float Hsize, Vsize, deltaX, deltaY, minX, minY, maxX, maxY; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/************************************************************************* | |
swimlanes | |
- for more info on swim lanes: https://en.wikipedia.org/wiki/Swim_lane | |
- new attributes, all at the parent cluster-level: | |
- swimlanePool=true/false/[0-9]+ - turns on swimlane algorithm | |
- if having nested swimlanes is desirable, true/false is | |
insufficient. Instead, use swimlane=someuniquename | |
- swimlaneequalSize=true/false all lanes given same width, or width determined "naturally" by dot |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/**************************************************************** | |
swapHeadTail.gvpr - swap tail & head of edge(s) | |
(only seems to have "real" effect when using dot) | |
replaces edges with tail & head swapped | |
and (unless using -a0 option) "fixes" all the attribures that are associated with head or tail | |
to swap ALL edges, either add | |
- edge [swap=1] to your myFile.gv, then |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/******************************************************************** | |
gvlint.gvpr - lint program for Graphviz input | |
USAGE: | |
gvpr -f gvlint.gvpr # just produces a "report" (assumes dot) | |
gvpr -cf gvlint.gvpr # report & reformatted input | |
gvpr -a neato -f gvlint.gvpr # report assuming neato attributes | |
gvpr -a S -f gvlint.gvpr myfile.gv # skip "pos not defined ..." | |
gvpr -a "neato A" -f gvlint.gvpr # report assuming neato attributes | |
# and show all attributes used |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BEGIN{ | |
int clusterCnt, cHtmlCnt; | |
graph_t aGraph; | |
string printBuf; | |
//////////////// help ///////////////////////////////////////////// | |
string help=" | |
gvstats.gvpr : | |
a GVPR program that provides information about Graphviz input files | |
- the file name | |
- the layout engine (if set) |
NewerOlder