summaryrefslogtreecommitdiffstats
path: root/src/latexgen.cpp
diff options
context:
space:
mode:
authorDimitri van Heesch <doxygen@gmail.com>2019-12-25 09:04:23 (GMT)
committerGitHub <noreply@github.com>2019-12-25 09:04:23 (GMT)
commitff3fdb3ac14a1f90334ca6c40eac46c772b5af63 (patch)
tree9fc8728c52e91e673137b631ef2f8bd613dfe164 /src/latexgen.cpp
parentfabc8146c8bdbdedcb2d2d8630a5eb60de3f5dc0 (diff)
parentfd3b60caa8bb99bec81b74d74f394c6043091c76 (diff)
downloadDoxygen-ff3fdb3ac14a1f90334ca6c40eac46c772b5af63.zip
Doxygen-ff3fdb3ac14a1f90334ca6c40eac46c772b5af63.tar.gz
Doxygen-ff3fdb3ac14a1f90334ca6c40eac46c772b5af63.tar.bz2
Merge pull request #7230 from albert-github/feature/bug_formula_macrofile
Create possibility to define LaTeX commands for formulas
Diffstat (limited to 'src/latexgen.cpp')
-rw-r--r--src/latexgen.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/latexgen.cpp b/src/latexgen.cpp
index 7d54f7a..5c2beae 100644
--- a/src/latexgen.cpp
+++ b/src/latexgen.cpp
@@ -691,6 +691,16 @@ static void writeDefaultHeaderPart1(FTextStream &t)
writeExtraLatexPackages(t);
writeLatexSpecialFormulaChars(t);
+ QCString macroFile = Config_getString(FORMULA_MACROFILE);
+ if (!macroFile.isEmpty())
+ {
+ QCString dir=Config_getString(LATEX_OUTPUT);
+ QFileInfo fi(macroFile);
+ macroFile=fi.absFilePath().utf8();
+ QCString stripMacroFile = fi.fileName().data();
+ copyFile(macroFile,dir + "/" + stripMacroFile);
+ t << "\\input{" << stripMacroFile << "}" << endl;
+ }
// Hyperlinks
bool pdfHyperlinks = Config_getBool(PDF_HYPERLINKS);