From: Wolfgang Bangerth Date: Wed, 10 Jun 2020 22:09:34 +0000 (-0600) Subject: Improve tutorial graph layout. X-Git-Tag: v9.3.0-rc1~1451^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F10507%2Fhead;p=dealii.git Improve tutorial graph layout. Specifically, don't treat edges from one code-gallery to another code-gallery program as requiring special weight. Also show these edges in gray instead of the white we're currently using (i.e., not visible at all). --- diff --git a/doc/doxygen/scripts/steps.pl b/doc/doxygen/scripts/steps.pl index 97573ad04d..cae91383b9 100644 --- a/doc/doxygen/scripts/steps.pl +++ b/doc/doxygen/scripts/steps.pl @@ -202,11 +202,18 @@ foreach $step (@ARGV) # kind, use the same color as the nodes as this makes # reading the flow of the graph a bit easier. Furthermore, # set the edge weight to 5 (instead of the default of 1) - # to try and keep programs of the same kind together. The - # exception is the "basic" tutorial programs: these are - # going to be connected by edges of weight 100, ensuring - # that they are all essentially aligned vertically. - if ($kind_map{$source} eq $kind_map{$destination}) + # to try and keep programs of the same kind together. + # + # There are two exceptions: + # * The "basic" tutorial programs: these are + # going to be connected by edges of weight 100, ensuring + # that they are all essentially aligned vertically. + # * Code gallery programs: Here, we don't care much where + # they are placed, and so don't treat edges between these kinds + # of programs as special + if ($kind_map{$source} eq $kind_map{$destination} + && + ! ($kind_map{$source} eq "code-gallery")) { $edge_attributes = "color=\"$colors{$kind_map{$source}}\","; if ($kind_map{$source} eq "basic") @@ -220,9 +227,9 @@ foreach $step (@ARGV) } # If the destination is a code gallery program, used a dashed line - if ($destination =~ /code_gallery/) + if ($kind_map{$destination} eq "code-gallery") { - $edge_attributes .= "style=\"dashed\", arrowhead=\"empty\","; + $edge_attributes .= "style=\"dashed\", arrowhead=\"empty\", color=\"gray\","; } print " [$edge_attributes];\n"; }