diff options
author | albert-github <albert.tests@gmail.com> | 2016-08-24 10:41:23 (GMT) |
---|---|---|
committer | albert-github <albert.tests@gmail.com> | 2016-08-24 10:41:23 (GMT) |
commit | a4bde1e1e71a24d6c714377be4265e95deb1acf3 (patch) | |
tree | 102d05997af85748dfb34d448e4ac05524ded74f | |
parent | cd6a8d34708c40da3e568fdb689b59e7a3d8bdbc (diff) | |
download | Doxygen-a4bde1e1e71a24d6c714377be4265e95deb1acf3.zip Doxygen-a4bde1e1e71a24d6c714377be4265e95deb1acf3.tar.gz Doxygen-a4bde1e1e71a24d6c714377be4265e95deb1acf3.tar.bz2 |
Include command show line number (e.g. LaTeX)
Based on the report of Luis Vega (http://doxygen.10944.n7.nabble.com/include-inserts-line-numbers-for-LaTeX-PDF-output-td7683.html)
The default setting for parseCode calls was not consistent between the different output formats, resulting in wrong settings of default options (e.g. show line numbers).
-rw-r--r-- | src/latexdocvisitor.cpp | 18 | ||||
-rw-r--r-- | src/mandocvisitor.cpp | 18 | ||||
-rw-r--r-- | src/rtfdocvisitor.cpp | 18 | ||||
-rw-r--r-- | src/xmldocvisitor.cpp | 18 |
4 files changed, 64 insertions, 8 deletions
diff --git a/src/latexdocvisitor.cpp b/src/latexdocvisitor.cpp index 4a98c77..2c1bc37 100644 --- a/src/latexdocvisitor.cpp +++ b/src/latexdocvisitor.cpp @@ -431,7 +431,14 @@ void LatexDocVisitor::visit(DocInclude *inc) inc->text(), langExt, inc->isExample(), - inc->exampleFile(), &fd); + inc->exampleFile(), + &fd, // fileDef, + -1, // start line + -1, // end line + FALSE, // inline fragment + 0, // memberDef + TRUE // show line numbers + ); m_t << "\\end{DoxyCodeInclude}" << endl; } break; @@ -440,7 +447,14 @@ void LatexDocVisitor::visit(DocInclude *inc) Doxygen::parserManager->getParser(inc->extension()) ->parseCode(m_ci,inc->context(), inc->text(),langExt,inc->isExample(), - inc->exampleFile()); + inc->exampleFile(), + 0, // fileDef + -1, // startLine + -1, // endLine + TRUE, // inlineFragment + 0, // memberDef + FALSE + ); m_t << "\\end{DoxyCodeInclude}\n"; break; case DocInclude::DontInclude: diff --git a/src/mandocvisitor.cpp b/src/mandocvisitor.cpp index 8acffc7..6b06958 100644 --- a/src/mandocvisitor.cpp +++ b/src/mandocvisitor.cpp @@ -237,7 +237,14 @@ void ManDocVisitor::visit(DocInclude *inc) inc->text(), langExt, inc->isExample(), - inc->exampleFile(), &fd); + inc->exampleFile(), + &fd, // fileDef, + -1, // start line + -1, // end line + FALSE, // inline fragment + 0, // memberDef + TRUE + ); if (!m_firstCol) m_t << endl; m_t << ".fi" << endl; m_t << ".PP" << endl; @@ -253,7 +260,14 @@ void ManDocVisitor::visit(DocInclude *inc) inc->text(), langExt, inc->isExample(), - inc->exampleFile()); + inc->exampleFile(), + 0, // fileDef + -1, // startLine + -1, // endLine + TRUE, // inlineFragment + 0, // memberDef + FALSE + ); if (!m_firstCol) m_t << endl; m_t << ".fi" << endl; m_t << ".PP" << endl; diff --git a/src/rtfdocvisitor.cpp b/src/rtfdocvisitor.cpp index 7386c6e..1e539ff 100644 --- a/src/rtfdocvisitor.cpp +++ b/src/rtfdocvisitor.cpp @@ -386,7 +386,14 @@ void RTFDocVisitor::visit(DocInclude *inc) inc->text(), langExt, inc->isExample(), - inc->exampleFile(), &fd); + inc->exampleFile(), + &fd, // fileDef, + -1, // start line + -1, // end line + FALSE, // inline fragment + 0, // memberDef + TRUE // show line numbers + ); m_t << "\\par"; m_t << "}" << endl; } @@ -398,7 +405,14 @@ void RTFDocVisitor::visit(DocInclude *inc) Doxygen::parserManager->getParser(inc->extension()) ->parseCode(m_ci,inc->context(), inc->text(),langExt,inc->isExample(), - inc->exampleFile()); + inc->exampleFile(), + 0, // fileDef + -1, // startLine + -1, // endLine + TRUE, // inlineFragment + 0, // memberDef + FALSE // show line numbers + ); m_t << "\\par"; m_t << "}" << endl; break; diff --git a/src/xmldocvisitor.cpp b/src/xmldocvisitor.cpp index 380a39b..1f5dea3 100644 --- a/src/xmldocvisitor.cpp +++ b/src/xmldocvisitor.cpp @@ -272,7 +272,14 @@ void XmlDocVisitor::visit(DocInclude *inc) inc->text(), langExt, inc->isExample(), - inc->exampleFile(), &fd); + inc->exampleFile(), + &fd, // fileDef, + -1, // start line + -1, // end line + FALSE, // inline fragment + 0, // memberDef + TRUE // show line numbers + ); m_t << "</programlisting>"; } break; @@ -283,7 +290,14 @@ void XmlDocVisitor::visit(DocInclude *inc) inc->text(), langExt, inc->isExample(), - inc->exampleFile()); + inc->exampleFile(), + 0, // fileDef + -1, // startLine + -1, // endLine + TRUE, // inlineFragment + 0, // memberDef + FALSE // show line numbers + ); m_t << "</programlisting>"; break; case DocInclude::DontInclude: |