Files
book/dot/trpl04-05.dot
Chris Krycho 81c42b5c54 Simplify dot file for Figure 4-5
Get rid of things which are not contributing meaningfully to the
resulting SVG output.
2024-10-01 09:41:37 -06:00

38 lines
1.2 KiB
Plaintext

digraph {
rankdir = LR;
overlap = false;
dpi = 300.0;
node [shape = "plaintext";];
s [label = <<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0">
<TR><TD COLSPAN="2" SIDES="B">s</TD></TR>
<TR><TD>name</TD><TD>value</TD></TR>
<TR><TD>ptr</TD><TD PORT="pointer"></TD></TR>
<TR><TD>len</TD><TD>4</TD></TR>
<TR><TD>capacity</TD><TD>4</TD></TR>
</TABLE>>;];
subgraph cluster_heap {
peripheries = 0;
rank = "same";
hello [label = <<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0" BGCOLOR="gray">
<TR><TD>index</TD><TD>value</TD></TR>
<TR><TD PORT="pointee">0</TD><TD>h</TD></TR>
<TR><TD>1</TD><TD>e</TD></TR>
<TR><TD>2</TD><TD>l</TD></TR>
<TR><TD>3</TD><TD>l</TD></TR>
<TR><TD>4</TD><TD>o</TD></TR>
</TABLE>>;];
ahoy [label = <<TABLE BORDER="0" CELLBORDER="1" CELLSPACING="0">
<TR><TD>index</TD><TD>value</TD></TR>
<TR><TD PORT="pointee">0</TD><TD>a</TD></TR>
<TR><TD>1</TD><TD>h</TD></TR>
<TR><TD>2</TD><TD>o</TD></TR>
<TR><TD>3</TD><TD>y</TD></TR>
</TABLE>>;];
}
s -> ahoy [tailport = "pointer:c"; headport = "pointee"; tailclip = false;];
}