32 const QCString &context)
35 if (!f.open(IO_ReadOnly))
37 err(
"failed to open map file %s for inclusion in the docs!\n"
38 "If you installed Graphviz/dot after a previous failing run, \n"
39 "try deleting the output directory and rerun doxygen.\n",mapName);
42 const int maxLineLen=1024;
50 int numBytes = f.readLine(buf,maxLineLen);
53 if (qstrncmp(buf,
"rect",4)==0)
56 sscanf(buf,
"rect %s %d,%d %d,%d",url,&x1,&y1,&x2,&y2);
58 if (qstrcmp(url,
"\\ref")==0 || qstrcmp(url,
"@ref")==0)
61 sscanf(buf,
"rect %s %s %d,%d %d,%d",ref,url,&x1,&y1,&x2,&y2);
65 if (y2<y1) {
int temp=y2; y2=y1; y1=temp; }
66 if (x2<x1) {
int temp=x2; x2=x1; x1=temp; }
83 t <<
"\" shape=\"rect\" coords=\""
84 << x1 <<
"," << y1 <<
"," << x2 <<
"," << y2 <<
"\""
85 <<
" alt=\"\"/>" <<
endl;
95 QCString absOutFile = outDir;
100 QCString oldDir = QDir::currentDirPath().utf8();
102 QDir::setCurrent(outDir);
129 mscArgs+=extension+
"\"";
142 epstopdfArgs.sprintf(
"\"%s.eps\" --outfile=\"%s.pdf\"",
147 err(
"Problems running epstopdf. Check your TeX installation!\n");
153 QDir::setCurrent(oldDir);
157 const QCString& relPath,
const QCString& context)
159 QCString outFile = inFile +
".map";
164 QCString oldDir = QDir::currentDirPath().utf8();
166 QDir::setCurrent(outDir);
170 QCString mscArgs =
"-T ismap -i \"";
173 mscArgs+=outFile +
"\"";
180 QDir::setCurrent(oldDir);
188 QDir().remove(outFile);
190 QDir::setCurrent(oldDir);
191 return result.data();
195 const QCString &outDir,
196 const QCString &relPath,
197 const QCString &baseName,
198 const QCString &context,
202 QCString mapName = baseName+
".map";
203 t <<
"<img src=\"" << relPath << baseName <<
".";
219 << baseName <<
"\" border=\"0\" usemap=\"#" << mapName <<
"\"/>" <<
endl;
221 t <<
"<map name=\"" << mapName <<
"\" id=\"" << mapName <<
"\">" << imap <<
"</map>" <<
endl;