diff options
author | Dimitri van Heesch <dimitri@stack.nl> | 2013-07-13 12:28:11 (GMT) |
---|---|---|
committer | Dimitri van Heesch <dimitri@stack.nl> | 2013-07-13 12:28:11 (GMT) |
commit | 096c5944ec6f8ee0fa0733f53a8a87f0bbce0ee4 (patch) | |
tree | e17d86e1d07d5735625389a99a60d67c9aa836e7 /src/xmldocvisitor.cpp | |
parent | 5dd0b01af656004aaf07a6195920520cd4161e27 (diff) | |
download | Doxygen-096c5944ec6f8ee0fa0733f53a8a87f0bbce0ee4.zip Doxygen-096c5944ec6f8ee0fa0733f53a8a87f0bbce0ee4.tar.gz Doxygen-096c5944ec6f8ee0fa0733f53a8a87f0bbce0ee4.tar.bz2 |
The language specifier in e.g. \code{.py} was ignored for the XML output
Diffstat (limited to 'src/xmldocvisitor.cpp')
-rw-r--r-- | src/xmldocvisitor.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/xmldocvisitor.cpp b/src/xmldocvisitor.cpp index 79bd1ad..d9b5df9 100644 --- a/src/xmldocvisitor.cpp +++ b/src/xmldocvisitor.cpp @@ -246,12 +246,17 @@ void XmlDocVisitor::visit(DocStyleChange *s) void XmlDocVisitor::visit(DocVerbatim *s) { if (m_hide) return; - SrcLangExt langExt = getLanguageFromFileName(m_langExt); + QCString lang = m_langExt; + if (!s->language().isEmpty()) // explicit language setting + { + lang = s->language(); + } + SrcLangExt langExt = getLanguageFromFileName(lang); switch(s->type()) { case DocVerbatim::Code: // fall though m_t << "<programlisting>"; - Doxygen::parserManager->getParser(m_langExt) + Doxygen::parserManager->getParser(lang) ->parseCode(m_ci,s->context(),s->text(),langExt, s->isExample(),s->exampleFile()); m_t << "</programlisting>"; |