Skip to content
Snippets Groups Projects
Commit 7537db67 authored by g0dil's avatar g0dil
Browse files

Add helper to wrap long (template) class labels in dot graphs

parent f5c40d39
No related branches found
No related tags found
No related merge requests found
......@@ -36,13 +36,16 @@ GENERATE_XML = YES
HAVE_DOT = YES
CLASS_GRAPH = YES
COLLABORATION_GRAPH = YES
TEMPLATE_RELATIONS = YES
COLLABORATION_GRAPH = NO
TEMPLATE_RELATIONS = NO
INCLUDE_GRAPH = YES
INCLUDED_BY_GRAPH = YES
GROUP_GRAPHS = NO
MAX_DOT_GRAPH_WIDTH = 800
MAX_DOT_GRAPH_HEIGHT = 1200
MAX_DOT_GRAPH_HEIGHT = 1600
MAX_DOT_GRAPH_DEPTH = 3
DOT_MULTI_TARGETS = YES
DOT_CLEANUP = NO
DOT_PATH = "$(TOPDIR)/doclib"
@INCLUDE = "$(TOPDIR)/Doxyfile.local"
#!/bin/sh
topdir="`dirname "$0"`"; topdir="`cd "$topdir/.."; pwd`"
"$topdir/doclib/dot-munge.pl" "$1"
exec dot "$@"
#!/usr/bin/perl -i -n
# Reduce font size
s/fontsize=10/fontsize=8/g;
# Wrap long labels (templates)
if (/label=\"([^"]*)\"/) { #"])){ # To make emacs happy ...
$pre=$`;
$post=$'; #' # To make emacs happy ...
$label=$1;
# Break at each komma
$label=~s/,/,\\r\\ \\ \\ \\ \\ \\ \\ \\ /g;
# If more than one '<' is in the label, break after each '<'
if (($label=~tr/</</)>1) {
$label=~s/</<\\r\\ \\ \\ \\ \\ \\ \\ \\ /g;
}
# If at least one break is in there ...
if ($label=~/\\r/) {
# Make last line flush right
$label.="\\r";
# and first line flush left
$label=~s/\\r/\\l/;
}
print "${pre}label=\"${label}\"${post}";
} else {
print;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment