diff options
author | dimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7> | 2011-01-23 17:25:30 (GMT) |
---|---|---|
committer | dimitri <dimitri@afe2bf4a-e733-0410-8a33-86f594647bc7> | 2011-01-23 17:25:30 (GMT) |
commit | e3867f798e35c06c2208899f9c0bc264d8e6cb83 (patch) | |
tree | 56f084a80118debb8b5569e59a7435a20fc82b03 /src/dot.cpp | |
parent | 38de39f102c03a52de4c9bb4875125745abce622 (diff) | |
download | Doxygen-e3867f798e35c06c2208899f9c0bc264d8e6cb83.zip Doxygen-e3867f798e35c06c2208899f9c0bc264d8e6cb83.tar.gz Doxygen-e3867f798e35c06c2208899f9c0bc264d8e6cb83.tar.bz2 |
Release-1.7.3-20110123
Diffstat (limited to 'src/dot.cpp')
-rw-r--r-- | src/dot.cpp | 27 |
1 files changed, 14 insertions, 13 deletions
diff --git a/src/dot.cpp b/src/dot.cpp index 134f51a..63e595a 100644 --- a/src/dot.cpp +++ b/src/dot.cpp @@ -3,7 +3,7 @@ * * * - * Copyright (C) 1997-2010 by Dimitri van Heesch. + * Copyright (C) 1997-2011 by Dimitri van Heesch. * * Permission to use, copy, modify, and distribute this software and its * documentation under the terms of the GNU General Public License is hereby @@ -3526,10 +3526,10 @@ void writeDotGraphFromFile(const char *inFile,const char *outDir, * \param context the scope in which this graph is found (for resolving links) */ void writeDotImageMapFromFile(FTextStream &t, - const QCString& inFile, const QCString& outDir, - const QCString &relPath, const QCString &context) + const QCString &inFile, const QCString &outDir, + const QCString &relPath, const QCString &baseName, + const QCString &context) { - QCString outFile = inFile + ".map"; QDir d(outDir); if (!d.exists()) @@ -3537,17 +3537,19 @@ void writeDotImageMapFromFile(FTextStream &t, err("error: Output dir %s does not exist!\n",outDir.data()); exit(1); } + QCString mapName = baseName+".map"; + QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT"); + QCString imgName = baseName+"."+imgExt; + QCString absOutFile = QCString(d.absPath())+"/"+mapName; + DotRunner dotRun(inFile,d.absPath().data(),FALSE); - dotRun.addJob(MAP_CMD,outFile); + dotRun.addJob(MAP_CMD,absOutFile); dotRun.preventCleanUp(); if (!dotRun.run()) { return; } - QCString mapName = inFile+".map"; - QCString imgExt = Config_getEnum("DOT_IMAGE_FORMAT"); - if (imgExt=="svg") // vector graphics { writeSVGFigureLink(t,relPath,inFile,inFile+".svg"); @@ -3557,16 +3559,15 @@ void writeDotImageMapFromFile(FTextStream &t, } else // bitmap graphics { - t << "<img src=\"" << relPath << inFile << "." - << imgExt << "\" alt=\"" - << inFile << "\" border=\"0\" usemap=\"#" << mapName << "\">" << endl + t << "<img src=\"" << relPath << imgName << "\" alt=\"" + << imgName << "\" border=\"0\" usemap=\"#" << mapName << "\">" << endl << "<map name=\"" << mapName << "\" id=\"" << mapName << "\">"; - convertMapFile(t, outFile, relPath ,TRUE, context); + convertMapFile(t, absOutFile, relPath ,TRUE, context); t << "</map>" << endl; } - d.remove(outFile); + d.remove(absOutFile); } //------------------------------------------------------------- |