From 4df52916170bb81179697d0fa78c7d81fd95415f Mon Sep 17 00:00:00 2001 From: Dimitri van Heesch Date: Fri, 26 Sep 2014 21:31:44 +0200 Subject: Fixed problem finding \enduml when using /// style comments. --- src/commentcnv.l | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/commentcnv.l b/src/commentcnv.l index ec56b90..352985f 100644 --- a/src/commentcnv.l +++ b/src/commentcnv.l @@ -450,7 +450,14 @@ void replaceComment(int offset); copyToOutput(yytext,(int)yyleng); g_lastCommentContext = YY_START; g_javaBlock=0; - g_blockName=&yytext[1]; + if (qstrcmp(&yytext[1],"startuml")==0) + { + g_blockName="uml"; + } + else + { + g_blockName=&yytext[1]; + } BEGIN(VerbatimCode); } [\\@]("f$"|"f["|"f{"[a-z]*) { @@ -554,7 +561,7 @@ void replaceComment(int offset); copyToOutput(yytext,(int)yyleng); } ^[ \t]*"///" { - if (g_blockName=="dot" || g_blockName=="msc" || g_blockName=="startuml" || g_blockName.at(0)=='f') + if (g_blockName=="dot" || g_blockName=="msc" || g_blockName=="uml" || g_blockName.at(0)=='f') { // see bug 487871, strip /// from dot images and formulas. int l=0; -- cgit v0.12 From b55a5c91d49359f9bbf7c78d9f284be2092bcfaa Mon Sep 17 00:00:00 2001 From: Dimitri van Heesch Date: Sun, 28 Sep 2014 21:27:35 +0200 Subject: Fixed to small memory leaks --- src/config.h | 1 + src/parserintf.h | 4 ++++ src/plantuml.cpp | 2 +- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/config.h b/src/config.h index 505e4d1..981f6fe 100644 --- a/src/config.h +++ b/src/config.h @@ -533,6 +533,7 @@ class Config m_dict = new QDict(257); m_options->setAutoDelete(TRUE); m_obsolete->setAutoDelete(TRUE); + m_disabled->setAutoDelete(TRUE); m_initialized = FALSE; create(); } diff --git a/src/parserintf.h b/src/parserintf.h index 019b4a9..989fdcf 100644 --- a/src/parserintf.h +++ b/src/parserintf.h @@ -147,6 +147,10 @@ class ParserManager */ ParserManager() : m_defaultParser(0) { m_parsers.setAutoDelete(TRUE); } + ~ParserManager() + { + delete m_defaultParser; + } void registerDefaultParser(ParserInterface *parser) { diff --git a/src/plantuml.cpp b/src/plantuml.cpp index 5e5bd98..87e70e1 100644 --- a/src/plantuml.cpp +++ b/src/plantuml.cpp @@ -116,7 +116,7 @@ void generatePlantUMLOutput(const char *baseName,const char *outDir,PlantUMLOutp QCString epstopdfArgs(maxCmdLine); epstopdfArgs.sprintf("\"%s.eps\" --outfile=\"%s.pdf\"",baseName,baseName); portable_sysTimerStart(); - if (exitCode=portable_system("epstopdf",epstopdfArgs)!=0) + if ((exitCode=portable_system("epstopdf",epstopdfArgs))!=0) { err("Problems running epstopdf. Check your TeX installation! Exit code: %d\n",exitCode); } -- cgit v0.12 From 418d7f076ffbb1aeaae5f689a5dd46977c456a98 Mon Sep 17 00:00:00 2001 From: albert-github Date: Sun, 5 Oct 2014 19:24:52 +0200 Subject: Package mathptmx gives discrepancy between pdf and HTML formulas When using the mathcal command in formulas the mathptmx package gives in the different output version different letters. When the mathptmx, more exuberant, type of fonts are to be used they can be added by means of the EXTRA_PACKAGES option for the dot version. --- src/latexgen.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/src/latexgen.cpp b/src/latexgen.cpp index 4ad577e..7cdfeaf 100644 --- a/src/latexgen.cpp +++ b/src/latexgen.cpp @@ -316,7 +316,6 @@ static void writeDefaultHeaderPart1(FTextStream &t) // Define default fonts t << "% Font selection\n" "\\usepackage[T1]{fontenc}\n" - "\\usepackage{mathptmx}\n" "\\usepackage[scaled=.90]{helvet}\n" "\\usepackage{courier}\n" "\\usepackage{amssymb}\n" -- cgit v0.12 From f121923bde72ef68616224a3fa1c1fe27eeb385e Mon Sep 17 00:00:00 2001 From: albert-github Date: Fri, 10 Oct 2014 19:12:32 +0200 Subject: Generate error message in case bibtex generation fails In case bibtex fails no message is given. When perl is missing the OS just emits an message. With this patch doxygen logs a message (analogous to other calls to portable_system) --- src/cite.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/cite.cpp b/src/cite.cpp index fb96c7a..42374d0 100644 --- a/src/cite.cpp +++ b/src/cite.cpp @@ -211,8 +211,15 @@ void CiteDict::generatePage() const // 5. run bib2xhtml perl script on the generated file which will insert the // bibliography in citelist.doc - portable_system("perl","\""+bib2xhtmlFile+"\" "+bibOutputFiles+" \""+ - citeListFile+"\""); + int exitCode; + portable_sysTimerStop(); + if ((exitCode=portable_system("perl","\""+bib2xhtmlFile+"\" "+bibOutputFiles+" \""+ + citeListFile+"\"")) != 0) + { + err("Problems running bibtex. Verify that the command 'perl --version' works from the command line. Exit code: %d\n", + exitCode); + } + portable_sysTimerStop(); QDir::setCurrent(oldDir); -- cgit v0.12 From d2acdcf3b1bbd4d3079cf6c4ff5de6ba6716fd06 Mon Sep 17 00:00:00 2001 From: albert-github Date: Sat, 11 Oct 2014 12:16:05 +0200 Subject: Empty entry in \tableofcontents in case e.g. section without description. In case a section, subsection etc just has a tag and not a description in the \tableofcontents there is nothing mentioned. With this patch the tag is used as description when no description is present, as is done on other places as well (consistency and no empty items in the \tableofcontents). --- src/definition.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/definition.cpp b/src/definition.cpp index d2e3e01..3c11916 100644 --- a/src/definition.cpp +++ b/src/definition.cpp @@ -1618,7 +1618,7 @@ void Definition::writeToc(OutputList &ol) } cs[0]='0'+nextLevel; if (inLi[nextLevel]) ol.writeString("\n"); - ol.writeString("
  • label+"\">"+si->title+""); + ol.writeString("
  • label+"\">"+(si->title.isEmpty()?si->label:si->title)+""); inLi[nextLevel]=TRUE; level = nextLevel; } -- cgit v0.12 From 6da2e3fb28f6ed9f219c66d165ac4467fda36148 Mon Sep 17 00:00:00 2001 From: albert-github Date: Sat, 11 Oct 2014 12:21:06 +0200 Subject: Bug 738063 - Fortran attribute contiguous not identified Added keywords contiguous and volatile --- src/fortrancode.l | 2 +- src/fortranscanner.l | 26 ++++++++++++++++++++++++-- 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/src/fortrancode.l b/src/fortrancode.l index 03baeed..ac6a73b 100644 --- a/src/fortrancode.l +++ b/src/fortrancode.l @@ -694,7 +694,7 @@ CHAR (CHARACTER{ARGS}?|CHARACTER{BS}"*"({BS}[0-9]+|{ARGS})) TYPE_SPEC (({NUM_TYPE}({BS}"*"{BS}[0-9]+)?)|({NUM_TYPE}{KIND})|DOUBLE{BS}COMPLEX|DOUBLE{BS}PRECISION|{CHAR}|TYPE|CLASS|PROCEDURE) INTENT_SPEC intent{BS}"("{BS}(in|out|in{BS}out){BS}")" -ATTR_SPEC (IMPLICIT|ALLOCATABLE|DIMENSION{ARGS}|EXTERNAL|{INTENT_SPEC}|INTRINSIC|OPTIONAL|PARAMETER|POINTER|PROTECTED|PRIVATE|PUBLIC|SAVE|TARGET|RECURSIVE|PURE|IMPURE|ELEMENTAL|VALUE|NOPASS|DEFERRED) +ATTR_SPEC (IMPLICIT|ALLOCATABLE|DIMENSION{ARGS}|EXTERNAL|{INTENT_SPEC}|INTRINSIC|OPTIONAL|PARAMETER|POINTER|PROTECTED|PRIVATE|PUBLIC|SAVE|TARGET|RECURSIVE|PURE|IMPURE|ELEMENTAL|VALUE|NOPASS|DEFERRED|CONTIGUOUS|VOLATILE) ACCESS_SPEC (PROTECTED|PRIVATE|PUBLIC) /* Assume that attribute statements are almost the same as attributes. */ ATTR_STMT {ATTR_SPEC}|DIMENSION diff --git a/src/fortranscanner.l b/src/fortranscanner.l index 8ea8aeb..8415e43 100644 --- a/src/fortranscanner.l +++ b/src/fortranscanner.l @@ -99,13 +99,15 @@ struct SymbolModifiers { bool nonoverridable; bool nopass; bool pass; + bool contiguous; + bool volat; /* volatile is a reserverd name */ QCString passVar; SymbolModifiers() : type(), returnName(), protection(NONE_P), direction(NONE_D), optional(FALSE), protect(FALSE), dimension(), allocatable(FALSE), external(FALSE), intrinsic(FALSE), parameter(FALSE), pointer(FALSE), target(FALSE), save(FALSE), deferred(FALSE), nonoverridable(FALSE), - nopass(FALSE), pass(FALSE), passVar() {} + nopass(FALSE), pass(FALSE), contiguous(FALSE), volat(FALSE), passVar() {} SymbolModifiers& operator|=(const SymbolModifiers &mdfs); SymbolModifiers& operator|=(QCString mdfrString); @@ -258,7 +260,7 @@ CHAR (CHARACTER{ARGS}?|CHARACTER{BS}"*"({BS}[0-9]+|{ARGS})) TYPE_SPEC (({NUM_TYPE}({BS}"*"{BS}[0-9]+)?)|({NUM_TYPE}{KIND})|DOUBLE{BS}COMPLEX|DOUBLE{BS}PRECISION|{CHAR}|TYPE{ARGS}|CLASS{ARGS}|PROCEDURE{ARGS}?) INTENT_SPEC intent{BS}"("{BS}(in|out|in{BS}out){BS}")" -ATTR_SPEC (EXTERNAL|ALLOCATABLE|DIMENSION{ARGS}|{INTENT_SPEC}|INTRINSIC|OPTIONAL|PARAMETER|POINTER|PROTECTED|PRIVATE|PUBLIC|SAVE|TARGET|NOPASS|PASS{ARGS}?|DEFERRED|NON_OVERRIDABLE) +ATTR_SPEC (EXTERNAL|ALLOCATABLE|DIMENSION{ARGS}|{INTENT_SPEC}|INTRINSIC|OPTIONAL|PARAMETER|POINTER|PROTECTED|PRIVATE|PUBLIC|SAVE|TARGET|NOPASS|PASS{ARGS}?|DEFERRED|NON_OVERRIDABLE|CONTIGUOUS|VOLATILE) ACCESS_SPEC (PRIVATE|PUBLIC) LANGUAGE_BIND_SPEC BIND{BS}"("{BS}C{BS}(,{BS}NAME{BS}"="{BS}"\""(.*)"\""{BS})?")" /* Assume that attribute statements are almost the same as attributes. */ @@ -1572,6 +1574,8 @@ SymbolModifiers& SymbolModifiers::operator|=(const SymbolModifiers &mdfs) nopass |= mdfs.nopass; pass |= mdfs.pass; passVar = mdfs.passVar; + contiguous |= mdfs.contiguous; + volat |= mdfs.volat; return *this; } @@ -1650,6 +1654,14 @@ SymbolModifiers& SymbolModifiers::operator|=(QCString mdfString) { newMdf.nonoverridable = TRUE; } + else if (mdfString=="contiguous") + { + newMdf.contiguous = TRUE; + } + else if (mdfString=="volatile") + { + newMdf.volat = TRUE; + } else if (mdfString.contains("pass")) { newMdf.pass = TRUE; @@ -1804,6 +1816,16 @@ static QCString applyModifiers(QCString typeName, SymbolModifiers& mdfs) if (!typeName.isEmpty()) typeName += ", "; typeName += "protected"; } + if (mdfs.contiguous) + { + if (!typeName.isEmpty()) typeName += ", "; + typeName += "contiguous"; + } + if (mdfs.volat) + { + if (!typeName.isEmpty()) typeName += ", "; + typeName += "volatile"; + } return typeName; } -- cgit v0.12 From b9145da402cd49c4c4e888a31dc17612387b1321 Mon Sep 17 00:00:00 2001 From: albert-github Date: Sat, 11 Oct 2014 14:18:33 +0200 Subject: Last comment of \code{.f90} missing In case e.g. an number of Fortran variables are documented as an example in a \code block and the last line looks like: INTEGER :: var !< documentation The "!< documentation" is missing as the last block was not rendered. Note: STRIP_CODE_COMMENTS has to be NO as otherwise the code comment will anyway, correctly, be absent. --- src/fortrancode.l | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/fortrancode.l b/src/fortrancode.l index 03baeed..6530a8a 100644 --- a/src/fortrancode.l +++ b/src/fortrancode.l @@ -1136,6 +1136,17 @@ PREFIX (RECURSIVE{BS_}|IMPURE{BS_}|PURE{BS_}|ELEMENTAL{BS_}){0,3}(RECURSIVE|I <*>{LOG_OPER} { // Fortran logical comparison keywords g_code->codify(yytext); } +<*><> { + if (YY_START == DocBlock) { + if (!Config_getBool("STRIP_CODE_COMMENTS")) + { + startFontClass("comment"); + codifyLines(docBlock); + endFontClass(); + } + } + yyterminate(); + } %% /*@ ---------------------------------------------------------------------------- -- cgit v0.12 From e446e2e044d674ba3609619e3dd95eb340f15e09 Mon Sep 17 00:00:00 2001 From: Dimitri van Heesch Date: Sat, 11 Oct 2014 17:07:56 +0200 Subject: Bug 737444 - Java: Annotations with brackets prevent documentation --- src/scanner.l | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/scanner.l b/src/scanner.l index 716dc6a..d012b93 100644 --- a/src/scanner.l +++ b/src/scanner.l @@ -1228,7 +1228,7 @@ OPERATOR "operator"{B}*({ARITHOP}|{ASSIGNOP}|{LOGICOP}|{BITOP}) { lineCount(); lastSkipRoundContext = YY_START; - roundCount=1; + roundCount=0; BEGIN( SkipRound ); } else if (qstrncmp(yytext,"@property",9)==0) // ObjC 2.0 property -- cgit v0.12 From 61e07f8ea2d0d2a2f001b1f657d3d5bbe44e7690 Mon Sep 17 00:00:00 2001 From: Claus Stovgaard Date: Tue, 14 Oct 2014 17:05:45 +0200 Subject: Updated configuration script and libdoxygen.pro.in to use llvm-config This is needed on platforms like ubuntu 14.04 where several version of clang can be installed, and the version is included in the location. The best way is to use the llvm-config if available --- configure | 11 ++++++++--- src/libdoxygen.pro.in | 1 + 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/configure b/configure index 5c01af0..7514680 100755 --- a/configure +++ b/configure @@ -554,8 +554,13 @@ fi if test "$f_libclang" = YES; then printf " Checking for libclang ... " - libclang_hdr_dir="/usr/include /usr/local/include /opt/local/include" - libclang_lib_dir="/usr/lib /usr/local/lib /opt/local/lib /usr/lib64/llvm /usr/lib/llvm" + if llvm-config --version > /dev/null 2>&1; then + libclang_hdr_dir=$(llvm-config --includedir) + libclang_lib_dir=$(llvm-config --libdir) + else + libclang_hdr_dir="/usr/include /usr/local/include /opt/local/include" + libclang_lib_dir="/usr/lib /usr/local/lib /opt/local/lib /usr/lib64/llvm /usr/lib/llvm" + fi if test "$f_libclangstatic" = NO; then libclang_lib_name="libclang.so libclang.dylib libclang.a libclang.dll.a" else @@ -952,7 +957,7 @@ EOF #if test "$f_thread" = YES; then # realopts="$realopts thread" #fi - cat $SRC .tmakeconfig | sed -e "s/\$extraopts/$realopts/g" -e "s;%%SQLITE3_INC%%;$sqlite3_hdr_dir;g" -e "s;%%SQLITE3_LIBS%%;$sqlite3_link;g" -e "s;%%LIBCLANG_LIBS%%;$libclang_link;g" >> $DST + cat $SRC .tmakeconfig | sed -e "s/\$extraopts/$realopts/g" -e "s;%%SQLITE3_INC%%;$sqlite3_hdr_dir;g" -e "s;%%SQLITE3_LIBS%%;$sqlite3_link;g" -e "s;%%LIBCLANG_INC%%;$libclang_hdr_dir;g" -e "s;%%LIBCLANG_LIBS%%;$libclang_link;g" >> $DST echo " Created $DST from $SRC..." done diff --git a/src/libdoxygen.pro.in b/src/libdoxygen.pro.in index 703b885..c5943c6 100644 --- a/src/libdoxygen.pro.in +++ b/src/libdoxygen.pro.in @@ -230,6 +230,7 @@ win32-g++:TMAKE_CXXFLAGS += -fno-exceptions linux-g++:TMAKE_CXXFLAGS += -fno-exceptions INCLUDEPATH += ../generated_src/doxygen ../src ../qtools ../libmd5 ../vhdlparser INCLUDEPATH += %%SQLITE3_INC%% +INCLUDEPATH += %%LIBCLANG_INC%% DEPENDPATH += ../generated_src/doxygen win32:INCLUDEPATH += . DESTDIR = ../lib -- cgit v0.12 From b68a4abcfa22e68fd94487a8f2b48588eda5a1af Mon Sep 17 00:00:00 2001 From: albert-github Date: Wed, 15 Oct 2014 13:48:30 +0200 Subject: Bug 738548 - latex: dead links to source code For Latex an extra dependency exists. In case Latex is set and LATEX_SOURCE_CODE is not set the writing of the "Definition in file" section is disabled. --- src/filedef.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/filedef.cpp b/src/filedef.cpp index 9c18e20..3ff69a4 100644 --- a/src/filedef.cpp +++ b/src/filedef.cpp @@ -327,6 +327,13 @@ void FileDef::writeDetailedDescription(OutputList &ol,const QCString &title) //printf("Writing source ref for file %s\n",name().data()); if (Config_getBool("SOURCE_BROWSER")) { + //if Latex enabled and LATEX_SOURCE_CODE isn't -> skip, bug_738548 + ol.pushGeneratorState(); + if (ol.isEnabled(OutputGenerator::Latex) && !Config_getBool("LATEX_SOURCE_CODE")) + { + ol.disable(OutputGenerator::Latex); + } + ol.startParagraph(); QCString refText = theTranslator->trDefinedInSourceFile(); int fileMarkerPos = refText.find("@0"); @@ -339,6 +346,8 @@ void FileDef::writeDetailedDescription(OutputList &ol,const QCString &title) refText.length()-fileMarkerPos-2)); // text right from marker 2 } ol.endParagraph(); + //Restore settings, bug_738548 + ol.popGeneratorState(); } ol.endTextBlock(); } -- cgit v0.12 From 9ac31f84bd25d320f861e9e194fe5df49f4b212b Mon Sep 17 00:00:00 2001 From: albert-github Date: Wed, 15 Oct 2014 16:01:50 +0200 Subject: Bug 738574 - … is replaced by \cdots rather than \dots in the LaTeX output Changed the \cdots to \dots. Based on the bug report and on http://tex.stackexchange.com/questions/77737/dots-versus-ldots-is-there-a-difference --- src/htmlentity.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/htmlentity.cpp b/src/htmlentity.cpp index 216b65c..a4d5914 100644 --- a/src/htmlentity.cpp +++ b/src/htmlentity.cpp @@ -193,7 +193,7 @@ static struct htmlEntityInfo { SYM(upsih), "\xcf\x92", "ϒ", "", "ϒ", "{$\\Upsilon$}", NULL, "\\u978?", { NULL, DocSymbol::Perl_unknown }}, { SYM(piv), "\xcf\x96", "ϖ", "", "ϖ", "{$\\varpi$}", NULL, "\\u982?", { NULL, DocSymbol::Perl_unknown }}, { SYM(bull), "\xe2\x80\xa2", "•", "", "•", "\\textbullet{}", NULL, "\\'95", { NULL, DocSymbol::Perl_unknown }}, - { SYM(hellip), "\xe2\x80\xa6", "…", "", "…", "{$\\cdots$}", NULL, "\\'85", { NULL, DocSymbol::Perl_unknown }}, + { SYM(hellip), "\xe2\x80\xa6", "…", "", "…", "{$\\dots$}", NULL, "\\'85", { NULL, DocSymbol::Perl_unknown }}, { SYM(prime), "\xe2\x80\xb2", "′", "", "′", "'", NULL, "\\u8242?", { "\\\'", DocSymbol::Perl_string }}, { SYM(Prime), "\xe2\x80\xb3", "″", "", "″", "''", NULL, "\\u8243?", { "\"", DocSymbol::Perl_char }}, { SYM(oline), "\xe2\x80\xbe", "‾", "", "‾", "{$\\overline{\\,}$}", NULL, "\\u8254?", { NULL, DocSymbol::Perl_unknown }}, -- cgit v0.12 From 352bac2c21b69d4e33ec0056fe4d2b96fbe1b0b5 Mon Sep 17 00:00:00 2001 From: albert-github Date: Sat, 18 Oct 2014 14:54:40 +0200 Subject: Remove dependency of PLantUML on HAVE_DOT Seen the discussion with the pull request 229 the dependency of PlantUML and HAVE dot should be removed. --- src/config.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/config.xml b/src/config.xml index 1e97b47..d46b8ef 100644 --- a/src/config.xml +++ b/src/config.xml @@ -3304,7 +3304,7 @@ to be found in the default search path. ]]> - -